PageSourceSearch

https://www.titani.tv/main-6628c1ea.196706f7b45767fd1c9f.js

js titani.tv collected 2026-09-25 10:24:52 UTC 131,523 bytes, 21 lines download raw bytes

1try{!function(){var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="ea80ade4-25a8-40f5-8b01-0a8a5e3fc283",e._sentryDebugIdIdentifier="sentry-dbid-ea80ade4-25a8-40f5-8b01-0a8a5e3fc283")}()}catch(e){}!function(){try{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{}).SENTRY_RELEASE={id:"d90ac16e0aec0a5eeda665985099a5735ab0bd5b"}}catch(e){}}(),(self.webpackChunkstaylive_partnerplatform=self.webpackChunkstaylive_partnerplatform||[]).push([[5645],{57779:(e,t,s)=>{s.r(t),s.d(t,{default:()=>w});var a=s(74848),r=s(96540),o=s(53952),l=s(45601),n=s(66176),i=s(77183),c=s(67316),d=s(23574),u=s(50635),p=s(22960),m=Object.defineProperty,h=Object.defineProperties,f=Object.getOwnPropertyDescriptors,g=Object.getOwnPropertySymbols,x=Object.prototype.hasOwnProperty,y=Object.prototype.propertyIsEnumerable,b=(e,t,s)=>t in e?m(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,v=(e,t)=>{for(var s in t||(t={}))x.call(t,s)&&b(e,s,t[s]);if(g)for(var s of g(t))y.call(t,s)&&b(e,s,t[s]);return e},j=(e,t)=>h(e,f(t));const C={ContentFeed:d.default,InformationSection:c.default,VerticalContentFeed:p.default,BackgroundHero:l.default,BoxNavigation:n.default,SwipeCarousel:u.default,AnnouncementBanner:o.default};function w(){const[e,t]=(0,r.useState)(null);(0,r.useEffect)((()=>{var e;return window.addEventListener("message",s),null==(e=null==window?void 0:window.parent)||e.postMessage({type:"staylive_cms.page_changed"},"*"),()=>window.removeEventListener("message",s)}),[]);const s=e=>{var s;"staylive_cms.preview_template"===(null==(s=null==e?void 0:e.data)?void 0:s.type)&&o(e.data.data.component)&&t(j(v({},e.data.data),{name:e.data.data.component}))},o=e=>C[e]?C[e]:null;return e?(0,a.jsx)("div",{className:"flex flex-col justify-center w-full min-h-screen",children:(0,a.jsx)(i.default,{element:e})}):null}},75718:(e,t,s)=>{s.r(t),s.d(t,{default:()=>E});var a=s(74848),r=s(96540),o=s(5556),l=s.n(o),n=s(67438),i=s(24712),c=s(51978),d=s(50321),u=s(51058),p=s(23114),m=s(26840),h=s(15422),f=s(2890),g=s(41412),x=s(90683),y=Object.defineProperty,b=Object.defineProperties,v=Object.getOwnPropertyDescriptors,j=Object.getOwnPropertySymbols,C=Object.prototype.hasOwnProperty,w=Object.prototype.propertyIsEnumerable,S=(e,t,s)=>t in e?y(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,T=(e,t)=>
1{for(var s in t||(t={}))C.call(t,s)&&S(e,s,t[s]);if(j)for(var s of j(t))w.call(t,s)&&S(e,s,t[s]);return e},N=(e,t)=>b(e,v(t)),O=(e,t,s)=>new Promise(((a,r)=>{var o=e=>{try{n(s.next(e))}catch(e){r(e)}},l=e=>{try{n(s.throw(e))}catch(e){r(e)}},n=e=>e.done?a(e.value):Promise.resolve(e.value).then(o,l);n((s=s.apply(e,t)).next())}));function E({subscription:e,isCurrentPlan:t,isSwitching:s,onSwitch:o,isDarkTheme:l,currentSub:y,isUpgrade:b,pendingDowngrade:v}){const[j,C]=(0,r.useState)(!1),{data:w,isLoading:S,error:E}=(0,g.V)(e.ID,j),A=`w-96 text-left ${l?"bg-zinc-800":"bg-white"} rounded-md border-solid ${t?"border-2 border-primary":"border border-transparent"}`,_=l?"text-gray-100":"text-gray-900",P=l?"text-gray-100":"text-gray-900";return(0,a.jsxs)("div",{className:`relative ${A}`,children:[t&&(0,a.jsx)("div",{className:"absolute -top-3 right-4",children:(0,a.jsx)("span",{className:"px-3 py-1 text-xs font-semibold text-white uppercase rounded-full bg-primary whitespace-nowrap",children:(0,a.jsx)(n.A,T({},x.default.currentPlanBadge))})}),v&&(0,a.jsx)("div",{className:"absolute -top-3 right-4",children:(0,a.jsxs)("span",{className:"flex gap-1.5 items-center px-3 py-1 text-xs font-semibold text-amber-900 uppercase whitespace-nowrap bg-amber-400 rounded-full",children:[(0,a.jsx)(i.default,{icon:["fa","exclamation-circle"]}),(0,a.jsx)(n.A,N(T({},x.default.pendingDowngradeBadge),{values:{date:(0,a.jsx)(m.default,{time:!1,date:v.effective_at})}}))]})}),(0,a.jsxs)("div",{className:"p-5% flex flex-col justify-between h-full",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("h3",{style:{height:"65px"},className:`sm:text-3xl text-2xl font-medium pt-0.5 mb-2 line-clamp-2 text-pretty ${_}`,children:(0,a.jsx)(p.default,{text:e.name})}),(0,a.jsx)("p",{style:{height:"100px"},className:`text-pretty overflow-hidden line-clamp-4 mt-4 mb-8 ${P}`,children:(0,a.jsx)(p.default,{text:e.description||""})}),e.included_list&&e.included_list.length>0&&(0,a.jsx)("div",{className:"flex flex-col mt-6 space-y-2 overflow-y-auto max-h-60",children:e.included_list.map(((e,t)=>(0,a.jsxs)("div",{className:"flex items-center ml-1.5",children:[(0,a.jsx)("div",{className:"flex justify-center w-8",children:e.showIcon&&(0,a.jsx)(i.default,{icon:["fas","checkMark"===e.icon?"check":"times"],className:"mt-1 mr-6 "+("checkMark"===e.icon?"text-primary":"text-red-500")})}),(0,a.jsx)("span",{className:`text-sm ${P}`,children:(0,a.jsx)(p.default,{text:e.text})})]},t)))})]}),(0,a.jsxs)("div",{className:"flex flex-col items-center justify-center mt-6",children:[(0,a.jsx)("div",{className:`text-4xl mt-6 font-extrabold ${_}`,children:(0,f.O)(e.price,e.currency)}),e.billing_interval&&(0,a.jsx)("div",{className:`mt-1 text-sm ${P}`,children:(0,a.jsx)(n.A,N(T({},x.default.billedInterval),{values:{interval:(0,a.jsx)(u.default,{billingInterval:e.billing_interval,billingIntervalCount:e.billing_interval_count})}}))}),(0,a.jsx)("div",{className:`mt-1 text-sm ${P} opacity-60`,children:(0,a.jsx)(n.A,T({},x.default.renewsAutomatically))}),(0,a.jsx)("div",{className:"w-full mt-3",children:t?(0,a.jsxs)("div",{className:`flex items-center justify-center text-base py-3 px-4 w-full ${P}`,children:[(0,a.jsx)(i.default,{icon:["fa","check"],className:"mr-2 text-lg text-primary"}),(0,a.jsx)(n.A,T({},x.default.currentPlanBadge))]}):(0,a.jsx)(c.default,{triggerButton:{text:(0,a.jsx)(n.A,T({},x.default.switchTo)),classes:"w-full px-4 py-3 font-bold text-white rounded border-none cursor-pointer bg-primary hover:opacity-75"},open:j,setIsOpen:C,fullScreen:!1,children:(0,a.jsxs)("div",{className:"max-w-lg p-4 text-gray-900 bg-white rounded-xl",children:[(0,a.jsx)("h3",{className:"m-0 text-2xl font-medium text-gray-900",children:(0,a.jsx)(n.A,N(T({},x.default.confirmTitle),{values:{name:(0,a.jsx)(p.default,{text:e.name})}}))}),b?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:"mt-2 text-sm font-semibold text-gray-900",children:(0,a.jsx)(n.A,T({},x.default.confirmBodyUpgradeBold))}),(0,a.jsx)("p",{className:"mt-1 text-sm text-gray-600",children:(0,a.jsx)(n.A,N(T({},x.default.confirmBodyUpgrade),{values:{price:(0,f.O)(e.price,e.currency),interval:(0,a.jsx)(u.default,{billingInterval:e.billing_interval,billingIntervalCount:e.billing_interval_count})}}))})]}):(0,a.jsxs)(a.Fragment,{children:[!t&&(0,a.jsx)("p",{className:"mt-2 text-sm font-semibold text-gray-900",children:(0,a.jsx)(n.A,T({},x.default.confirmBodyDowngradeBold))}),(0,a.jsx)("p",{className:"mt-1 text-sm text-gray-600",children:(0,a.jsx)(n.A,N(T({},t?x.default.confirmBody:x.default.confirmBodyDowngrade),{values:{name:(0,a.jsx)(p.default,{text:e.name}),price:(0,f.O)(e.price,e.currency)}}))})]}),(0,a.jsx)("div",{className:"p-4 mt-4 border border-gray-200 rounded-lg",children:S&&!E?(0,a.jsx)("div",{className:"flex justify-center py-4",children:(0,a.jsx)(h.default,{})}):(0,a.jsxs)("div",{className:"grid grid-cols-2 text-sm gap-x-4 gap-y-3",children:[(0,a.jsx)("span",{className:"text-gray-500",children:(0,a.jsx)(n.A,T({},x.default.currentPlanLabel))}),(0,a.jsx)("span",{className:"font-medium text-gray-900 line-clamp-2",children:(null==y?void 0:y.name)||"—"}),(0,a.jsx)("span",{className:"pt-3 text-gray-500 border-t border-gray-200",children:(0,a.jsx)(n.A,T({},x.default.newPlanLabel))}),(0,a.jsx)("span",{className:"pt-3 font-medium text-gray-900 border-t border-gray-200 line-clamp-2",children:(0,a.jsx)(p.default,{text:e.name})}),(0,a.jsx)("span",{className:"text-gray-500",children:(0,a.jsx)(n.A,T({},x.default.newPriceLabel))}),(0,a.jsxs)("span",{className:"font-medium text-gray-900",children:[(0,f.O)(e.price,e.currency),e.billing_interval&&(0,a.jsxs)("span",{className:"ml-1 text-gray-500",children:["/"," ",(0,a.jsx)(u.default,{billingInterval:e.billing_interval,billingIntervalCount:e.billing_interval_count})]})]}),"upgrade"===(null==w?void 0:w.type)&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"text-gray-500",children:(0,a.jsx)(n.A,T({},x.default.amountDueTodayLabel))}),(0,a.jsx)("span",{className:"font-medium text-gray-900",children:(0,f.O)(w.proratedAmount,w.currency)})]}),(null==y?void 0:y.current_period_end)&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"text-gray-500",children:(0,a.jsx)(n.A,T({},x.default.nextBillingDateLabel))}),(0,a.jsx)("span",{className:"font-medium text-gray-900",children:(0,a.jsx)(m.default,{time:!1,date:"upgrade"===(null==w?void 0:w.type)?w.nextFullChargeDate:y.current_period_end})})]})]})}),(0,a.jsxs)("div",{className:"flex mt-6 space-x-4",children:[(0,a.jsx)(d.default,{"data-testid":"confirm-switch-subscription",color:"primary",size:"py-2 px-4",fontSize:"text-base",loading:s,onClick:()=>O(this,null,(function*(){try{yield o()}finally{C(!1)}})),children:(0,a.jsx)(n.A,T({},x.default.confirmButton))}),(0,a.jsx)("button",{"data-testid":"cancel-switch-subscription",type:"button",onClick:()=>C(!1),className:"px-4 py-2 font-normal text-gray-700 bg-gray-300 border-none rounded cursor-pointer hover:opacity-75",children:(0,a.jsx)(n.A,T({},x.default.cancelButton))})]})]})})})]})]})]})}
1E.propTypes={subscription:l().shape({ID:l().oneOfType([l().string,l().number]),name:l().oneOfType([l().string,l().object]),description:l().string,price:l().number,currency:l().string,billing_interval:l().string,billing_interval_count:l().number,included_list:l().array}).isRequired,isCurrentPlan:l().bool,isSwitching:l().bool,isUpgrade:l().bool,onSwitch:l().func,isDarkTheme:l().bool,currentSub:l().shape({name:l().string,current_period_end:l().oneOfType([l().string,l().number])}),pendingDowngrade:l().shape({effective_at:l().oneOfType([l().string,l().number])})},E.defaultProps={pendingDowngrade:null}},97707:(e,t,s)=>{s.r(t),s.d(t,{default:()=>P});var a=s(74848),r=s(96540),o=s(47767),l=s(84976),n=s(67438),i=s(16683),c=s(1081),d=s(15422),u=s(75718),p=s(39522),m=s(17386),h=s(45581),f=s(69165),g=s(77461),x=s(72748),y=s(60799),b=s(90683),v=Object.defineProperty,j=Object.defineProperties,C=Object.getOwnPropertyDescriptors,w=Object.getOwnPropertySymbols,S=Object.prototype.hasOwnProperty,T=Object.prototype.propertyIsEnumerable,N=(e,t,s)=>t in e?v(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,O=(e,t)=>{for(var s in t||(t={}))S.call(t,s)&&N(e,s,t[s]);if(w)for(var s of w(t))T.call(t,s)&&N(e,s,t[s]);return e},E=(e,t)=>j(e,C(t)),A=(e,t,s)=>new Promise(((a,r)=>{var o=e=>{try{n(s.next(e))}catch(e){r(e)}},l=e=>{try{n(s.throw(e))}catch(e){r(e)}},n=e=>e.done?a(e.value):Promise.resolve(e.value).then(o,l);n((s=s.apply(e,t)).next())}));const _=(0,c.j8)({platform:(0,m.makeSelectPlatform)()});function P(){const{subscriptionGroupId:e}=(0,o.g)(),[t]=(0,l.ok)(),s=(0,o.Zp)(),c=t.get("redirectTo"),m=c&&c.startsWith("/")?c:"/",{platform:v}=(0,i.d4)(_),{baseColor:j,BASE_COLORS:C}=(0,h.m)(),w=j===C.dark,{data:S,error:T,isValidating:N}=(0,f.a)(e),{data:P,isValidating:k}=(0,g.Q)(),[I,$]=(0,r.useState)(null),M=N&&!S||k&&!P,R=(null==P?void 0:P.subscriptions)||[],D=((null==S?void 0:S.subscriptions)||[]).map((e=>String(e.ID))),L=R.find((e=>D.includes(String(e.subscription)))),U=((null==S?void 0:S.subscriptions)||[]).find((e=>String(e.ID)===String(null==L?void 0:L.subscription))),F={day:1/30,week:7/30,month:1,year:12},B=e=>(F[null==e?void 0:e.billing_interval]||0)*((null==e?void 0:e.billing_interval_count)||1),V=B(U),H=[...(null==S?void 0:S.subscriptions)||[]].filter((e=>!U||B(e)>=V)).sort(((e,t)=>{const s=String(null==L?void 0:L.subscription)===String(e.ID),a=String(null==L?void 0:L.subscription)===String(t.ID);return s?-1:a?1:e.price-t.price})),W=e=>A(this,null,(function*(){var t;if(L&&!I){$(e.ID);try{yield(0,x.Ku)(`platforms/${v.uid}/switch-subscription`,{planId:Number(e.ID)}),y.Ay.success((0,a.jsx)(n.A,E(O({},b.default.switchSuccess),{values:{name:e.name}})),{duration:5e3}),s(m)}catch(e){console.error(e),"A subscription change is already scheduled."===(null==(t=e.json)?void 0:t.message)?y.Ay.error((0,a.jsx)(n.A,O({},b.default.errorChangeAlreadyScheduled)),{duration:6e3}):y.Ay.error((0,a.jsx)(n.A,O({},p.default.somethingWentWrong)))}finally{$(null)}}})),Y=w?"min-h-screen bg-zinc-900 text-white":"min-h-screen bg-gray-100 text-gray-900";return M?(0,a.jsx)("div",{className:`${Y} flex items-center justify-center`,children:(0,a.jsx)(d.default,{})}):T||!S?(0,a.jsx)("div",{className:`${Y} flex items-center justify-center`,children:(0,a.jsx)("p",{className:"text-center",children:(0,a.jsx)(n.A,O({},b.default.noGroupFound))})}):(0,a.jsx)("div",{className:`${Y} py-12 px-4`,children:(0,a.jsxs)("div",{className:"px-5% mt-28 mx-auto w-full",children:[(0,a.jsx)("h1",{className:"mb-2 text-3xl font-bold text-center sm:text-4xl",children:(0,a.jsx)(n.A,O({},b.default.pageTitle))}),L&&(0,a.jsx)("p",{className:"mb-10 text-center text-lg "+(w?"text-gray-100":"text-zinc-900"),children:(0,a.jsx)(n.A,E(O({},b.default.currentPlanDescription),{values:{name:L.name}}))}),(0,a.jsx)("div",{className:"flex flex-wrap items-stretch justify-center gap-4",children:H.map((e=>{var t,s;const r=String(null==L?void 0:L.subscription)===String(e.ID),o=I===e.ID,l=e.price>(null!=(t=null==U?void 0:U.price)?t:e.price),n=String(null==(s=null==L?void 0:L.pending_change)?void 0:s.plan_id)===String(e.ID)?L.pending_change:null;return(0,a.jsx)(u.default,{subscription:e,isCurrentPlan:r,isSwitching:o,onSwitch:()=>W(e),isDarkTheme:w,currentSub:L,isUpgrade:l,pendingDowngrade:n},e.ID)}))})]})})}},90683:(e,t,s)=>{s.r(t),s.d(t,{default:()=>o,scope:()=>r});var a=s(11164);
1const r="app.containers.ChangeSubscriptionPage",o=(0,a.YK)({pageTitle:{id:`${r}.pageTitle`,defaultMessage:"Change subscription"},currentPlanDescription:{id:`${r}.currentPlanDescription`,defaultMessage:"You're currently on the {name} plan"},switchSuccess:{id:`${r}.switchSuccess`,defaultMessage:"Successfully switched to {name}"},noGroupFound:{id:`${r}.noGroupFound`,defaultMessage:"Subscription group not found."},currentPlanBadge:{id:`${r}.currentPlanBadge`,defaultMessage:"Current plan"},pendingDowngradeBadge:{id:`${r}.pendingDowngradeBadge`,defaultMessage:"Downgrade scheduled for {date}"},switchTo:{id:`${r}.switchTo`,defaultMessage:"Switch to this plan"},confirmTitle:{id:`${r}.confirmTitle`,defaultMessage:"Switch to {name}?"},confirmBody:{id:`${r}.confirmBody`,defaultMessage:"You are about to switch to the {name} plan."},confirmBodyUpgradeBold:{id:`${r}.confirmBodyUpgradeBold`,defaultMessage:"Your upgrade takes effect immediately."},confirmBodyUpgrade:{id:`${r}.confirmBodyUpgrade`,defaultMessage:"When you upgrade, your renewal date changes to today. Your next full charge of {price} will be one {interval} from today."},confirmBodyDowngradeBold:{id:`${r}.confirmBodyDowngradeBold`,defaultMessage:"Your plan change takes effect at the end of your billing period."},confirmBodyDowngrade:{id:`${r}.confirmBodyDowngrade`,defaultMessage:"Your current plan stays active until the end of your billing period. After that your subscription switches to {name} at {price}."},confirmButton:{id:`${r}.confirmButton`,defaultMessage:"Yes, switch my subscription"},cancelButton:{id:`${r}.cancelButton`,defaultMessage:"No, keep my current plan"},currentPlanLabel:{id:`${r}.currentPlanLabel`,defaultMessage:"Current plan"},newPlanLabel:{id:`${r}.newPlanLabel`,defaultMessage:"Switching to"},newPriceLabel:{id:`${r}.newPriceLabel`,defaultMessage:"New price"},billedInterval:{id:`${r}.billedInterval`,defaultMessage:"Billed {interval}"},renewsAutomatically:{id:`${r}.renewsAutomatically`,defaultMessage:"Renews automatically. Cancel anytime."},amountDueTodayLabel:{id:`${r}.amountDueTodayLabel`,defaultMessage:"Amount due today"},nextBillingDateLabel:{id:`${r}.nextBillingDateLabel`,defaultMessage:"Next billing date"},errorChangeAlreadyScheduled:{id:`${r}.errorChangeAlreadyScheduled`,defaultMessage:"A subscription change is already scheduled. Please wait for it to take effect before switching again."}})},70840:(e,t,s)=>{s.r(t),s.d(t,{CheckoutCard:()=>l,default:()=>n});var a=s(74848),r=(s(96540),s(5556)),o=s.n(r);function l({children:e,cardStylingClasses:t}){return(0,a.jsx)("div",{className:`flex flex-col w-full ${t}`,children:e})}l.propTypes={children:o().node,cardStylingClasses:o().string};const n=l},93319:(e,t,s)=>{s.r(t),s.d(t,{EmbedSelection:()=>T,default:()=>N});var a=s(74848),r=(s(96540),s(5556)),o=s.n(r),l=s(96541),n=s(28457),i=s(16683),c=s(1081),d=s(23114),u=s(47767),p=s(45581),m=s(2302),h=s(91606),f=Object.defineProperty,g=Object.defineProperties,x=Object.getOwnPropertyDescriptors,y=Object.getOwnPropertySymbols,b=Object.prototype.hasOwnProperty,v=Object.prototype.propertyIsEnumerable,j=(e,t,s)=>t in e?f(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,C=(e,t)=>{for(var s in t||(t={}))b.call(t,s)&&j(e,s,t[s]);if(y)for(var s of y(t))v.call(t,s)&&j(e,s,t[s]);return e},w=(e,t)=>g(e,x(t));const S=(0,c.j8)({embed:(0,m.makeSelectEmbed)()});function T({textColor:e="text-primaryText"}){const{embed:t}=(0,i.d4)(S),s=new URLSearchParams(window.location.search),r=(0,l.A)(),o=(0,u.Zp)(),c=(0,u.zy)(),{baseColor:m,BASE_COLORS:f}=(0,p.m)(),g=m===f.dark,x={background:g?"transparent":"white",menuBackground:g?"#09090b":"white",text:g?"#F7FAFC":"#1A202C",border:g?"#4A5568":"#E2E8F0",hoverBg:g?"#52525b":"#EDF2F7"},y=t.default_option_text?{name:(0,a.jsx)(d.default,{text:t.default_option_text}),id:0}:{name:r.formatMessage(h.default.nothingSelected),id:0},b=t.options;b.unshift(y);const v=b.map((e=>({key:e.id,value:e.id,label:(0,a.jsx)(d.default,{text:e.name}),affiliate:e.affiliate})));return(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("div",{className:"flex flex-row items-center justify-start",children:(0,a.jsxs)("div",{className:"flex flex-col justify-start w-full",children:[(0,a.jsx)("div",{className:`mb-2 text-xl font-medium ${e}`,children:(0,a.jsx)(d.default,{text:t.name})}),t.description&&(0,a.jsx)("p",{className:`my-1 ${e}`,children:(0,a.jsx)(d.default,{text:t.description})}),(0,a.jsx)(n.Ay,{name:(0,a.jsx)(d.default,{text:t.name}
1),value:s.has("embed")||s.has(t.uid)?v.find((e=>s.has("embed")?e.affiliate===parseInt(s.get("embed"),10):e.value===s.get(t.uid))):v[0],options:v,onChange:e=>(e=>{if(0===e){if(null===s.get(t.uid))return;s.delete(t.uid),o(`${c.pathname}?${s.toString()}`)}else s.has("embed")?s.delete("embed"):s.delete(t.uid),s.append(t.uid,e),o(`${c.pathname}?${s.toString()}`)})(e.value),styles:{control:(e,t)=>w(C({},e),{backgroundColor:x.background,borderColor:t.isFocused?"var(--color-primary)":x.border,"&:hover":{borderColor:"var(--color-primary)"},boxShadow:t.isFocused?"0 0 0 1px var(--color-primary)":"none"}),menu:e=>w(C({},e),{backgroundColor:x.menuBackground,color:x.text}),option:(e,t)=>w(C({},e),{backgroundColor:t.isFocused?x.hoverBg:"transparent",color:x.text,"&:hover":{backgroundColor:x.hoverBg}}),singleValue:e=>w(C({},e),{color:x.text}),input:e=>w(C({},e),{color:x.text}),placeholder:e=>w(C({},e),{color:g?"#A0AEC0":"#718096"}),dropdownIndicator:e=>w(C({},e),{color:x.text,"&:hover":{color:"var(--color-primary)"}})}})]})})})}T.propTypes={embed:o().shape({name:o().string,description:o().string,options:o().arrayOf(o().shape({name:o().string,id:o().number}))}),textColor:o().string};const N=T},95739:(e,t,s)=>{s.r(t),s.d(t,{default:()=>R});var a=s(74848),r=s(96540),o=s(30261),l=s(37427),n=s(5556),i=s.n(n),c=s(32689),d=s(78210),u=s(6864),p=s(96541),m=s(67438),h=s(39522),f=s(72748),g=s(17386),x=s(1081),y=s(73108),b=s(16683),v=s(47767),j=s(57644),C=s(68678),w=s(19940),S=s(71779),T=s(19952),N=s(29813),O=Object.defineProperty,E=Object.getOwnPropertySymbols,A=Object.prototype.hasOwnProperty,_=Object.prototype.propertyIsEnumerable,P=(e,t,s)=>t in e?O(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,k=(e,t)=>{for(var s in t||(t={}))A.call(t,s)&&P(e,s,t[s]);if(E)for(var s of E(t))_.call(t,s)&&P(e,s,t[s]);return e},I=(e,t,s)=>new Promise(((a,r)=>{var o=e=>{try{n(s.next(e))}catch(e){r(e)}},l=e=>{try{n(s.throw(e))}catch(e){r(e)}},n=e=>e.done?a(e.value):Promise.resolve(e.value).then(o,l);n((s=s.apply(e,t)).next())}));const $=(0,l.c)(c.STRIPE_PUBLISHABLE_TOKEN);$.catch((()=>{}));const M=(0,x.j8)({platform:(0,g.makeSelectPlatform)(),locale:(0,y.makeSelectLocale)()});function R({giftcard:e,classes:t={label:"block font-medium text-gray-900",input:"mt-2 active:border-primary active:outline-none appearance-none bg-white border border-solid focus focus:border-primary focus:outline-none form-input input pb-4 pt-4 px-3 rounded-md shadow-none w-full",errorText:"mt-1 text-red-600",checkbox:"mt-1 mr-2 border border-solid cursor-pointer form-checkbox border-primary text-primary",sendoutDateLabel:"text-gray-900 text-md"},pickedObjectClasses:s={titleColorClass:"text-primary",subtitleColorClass:"text-primary"}}){const{platform:l,locale:n}=(0,b.d4)(M),{user:i}=(0,d.Jd)(),c=(0,p.A)(),[g,x]=(0,r.useState)(!1),[y,O]=(0,r.useState)(null),E=(0,v.Zp)(),A=e&&"sek"===e.currency?"swish":"stripe",_=t.input,P=t.label,R=new Date,L={bought_by_email:i&&i.email||"",sender_name:"",recipient_name:"",sendToMe:!0,sent_to_email:"",schedule:!1,sendout_date:R,personal_message:"",payment_provider:A},U=u.Ik().shape({phone_number:u.Yj().matches(/^(([+]46)\s*(7)|07)[02369]\s*(\d{4})\s*(\d{3})$/).test("is-not-valid-phonenumber",(function(e){return!("swish"===this.options.parent.payment_provider&&!e)})),bought_by_email:u.Yj().email(c.formatMessage(h.default.emailAddressIncorrect)).required(c.formatMessage(h.default.requiredField)),sent_to_email:u.Yj().email(c.formatMessage(h.default.emailAddressIncorrect)).test("is-required",(function(e){return!(!this.options.parent.sendToMe&&!e)||this.createError({message:c.formatMessage(h.default.requiredField)})})),recipient_name:u.Yj().max(100,c.formatMessage(h.default.tooManyChars)).test("is-required",(function(e){return!(!this.options.parent.sendToMe&&!e)||this.createError({message:c.formatMessage(h.default.requiredField)})})),sender_name:u.Yj().max(100,c.formatMessage(h.default.tooManyChars)).test("is-required",(function(e){return!(!this.options.parent.sendToMe&&!e)||this.createError({message:c.formatMessage(h.default.requiredField)})})),personal_message:u.Yj().optional().max(500,c.formatMessage(h.default.tooManyChars)),sendout_date:u.p6().optional(),payment_provider:u.Yj().oneOf(["swish","stripe"]).required(c.formatMessage(h.default.requiredField)),user_terms:u.zM().test("user-terms","",(function(e){return!(!i&&!e)||this.createError({message:c.formatMessage(h.default.requiredField)})}))});return(0,a.jsx)(o.l1,{validationSchema:U,initialValues:L,enableReinitialize:!0,validateOnBlur:!0,validateOnChange:!0,onSubmit:t=>I(this,null,(function*(){const s=`platforms/${l.uid}
1/checkouts/giftcards/${e.id}?payment_provider=${t.payment_provider}`,a={bought_by_email:t.bought_by_email,sent_to_email:t.sendToMe?t.bought_by_email:t.sent_to_email,personal_message:t.personal_message,phone_number:"swish"===t.payment_provider?t.phone_number:null,return_url:window.location.href,language:n,recipient_name:t.sendToMe?t.bought_by_email:t.recipient_name,sender_name:t.sendToMe?t.bought_by_email:t.sender_name,sendout_date:t.sendout_date},r=i?f.Ku:f.un,o=i?f.lA:f.GO,{message:{session:c,payment_provider:d,success_url:u}}=yield r(s,a),p=new URL(u);if("swish"===d){x(!0);let e=yield o(`payment/callback/${c}`);do{e=yield o(`payment/callback/${c}`),yield D(5e3)}while(null===e.message.status);x(!1),1===e.message.status?E((0,j.Ms)(`${p.pathname}${p.search}`)):(O(d),console.error("Swish payment fail"))}else{let e;try{e=yield $}catch(e){return O("stripe"),void console.error(e)}try{yield e.redirectToCheckout({sessionId:c})}catch(e){console.error(e),O(d)}}})),children:({errors:r,touched:l,setFieldValue:n,values:d})=>(0,a.jsxs)(o.lV,{className:"space-y-4",children:[(0,a.jsx)("h2",{className:s.titleColorClass,children:(0,a.jsx)(m.A,k({},N.default.emailSettings))}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"bought_by_email",className:P,children:(0,a.jsx)(m.A,k({},N.default.yourEmail))}),(0,a.jsx)(o.D0,{id:"bought_by_email",name:"bought_by_email",type:"email",disabled:!!i,className:_,placeholder:c.formatMessage(N.default.yourEmailPlaceholder)}),l.bought_by_email&&r.bought_by_email&&(0,a.jsx)("p",{className:t.errorText,children:r.bought_by_email}),!i&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(o.D0,{id:"user_terms",name:"user_terms",type:"checkbox",className:t.checkbox}),(0,a.jsx)(C.default,{}),l.user_terms&&r.user_terms&&(0,a.jsx)("p",{className:t.errorText,children:r.user_terms})]})]}),(0,a.jsx)("p",{className:P,children:(0,a.jsx)(m.A,k({},N.default.giftCardtitle))}),(0,a.jsxs)("div",{className:"flex space-x-2 justify-evenly",children:[(0,a.jsxs)("div",{onClick:()=>n("sendToMe",!0),onKeyPress:()=>n("sendToMe",!0),role:"button",tabIndex:-1,className:"py-3.5 items-center flex flex-row w-1/2 px-4 border border-black border-opacity-50 border-solid rounded-md shadow-inner justify-items-start outline-none cursor-pointer leading-5 "+(d.sendToMe?"":"border-gray-300 hover:border-gray-500 transition ease-in-out"),children:[(0,a.jsx)("input",{readOnly:!0,type:"radio",className:"form-radio mr-2 "+(d.sendToMe?"text-primary":"border-gray-500 border-2 border-solid"),checked:d.sendToMe}),(0,a.jsx)("span",{className:s.titleColorClass,children:(0,a.jsx)(m.A,k({},N.default.sendToMe))})]}),(0,a.jsxs)("div",{onClick:()=>n("sendToMe",!1),onKeyPress:()=>n("sendToMe",!1),role:"button",tabIndex:-1,className:"flex flex-row items-center\n                w-1/2 px-4 py-3.5 border border-black border-solid rounded-md shadow-inner\n                border-opacity-50 justify-items-start outline-none cursor-pointer leading-5\n              "+(d.sendToMe?"border-gray-300 hover:border-gray-500 transition ease-in-out":""),children:[(0,a.jsx)("input",{readOnly:!0,type:"radio",className:"form-radio mr-2 "+(d.sendToMe?"border-gray-500 border-2 border-solid":"text-primary"),checked:!d.sendToMe}),(0,a.jsx)("span",{className:s.titleColorClass,children:(0,a.jsx)(m.A,k({},N.default.sendToSomeoneElse))})]})]}),!d.sendToMe&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"sent_to_email",className:P,children:(0,a.jsx)(m.A,k({},N.default.yourName))}),(0,a.jsx)(o.D0,{id:"sender_name",name:"sender_name",type:"text",className:_,placeholder:c.formatMessage(N.default.yourNamePlaceholder)}),l.sender_name&&r.sender_name&&(0,a.jsx)("p",{className:t.errorText,children:r.sender_name})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"sent_to_email",className:P,children:(0,a.jsx)(m.A,k({},N.default.recipinentsName))}),(0,a.jsx)(o.D0,{id:"recipient_name",name:"recipient_name",type:"text",className:_,placeholder:c.formatMessage(N.default.recipinentsNamePlaceholder)}),l.recipient_name&&r.recipient_name&&(0,a.jsx)("p",{className:t.errorText,children:r.recipient_name})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"sent_to_email",className:P,children:(0,a.jsx)(m.A,k({},N.default.recipientsEmail))}),(0,a.jsx)(o.D0,{id:"sent_to_email",name:"sent_to_email",type:"email",className:_,placeholder:c.formatMessage(N.default.recipientsEmailPlaceholder)}),l.sent_to_email&&r.sent_to_email&&(0,a.jsx)("p",{className:t.errorText,children:r.sent_to_email})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"personal_message",className:P,children:(0,a.jsx)(m.A,k({},N.default.personalMessage))}),(0,a.jsx)(o.D0,{id:"personal_message",name:"personal_message",component:"textarea",rows:4,className:_,placeholder:c.formatMessage(N.default.personalMessagePlaceholder)}),l.personal_message&&r.personal_message&&(0,a.jsx)("p",{className:t.errorText,children:r.personal_message})]}),(0,a.jsxs)("div",{className:"flex items-center",children:[(0,a.jsx)(o.D0,{checked:d.schedule,type:"checkbox",name:"schedule",id:"schedule",className:t.checkbox,onChange:()=>{n("schedule",!d.schedule),d.schedule||n("sendout_date",null)}}),(0,a.jsx)("label",{htmlFor:"schedule",className:`${P} mt-1`,children:(0,a.jsx)(m.A,k({},N.default.scheduleCheckbox))})]}),d.schedule&&(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"sendout_date",className:t.
1sendoutDateLabel,children:(0,a.jsx)(m.A,k({},N.default.sendout_date))}),(0,a.jsx)(o.D0,{id:"sendout_date",name:"sendout_date",component:w.default,value:d.sendout_date||L.sendout_date,onChange:(e,{value:t})=>n("sendout_date",t),placeholder:c.formatMessage(N.default.sendout_datePlaceholder)}),l.sendout_date&&r.sendout_date&&(0,a.jsx)("p",{className:t.errorText,children:r.sendout_date})]})]}),(0,a.jsx)("h2",{className:`pt-4 ${s.titleColorClass}`,children:(0,a.jsx)(m.A,k({},h.default.paymentMethod))}),"sek"===e.currency&&(0,a.jsx)("div",{onClick:()=>n("payment_provider","swish"),onKeyPress:()=>n("payment_provider","swish"),role:"button",tabIndex:-1,className:"outline-none cursor-pointer",children:(0,a.jsx)(T.default,{inputClasses:_,isPolling:g,isError:"swish"===y,pickedObjectClasses:s})}),(0,a.jsx)("div",{onClick:()=>n("payment_provider","stripe"),onKeyPress:()=>n("payment_provider","stripe"),role:"button",tabIndex:-1,className:"outline-none cursor-pointer",children:(0,a.jsx)(S.default,{isError:"stripe"===y,pickedObjectClasses:s})})]})})}function D(e){return I(this,null,(function*(){return new Promise((t=>setTimeout(t,e)))}))}R.propTypes={giftcard:i().object,pickedObjectClasses:i().shape({titleColorClass:i().string,subtitleColorClass:i().string})}},71779:(e,t,s)=>{s.r(t),s.d(t,{default:()=>O});var a=s(74848),r=(s(96540),s(30261)),o=s(24712),l=s(67438),n=s(5556),i=s.n(n),c=s(60697),d=s(1081),u=s(39522),p=s(17386),m=s(16683),h=s(50321),f=s(50924),g=s(71502),x=Object.defineProperty,y=Object.defineProperties,b=Object.getOwnPropertyDescriptors,v=Object.getOwnPropertySymbols,j=Object.prototype.hasOwnProperty,C=Object.prototype.propertyIsEnumerable,w=(e,t,s)=>t in e?x(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,S=(e,t)=>{for(var s in t||(t={}))j.call(t,s)&&w(e,s,t[s]);if(v)for(var s of v(t))C.call(t,s)&&w(e,s,t[s]);return e},T=(e,t)=>
1y(e,b(t));const N=(0,d.j8)({theme:(0,p.makeSelectTheme)()});function O({isError:e,pickedObjectClasses:t}){const{theme:s}=(0,m.d4)(N),{values:n,isValid:i,isSubmitting:d}=(0,r.j7)(),p="stripe"===n.payment_provider;return(0,a.jsxs)("div",{className:"flex flex-col w-full px-4 pt-5 pb-5 mt-5 border border-black border-opacity-50 border-solid rounded-md shadow-inner justify-items-start\n    "+(p?"":"border-gray-300 hover:border-gray-500 transition ease-in-out"),children:[(0,a.jsxs)("div",{className:`flex flex-row items-center text-lg font-medium ${t.titleColorClass}`,children:[(0,a.jsxs)("div",{className:"flex flex-row items-center w-1/2",children:[(0,a.jsx)("input",{readOnly:!0,type:"radio",className:"form-radio mr-2 "+(p?"text-primary":"border-gray-500 border-2 border-solid"),checked:p}),(0,a.jsx)(l.A,S({},c.default.creditCard))]}),(0,a.jsxs)("div",{className:"flex items-center justify-end w-1/2 text-right",children:[(0,a.jsx)(o.default,{icon:["fab","cc-visa"],className:"text-2xl text-gray-900"}),(0,a.jsx)(o.default,{icon:["fab","cc-mastercard"],className:"ml-1 text-2xl text-gray-900"}),(0,a.jsx)(o.default,{icon:["fab","cc-amex"],className:"ml-1 text-2xl text-gray-900"})]})]}),p&&(0,a.jsxs)(a.Fragment,{children:[e&&(0,a.jsx)(f.default,{type:"error",className:"my-2",children:(0,a.jsx)(l.A,S({},g.default.somethingWentWrong))}),(0,a.jsx)(h.default,{type:"submit",disabled:!i||d||!n.bought_by_email,className:"w-full mt-4 mb-2",loading:d,children:(0,a.jsx)(l.A,S({},u.default.goToCheckout))}),(0,a.jsx)("p",{className:"mt-2 text-sm italic",children:(0,a.jsx)(l.A,T(S({},c.default.stripeInformation),{values:{platform:s.platform.name}}))})]})]})}O.propTypes={isError:i().bool,pickedObjectClasses:i().shape({titleColorClass:i().string})},O.defaultProps={pickedObjectClasses:{titleColorClass:"text-gray-900"}}},64221:(e,t,s)=>{s.r(t),s.d(t,{SuccessPage:()=>v,default:()=>j});var a=s(74848),r=s(50321),o=s(24712),l=(s(96540),s(67438)),n=s(39522),i=s(29813),c=s(57644),d=s(40288),u=Object.defineProperty,p=Object.defineProperties,m=Object.getOwnPropertyDescriptors,h=Object.getOwnPropertySymbols,f=Object.prototype.hasOwnProperty,g=Object.prototype.propertyIsEnumerable,x=(e,t,s)=>t in e?u(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,y=(e,t)=>{for(var s in t||(t={}))f.call(t,s)&&x(e,s,t[s]);if(h)for(var s of h(t))g.call(t,s)&&x(e,s,t[s]);return e},b=(e,t)=>p(e,m(t));function v(){const e=new URLSearchParams(window.location.search),t=decodeURIComponent(e.get("sent_to_email"));return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex flex-row items-center justify-start mb-4",children:[(0,a.jsx)(o.default,{icon:["far","check-circle"],className:"text-3xl text-primary"}),(0,a.jsxs)("div",{className:"flex flex-col justify-start ml-4",children:[(0,a.jsx)("h3",{className:"mb-0 text-xl md:text-2xl text-gray-900",children:(0,a.jsx)(l.A,y({},i.default.successTitle))}),(0,a.jsx)("p",{className:"text-sm text-gray-900 md:text-base",children:(0,a.jsx)(l.A,b(y({},i.default.successSubTitle),{values:{strong:e=>(0,a.jsx)("strong",{children:e}),sent_to_email:t}}))})]})]}),(0,a.jsx)(r.default,{onClick:()=>{window.location.href=(0,d.i)(e.get("cta"))||`/${(0,c.rN)()||""}`},children:(0,a.jsx)(l.A,y({},n.default.continue))})]})}v.propTypes={};const j=v},19952:(e,t,s)=>{s.r(t),s.d(t,{default:()=>j});var a=s(74848),r=s(30261),o=(s(96540),s(18512)),l=s(5556),n=s.n(l),i=s(96541),c=s(67438),d=s(71502),u=s(39522),p=s(50321),m=s(76611),h=s(50924),f=Object.defineProperty,g=Object.getOwnPropertySymbols,x=Object.prototype.hasOwnProperty,y=Object.prototype.propertyIsEnumerable,b=(e,t,s)=>t in e?f(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,v=(e,t)=>{for(var s in t||(t={}))x.call(t,s)&&b(e,s,t[s]);if(g)for(var s of g(t))y.call(t,s)&&b(e,s,t[s]);return e};function j({inputClasses:e,isPolling:t,isError:s,pickedObjectClasses:l}){const{values:n,isValid:f}=(0,r.j7)(),g="swish"===n.payment_provider,x=(0,i.A)();return(0,a.jsxs)("div",{className:"flex flex-col w-full px-4 pt-5 pb-5 mt-5 border border-black border-solid border-opacity-50 rounded-md shadow-inner justify-items-start\n          "+(g?"":"border-gray-300 hover:border-gray-500 transition ease-in-out"),children:[(0,a.jsxs)("div",{className:`text-lg font-medium flex flex-row items-center ${l.titleColorClass}`,children:[(0,a.jsxs)("div",{className:"flex flex-row items-center w-1/2",children:[(0,a.jsx)("input",{readOnly:!0,t
1ype:"radio",className:"form-radio mr-2 "+(g?"text-primary":"border-gray-500 border-2 border-solid"),checked:g}),"Swish"]}),(0,a.jsx)("div",{className:"flex items-center justify-end w-1/2 text-right",children:(0,a.jsx)("img",{src:o,width:70,alt:"Swish"})})]}),g&&(t?(0,a.jsx)(m.default,{}):(0,a.jsxs)(a.Fragment,{children:[s&&(0,a.jsx)(h.default,{type:"error",className:"my-2",children:(0,a.jsx)(c.A,v({},d.default.somethingWentWrong))}),(0,a.jsx)(r.D0,{id:"phone_number",name:"phone_number",type:"phone",placeholder:x.formatMessage(d.default.phoneNumber),className:e,disabled:t}),(0,a.jsx)("p",{className:"mt-2 text-sm italic",children:(0,a.jsx)(c.A,v({},d.default.swishInformation))}),(0,a.jsx)(p.default,{className:"w-full",type:"submit",disabled:!f||t,children:(0,a.jsx)(c.A,v({},u.default.continue))})]}))]})}j.propTypes={inputClasses:n().string,isPolling:n().bool,isError:n().bool,pickedObjectClasses:n().shape({titleColorClass:n().string})},j.defaultProps={pickedObjectClasses:{titleColorClass:"text-gray-900"}}},39037:(e,t,s)=>{s.r(t),s.d(t,{default:()=>m});var a=s(74848),r=(s(96540),s(5556)),o=s.n(r),l=s(15422),n=s(96229),i=s(91005),c=s(56569),d=s(95739),u=s(70840),p=s(64221);function m({cardStylingClasses:e,pickedObjectClasses:t,giftcardFormClasses:s,previewGiftcard:r}){const o=(0,i.A)(),m=o.get("g"),{data:h,error:f}=(0,n.I)(r?null:m),g=r||h;if(!r&&f)return(0,a.jsx)("p",{children:f});if(!g)return(0,a.jsx)(l.default,{});if("true"===o.get("success"))return(0,a.jsx)(u.default,{cardStylingClasses:e,children:(0,a.jsx)(p.default,{})});const x={title:g.name,description:g.description,subtitle:g.subtitle,price:{amount:g.price,currency:g.currency,recurring:!1}};return(0,a.jsxs)("div",{className:"mb-8 space-y-4",children:[(0,a.jsx)(u.default,{cardStylingClasses:e,children:(0,a.jsx)(c.default,{disableVoucher:!0,item:x,classes:t})}),(0,a.jsx)(u.default,{cardStylingClasses:e,children:(0,a.jsx)(d.default,{giftcard:g,classes:s,pickedObjectClasses:t})})]})}m.propTypes={cardStylingClasses:o().string,pickedObjectClasses:o().shape({titleColorClass:o().string,subtitleColorClass:o().string,priceColorClass:o().string,discountPriceColorClass:o().string,originalPriceColorClass:o().string,descriptionColorClass:o().string}),giftcardFormClasses:o().shape({label:o().string,input:o().string,errorText:o().string,checkbox:o().string,sendoutDateLabel:o().string}),previewGiftcard:o().shape({id:o().oneOfType([o().string,o().number]),name:o().string,description:o().string,subtitle:o().string,price:o().number,currency:o().string})},m.defaultProps={previewGiftcard:null}},29813:(e,t,s)=>{s.r(t),s.d(t,{default:()=>o,scope:()=>r});var a=s(11164);const r="app.containers.GiftcardCheckout",o=(0,a.YK)({successTitle:{id:`${r}.successTitle`,defaultMessage:"Thank you for your purchase!"},successSubTitle:{id:`${r}.successSubTitle`,defaultMessage:"Your giftcard will be sent out to <strong>{sent_to_email}</strong> shortly."},yourEmail:{id:`${r}.yourEmail`,defaultMessage:"Your email address"},yourEmailPlaceholder:{id:`${r}.yourEmailPlaceholder`,defaultMessage:"Receipt will be sent to this adress"},giftCardtitle:{id:`${r}.giftCardtitle`,defaultMessage:"Gift card code"},giftCardDesc:{id:`${r}.giftCardDesc`,defaultMessage:"Gift card code and redeem instructions will be sent to the recipients email adress."},yourName:{id:`${r}.yourName`,defaultMessage:"Your name"},yourNamePlaceholder:{id:`${r}.yourNamePlaceholder`,defaultMessage:"Used in email sent to recipient"},recipinentsName:{id:`${r}.recipinentsName`,defaultMessage:"Recipients name"},recipinentsNamePlaceholder:{id:`${r}.recipinentsNamePlaceholder`,defaultMessage:"Used in email sent to recipient"},recipientsEmail:{id:`${r}.recipientsEmail`,defaultMessage:"Recipients email adress"},recipientsEmailPlaceholder:{id:`${r}.recipientsEmailPlaceholder`,defaultMessage:"Gift card code will be sent to this adress"},personalMessage:{id:`${r}.personalMessage`,defaultMessage:"Personal message"},personalMessagePlaceholder:{id:`${r}.personalMessagePlaceholder`,defaultMessage:"Write a personal message that will get sent to the recipient."},scheduleCheckbox:{id:`${r}.scheduleCheckbox`,defaultMessage:"I want to schedule the gift card to be sent out later"},sendout_date:{id:`${r}.sendout_date`,defaultMessage:"Schedule date for the receiever to get the gift card"},sendout_datePlaceholder:{id:`${r}.sendout_datePlaceholder`,defaultMessage:"Set a date"},emailSettings:{id:`${r}.emailSettings`,defaultMessage:"Email settings"},sendToMe:{id:`${r}.sendToMe`,defaultMessage:"Send to me"},sendToSomeoneElse:{id:`${r}
1.sendToSomeoneElse`,defaultMessage:"Send to someone else"}})},60157:(e,t,s)=>{s.r(t),s.d(t,{IssueWithProceeding:()=>i,default:()=>c});var a=s(74848),r=(s(96540),s(5556)),o=s.n(r),l=s(50321),n=s(40288);function i({header:e,subheader:t,classes:s={},cta:r,setCta:o=null}){const i=new URLSearchParams(window.location.search),c=o||(0,n.i)(i.get("cta"))||"/";return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"flex flex-row items-center justify-start mb-4",children:(0,a.jsxs)("div",{className:"flex flex-col justify-start",children:[(0,a.jsx)("h3",{className:s.title||"mb-0 text-xl md:text-2xl text-gray-900",children:e}),(0,a.jsx)("p",{className:s.subtitle||"text-lg text-gray-900 mb-4",children:t})]})}),r&&(0,a.jsx)(l.default,{onClick:()=>{window.location.href=c},dataTestid:"issue-with-proceeding-cta",children:r})]})}i.propTypes={header:o().node,subheader:o().node,cta:o().node,setCta:o().string,classes:o().shape({title:o().string,subtitle:o().string})};const c=i},81647:(e,t,s)=>{s.r(t),s.d(t,{Login:()=>N,default:()=>O});var a=s(74848),r=s(96540),o=s(16683),l=s(1081),n=s(17386),i=s(21988),c=s(67438),d=s(47767),u=s(78210),p=s(5556),m=s.n(p),h=s(64011),f=s(50321),g=s(24100),x=s(94152),y=Object.defineProperty,b=Object.getOwnPropertySymbols,v=Object.prototype.hasOwnProperty,j=Object.prototype.propertyIsEnumerable,C=(e,t,s)=>t in e?y(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,w=(e,t)=>{for(var s in t||(t={}))v.call(t,s)&&C(e,s,t[s]);if(b)for(var s of b(t))j.call(t,s)&&C(e,s,t[s]);return e};const S=(0,l.j8)({theme:(0,n.makeSelectTheme)()}),T=({theme:e})=>{var t;return(null==(t=null==e?void 0:e.auth)?void 0:t.skipLoginEnterEmail)?e.auth.loginPrompt?e.auth.loginPrompt:{prompt:"select_account"}:{prompt:"login"}};function N(){const{loginWithRedirect:e,loginWithPopup:t,isAuthenticated:s}=(0,i.WB)(),{isLoading:l}=(0,u.Jd)(),{theme:n}=(0,o.d4)(S),p=(0,g.xM)(),m=T({theme:n}),y=(0,d.Zp)(),b=(0,d.zy)(),v=()=>{const e=new URLSearchParams(b.search).get("back"),t=e&&e.startsWith("/")?e:"/";return"/login"===b.pathname?t:`${b.pathname}${b.search}`},j=()=>{l||(n.auth0&&n.auth0.usePopup||p?t:e)({appState:{returnTo:v()},authorizationParams:m})};return(0,r.useEffect)((()=>{j()}),[]),(0,r.useEffect)((()=>{s&&y(v())}),[s]),(0,a.jsxs)("div",{className:"flex flex-col w-full",children:[(0,a.jsx)(h.default,{}),(0,a.jsx)(f.default,{className:"mt-4",onClick:()=>j(),type:"button",children:(0,a.jsx)(c.A,w({},x.default.ifNothingHappensLoginAction))})]})}N.propTypes={loginSignupFlow:m().shape({loading:m().bool,error:m().oneOfType([m().bool,m().string])})};const O=N},60010:(e,t,s)=>{s.r(t),s.d(t,{LoginOrSignup:()=>R,default:()=>D});var a=s(74848),r=s(96540),o=s(16683),l=s(1081),n=s(21988),i=s(67438),c=s(47767),d=s(5556),u=s.n(d),p=s(17386),m=s(39522),h=s(24712),f=s(68678),g=s(23114),x=s(24100),y=s(80839),b=s(49087),v=s(28795),j=s(70985),C=s(94152),w=s(37640),S=Object.defineProperty,T=Object.defineProperties,N=Object.getOwnPropertyDescriptors,O=Object.getOwnPropertySymbols,E=Object.prototype.hasOwnProperty,A=Object.prototype.propertyIsEnumerable,_=(e,t,s)=>t in e?S(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,P=(e,t)=>{for(var s in t||(t={}))E.call(t,s)&&_(e,s,t[s]);if(O)for(var s of O(t))A.call(t,s)&&_(e,s,t[s]);return e},k=(e,t)=>T(e,N(t)),I=(e,t,s)=>new Promise(((a,r)=>{var o=e=>{try{n(s.next(e))}catch(e){r(e)}},l=e=>{try{n(s.throw(e))}catch(e){r(e)}},n=e=>e.done?a(e.value):Promise.resolve(e.value).then(o,l);n((s=s.apply(e,t)).next())}));const $=[1442],M=(0,l.j8)({theme:(0,p.makeSelectTheme)(),platform:(0,p.makeSelectPlatform)()});function R({validateEmailText:e,textCentered:t=!1,signup:s,classes:l}){var d,u,p,S,T,N;const{theme:O,platform:E}=(0,o.d4)(M),A=(0,o.wA)(),_=(0,c.zy)(),R=(0,c.Zp)(),{loginWithRedirect:D,loginWithPopup:L,getIdTokenClaims:U}=(0,n.WB)(),{data:F}=(0,y.s)(),[B,V]=(0,r.useState)(!1),H=(0,x.xM)(),W=O.auth0&&O.auth0.usePopup||H?L:D,Y=!$.includes(null==E?void 0:E.id),K=(null==(d=null==F?void 0:F.connections)?void 0:d.length)>0,G=O.platform.name,z=(null==(u=null==l?void 0:l.signup)?void 0:u.checkboxLabel)||"text-gray-900",q=(null==(p=null==l?void 0:l.connections)?void 0:p.borderColor)||"border-zinc-400",J=(null==(S=null==l?void 0:l.connections)?void 0:S.textColor)||"text-zinc-500",Q={wrapper:l.wrapper,title:`${t?"text-center":""} ${l.title}`,subtitle:`${t?"text-center":""} ${l.subtitle}`,card:`group flex flex-row items-center w-full gap-4 px-5 py-4 text-left border border-solid rounded-xl cursor-pointer transition-colors duration-200 focus:outline-none focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2 disabled:opacity-60 disabled:cursor-default bg-transparent ${q} ${z} hover:border-primary`,cardTitle:"block text-xl font-semibold leading-tight",cardSuffix:"font-normal opacity-80",cardDescription:"block mt-1 text-base leading-snug opacity-75",chevron:"flex-shrink-0 text-base opacity-60 transition-transform duration-200 group-hover:translate-x-1"},Z=()=>{const e=new URLSearchParams(_.search).get("back"),t=e&&e.startsWith("/")?e:"/";return"/login"===_.pathname?t:`${_.pathname}${_.search}`},X=K?(0,a.jsxs)(a.Fragment,{children:[" ",(0,a.jsx)("span",{className:Q.cardSuffix,children:(0,a.jsx)(i.A,P({},C.default.withEmail))})]}):null;return(0,a.jsxs)("div",{className:Q.wrapper,children:[(0,a.jsx)("div",{className:Q.title,children:(0,a.jsx)(i.A,P({},C.default.logInOrSignUp))}),(0,a.jsx)("p",{className:Q.subtitle,children:e?(0,a.jsx)(g.default,{text:e}):(0,a.jsx)(i.A,P({},C.default.chooseHowToContinue))}),K&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(w.default,{classes:{borderColor:q,textColor:z}}),(0,a.jsxs)("div",{className:"flex items-center w-full my-5",children:[(0,a.jsx)("hr",{className:`flex-grow border-t ${q}`}),(0,a.jsx)("div",{className:`mx-4 text-sm ${J}`,children:(0,a.jsx)(i.A,P({},C.default.orUseEmail))}),(0,a.jsx)("hr",{className:`flex-grow border-t ${q}`})]})]}),(0,a.jsxs)("div",{className:"flex flex-col w-full gap-3",children:[(0,a.jsxs)("button",{type:"button",className:Q.card,onClick:()=>A((0,j.setState)(v.STATES.login)),"data-testid":"sign-in-button",children:[(0,a.jsxs)("span",{className:"flex-grow min-w-0",children:[(0,a.jsxs)("span",{className:Q.cardTitle,children:[(0,a.jsx)(i.A,P({},m.default.signIn)),X]}),(0,a.jsx)("span",{className:Q.cardDescription,children:(0,a.jsx)(i.A,P({},C.default.signInCardDescription))})]}),(0,a.jsx)(h.default,{icon:["fa","chevron-right"],className:Q.chevron})]}),Y&&(0,a.jsxs)("button",{type:"button",className:Q.card,onClick:()=>I(this,null,(function*(){try{if(V(!0),yield W({authorizationParams:{screen_hint:"signup",prompt:"login"},appState:{returnTo:Z(),justRegistered:!0}}),W===L){const e=yield U();(null==e?void 0:e.sub)&&((0,b.Uk)(e.sub),R((0,b.r5)(Z())))}}catch(e){console.log(e)}finally{V(!1)}})),disabled:B,"data-testid":"create-account-button",children:[(0,a.jsxs)("span",{className:"flex-grow min-w-0",children:[(0,a.jsxs)("span",{className:Q.cardTitle,children:[(null==(T=null==s?void 0:s.title)?void 0:T.text)?(0,a.jsx)(g.default,{text:s.title.text,placeholders:{platform:G}}):(0,a.jsx)(i.A,P({},C.default.createAccount)),X]}),(0,a.jsx)("span",{className:Q.cardDescription,children:(null==(N=null==s?void 0:s.description)?void 0:N.text)?(0,a.jsx)(g.default,{text:s.description.text,placeholders:{platform:G}}):(0,a.jsx)(i.A,k(P({},C.default.createAccountCardDescription),{values:{platform:G}}))})]}),B?(0,a.jsx)(h.default,{icon:["fa","circle-notch"],className:"flex-shrink-0 text-base opacity-60 animate-spin"}):(0,a.jsx)(h.default,{icon:["fa","chevron-right"],className:Q.chevron})]})]}),Y&&(0,a.jsx)("p",{className:`mt-5 text-sm leading-relaxed ${z} opacity-75`,children:(0,a.jsx)(f.default,{className:z,passive:!0})})]})}R.propTypes={textCentered:u().bool,validateEmailText:u().string,
1signup:u().shape({title:u().shape({text:u().objectOf(u().string),classes:u().string}),description:u().shape({text:u().objectOf(u().string),classes:u().string})}),classes:u().object};const D=R},37640:(e,t,s)=>{s.r(t),s.d(t,{default:()=>C});var a=s(74848),r=(s(96540),s(5556)),o=s.n(r),l=s(21988),n=s(80839),i=s(67438),c=s(24100),d=s(24712),u=s(47767),p=s(94152),m=Object.defineProperty,h=Object.defineProperties,f=Object.getOwnPropertyDescriptors,g=Object.getOwnPropertySymbols,x=Object.prototype.hasOwnProperty,y=Object.prototype.propertyIsEnumerable,b=(e,t,s)=>t in e?m(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,v=(e,t)=>{for(var s in t||(t={}))x.call(t,s)&&b(e,s,t[s]);if(g)for(var s of g(t))y.call(t,s)&&b(e,s,t[s]);return e};function j({classes:e={borderColor:"border-zinc-400",textColor:"text-gray-900"}}){var t;const{loginWithRedirect:s}=(0,l.WB)(),{data:r}=(0,n.s)(),o=(0,u.zy)(),m=()=>{const e=new URLSearchParams(o.search).get("back"),t=e&&e.startsWith("/")?e:"/";return"/login"===o.pathname?t:`${o.pathname}${o.search}`};return(0,a.jsx)("div",{className:"flex flex-col w-full gap-2",children:null==(t=null==r?void 0:r.connections)?void 0:t.map((t=>{return(0,a.jsxs)("button",{className:`flex flex-row items-center w-full gap-3 px-4 py-3 text-base bg-transparent border border-solid rounded-xl cursor-pointer ${e.borderColor} ${e.textColor} hover:border-primary transition-colors duration-200 focus:outline-none focus-visible:ring-2 focus-visible:ring-primary focus-visible:ring-offset-2`,type:"button","data-testid":`social-login-btn-${t.name}`,onClick:()=>s({authorizationParams:{connection:t.name},appState:{returnTo:m()}}),children:[(0,a.jsx)("span",{className:"flex items-center justify-center flex-shrink-0 w-6 h-6",children:t.logo_url?(0,a.jsx)("img",{src:t.logo_url,alt:"",className:"object-contain w-6 h-6"}):(0,a.jsx)(d.default,{icon:(0,c.$w)(t),className:"text-xl"})}),(0,a.jsx)("span",{className:"flex-grow text-center",children:(0,a.jsx)(i.A,(r=v({},p.default.loginWith),o={values:{provider:"oidc"===t.strategy?t.display_name:(0,c.xr)(t)}},h(r,f(o))))}),(0,a.jsx)("span",{className:"flex-shrink-0 w-6","aria-hidden":"true"})]},t.name);var r,o}))})}j.propTypes={classes:o().shape({borderColor:o().string,textColor:o().string})};const C=j},70985:(e,t,s)=>{s.r(t),s.d(t,{setState:()=>r});var a=s(28795);function r(e){return{type:a.SET_STATE,payload:e}}},28795:(e,t,s)=>{s.r(t),s.d(t,{SET_STATE:()=>a,STATES:()=>r});const a="app/LoginSignupFlow/SET_STATE",r={chooseAction:"CHOOSE_ACTION",login:"LOGIN"}},1802:(e,t,s)=>{s.r(t),s.d(t,{LoginSignupFlow:()=>v,default:()=>j});var a=s(74848),r=s(54203),o=s(5556),l=s.n(o),n=s(96540),i=s(16683),c=s(1081),d=s(74980),u=s(78210),p=s(17386),m=s(14727),h=s(28795),f=s(81647),g=s(60010),x=s(22278),y=s(38576);const b=(0,c.j8)({loginSignupFlow:(0,y.default)(),theme:(0,p.makeSelectTheme)()});function v({validateEmailText:e,textCentered:t=!1,signup:s,classes:o={wrapper:"flex flex-col w-full rounded-lg",title:"mb-4 text-2xl font-medium text-gray-900",subtitle:"mb-4 text-lg text-gray-900",signup:{checkboxLabel:"text-gray-900",currentEmail:"text-gray-900 text-sm opacity-75"},connections:{borderColor:"border-zinc-400",textColor:"text-zinc-300"}}}){(0,d.N)({key:"loginSignupFlow",reducer:x.default});const{user:l}=(0,u.Jd)(),{loginSignupFlow:c,theme:p}=(0,i.d4)(b),y=(0,i.wA)(),{state:v}=c;return(0,n.useEffect)((()=>{y((0,r.trackCheckoutStep)({step:v,user:l})),(0,m.track)("CheckoutSignIn",{step:v})}),[v]),p.auth&&p.auth.skipLoginEnterEmail?(0,a.jsx)(f.default,{}):(0,a.jsxs)(a.Fragment,{children:[v===h.STATES.chooseAction&&(0,a.jsx)(g.default,{textCentered:t,validateEmailText:e,signup:s,classes:o}),v===h.STATES.login&&(0,a.jsx)(f.default,{})]})}v.propTypes={loginSignupFlow:l().shape({state:l().oneOf(["CHOOSE_ACTION","LOGIN"])}),validateEmailText:l().string,textCentered:l().bool,signup:l().shape({title:l().shape({text:l().objectOf(l().string),classes:l().string}),description:l().shape({text:l().objectOf(l().string),classes:l().string})}),classes:l().object};const j=v},94152:(e,t,s)=>{s.r(t),s.d(t,{default:()=>o,scope:()=>r});var a=s(11164);
1const r="app.containers.LoginSignupFlow",o=(0,a.YK)({yourEmail:{id:`${r}.yourEmail`,defaultMessage:"Your email address"},yourPassword:{id:`${r}.yourPassword`,defaultMessage:"Password"},youDoNotHaveAnAccount:{id:`${r}.youDoNotHaveAnAccount`,defaultMessage:"You do not have an account. Click the button below to create a new one at {platform}."},enterEmailAddressForPlatform:{id:`${r}.enterEmailAddressForPlatform`,defaultMessage:"Which email address would you like to use to log in to {platform}?"},signInInformationText:{id:`${r}.signInInformationText`,defaultMessage:"You already have an account. Sign in to continue."},passwordIncorrect:{id:`${r}.passwordIncorrect`,defaultMessage:"The password was incorrect. Please try again."},emailIncorrect:{id:`${r}.emailIncorrect`,defaultMessage:"The email is incorrect. Please verify and try again."},createAccount:{id:`${r}.createAccount`,defaultMessage:"Create account"},addAPassword:{id:`${r}.addAPassword`,defaultMessage:"Add a password for your account."},choosePassword:{id:`${r}.choosePassword`,defaultMessage:"Choose password"},changeEmail:{id:`${r}.changeEmail`,defaultMessage:"Change email"},verifiedEmailDescription:{id:`${r}.verifiedEmailDescription`,defaultMessage:"I have checked that my email is correct"},passwordTooShort:{id:`${r}.passwordTooShort`,defaultMessage:"Password needs to be atleast 6 characters long."},passwordRequired:{id:`${r}.passwordRequired`,defaultMessage:"Password is required"},forgotPassword:{id:`${r}.forgotPassword`,defaultMessage:"Forgot password"},forgotYourPassword:{id:`${r}.forgotYourPassword`,defaultMessage:"Forgot your password?"},iRememberMyPassword:{id:`${r}.iRememberMyPassword`,defaultMessage:"I remember my password."},forgotPasswordDescription:{id:`${r}.forgotPasswordDescription`,defaultMessage:"Enter your email address and click continue, and we will send you instructions on how to reset your password."},passwordSent:{id:`${r}.passwordSent`,defaultMessage:"Instructions on how to reset your password has been sent to {email}. If you can't find the email, check in spam as well."},ifNothingHappensLoginAction:{id:`${r}.ifNothingHappensLoginAction`,defaultMessage:"If nothing happens, click here"},loginWith:{id:`${r}.loginWith`,defaultMessage:"Continue with {provider}"},logInOrSignUp:{id:`${r}.logInOrSignUp`,defaultMessage:"Log in or create account"},signInOrCreateAccountForPlatform:{id:`${r}.signInOrCreateAccountForPlatform`,defaultMessage:"Sign in with your existing account, or create a new one at {platform}."},newToPlatform:{id:`${r}.newToPlatform`,defaultMessage:"New to {platform}?"},chooseHowToContinue:{id:`${r}.chooseHowToContinue`,defaultMessage:"Sign in to pick up where you left off, or create an account to get started."},signInCardDescription:{id:`${r}.signInCardDescription`,defaultMessage:"Already have an account? Pick up where you left off."},createAccountCardDescription:{id:`${r}.createAccountCardDescription`,defaultMessage:"New to {platform}? It only takes a minute."},orUseEmail:{id:`${r}.orUseEmail`,defaultMessage:"or use email"},withEmail:{id:`${r}.withEmail`,defaultMessage:"with email"},checkYourInbox:{id:`${r}.checkYourInbox`,defaultMessage:"Check your inbox"},passwordSetupEmailSent:{id:`${r}.passwordSetupEmailSent`,defaultMessage:"You need to set a new password before you can log in. An email with a link to set your password has been sent to {email}. If you can't find the email, check in spam as well."},resendEmail:{id:`${r}.resendEmail`,defaultMessage:"Resend email"},resendEmailIn:{id:`${r}.resendEmailIn`,defaultMessage:"Resend email ({seconds}s)"},passwordSetupEmailResent:{id:`${r}.passwordSetupEmailResent`,defaultMessage:"The email has been sent again."},newsletterLabel:{id:`${r}.newsletterLabel`,defaultMessage:"I would like to receive updates about news, content and more from {platformName}."}})},22278:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,initialState:()=>o});var a=s(64852),r=s(28795);const o={state:r.STATES.chooseAction},l=(e=o,t)=>(0,a.Ay)(e,(e=>{t.type===r.SET_STATE&&(e.state=t.payload)}))},38576:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,selectLoginSignupFlowDomain:()=>o});var a=s(1081),r=s(22278);const o=e=>e.loginSignupFlow||r.initialState,l=()=>(0,a.Mz)(o,(e=>e))},19917:(e,t,s)=>{s.r(t),s.d(t,{Menu:()=>w,default:()=>S});var a=s(74848),r=s(50321),o=s(39522),l=s(5556),n=s.n(l),i=(s(96540),s(16683)),c=s(1081),d=s(17386),u=s(67438),p=s(84976),m=s(78210),h=s(21988),f=s(24712),g=Object.defineProperty,x=Object.getOwnPropertySymbols,y=Object.prototype.hasOwnProperty,b=Object.prototype.propertyIsEnumerable,v=(e,t,s)=>t in e?g(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,j=(e,t)=>{for(var s in t||(t={}))y.call(t,s)&&v(e,s,t[s]);if(x)for(var s of x(t))b.call(t,s)&&v(e,s,t[s]);return e};const C=(0,c.j8)({platform:(0,d.makeSelectPlatform)(),theme:(0,d.makeSelectTheme)()});function w({settings:e}){const{user:t}=(0,m.Jd)(),{logout:s}=(0,h.WB)(),{platform:{stayliveIoBasename:l},theme:n}=(0,i.d4)(C);return(0,a.jsxs)("div",{className:`flex items-center justify-between w-full ${e.menuStylingClasses}`,children:[(0,a.jsx)(p.N_,{to:"/",className:"my-0 leading-3",children:(0,a.jsx)("img",{src:e.logotype||n.logos.webLogo,alt:"Logotype",height:30,className:"my-0"})}),t?(0,a.jsxs)(r.default,{size:"px-1 py-1",color:"transparent",className:"w-auto text-right outline-none",onClick:()=>s({returnTo:`${window.location.origin}${l?`/${l}`:""}?redirectTo=${window.location.pathname||""}${window.location.search||""}`}),children:[(0,a.jsx)(u.A,j({},o.default.signOut)),(0,a.jsx)(f.default,{icon:["fal","arrow-right-from-bracket"],className:"ml-3"})]}):(0,a.jsx)(p.N_,{to:"/login",className:e.linkStylingClasses,children:(0,a.jsx)(u.A,j({},o.default.signIn))})]})}w.propTypes={settings:n().shape({logotype:n().string,menuStylingClasses:n().string,linkStylingClasses:n().string})};const S=w},21852:(e,t,s)=>{s.r(t),s.d(t,{RedeemVoucher:()=>N,default:()=>O});var a=s(74848),r=s(96540),o=s(5556),l=s.n(o),n=s(96541),i=s(67438),c=s(50321),d=s(1081),u=s(17386),p=s(16683),m=s(72748),h=s(60799),f=s(47767),g=s(91005),x=s(98578),y=Object.defineProperty,b=Object.getOwnPropertySymbols,v=Object.prototype.hasOwnProperty,j=Object.prototype.propertyIsEnumerable,C=(e,t,s)=>t in e?y(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,w=(e,t)=>{for(var s in t||(t={}))v.call(t,s)&&C(e,s,t[s]);if(b)for(var s of b(t))j.call(t,s)&&C(e,s,t[s]);return e},S=(e,t,s)=>new Promise(((a,r)=>
1{var o=e=>{try{n(s.next(e))}catch(e){r(e)}},l=e=>{try{n(s.throw(e))}catch(e){r(e)}},n=e=>e.done?a(e.value):Promise.resolve(e.value).then(o,l);n((s=s.apply(e,t)).next())}));const T=(0,d.j8)({platform:(0,u.makeSelectPlatform)()});function N({item:e}){const{platform:t}=(0,p.d4)(T),s=(0,f.Zp)(),o=(0,n.A)(),[l,d]=(0,r.useState)(!1),u=(0,g.A)();return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"flex flex-row items-center justify-start mb-4",children:(0,a.jsxs)("div",{className:"flex flex-col justify-start",children:[(0,a.jsx)("h3",{className:"mb-0 text-xl md:text-2xl text-gray-900",children:(0,a.jsx)(i.A,w({},x.default.unlockForFree))}),(0,a.jsx)("p",{className:"mt-2 text-gray-900 md:text-base",children:(0,a.jsx)(i.A,w({},x.default.unlockSubheader))})]})}),(0,a.jsx)(c.default,{onClick:()=>S(this,null,(function*(){d(!0);try{const a=Array.from(u.entries()).filter((([e,t])=>e.startsWith("AG_"))).map((([e,t])=>t)),r=encodeURIComponent(e.price.discount.code),o=`platforms/${t.uid}/checkouts/redeem?code=${r}`;yield(0,m.Ku)(o,{product_type:e.type,product_identifier:e.id,embed:parseInt(u.get("embed"),10)||a[0]});const l=new URLSearchParams(window.location.search);l.delete("voucher"),l.append("success",!0);const n=`.?${l.toString()}`;s(n,{relative:"path"})}catch(e){console.error(e),h.Ay.error(o.formatMessage(x.default.error),{id:"onRedeem"})}finally{d(!1)}})),loading:l,disabled:l,children:(0,a.jsx)(i.A,w({},x.default.unlock))})]})}N.propTypes={item:l().object};const O=N},98578:(e,t,s)=>{s.r(t),s.d(t,{default:()=>o,scope:()=>r});var a=s(11164);const r="app.containers.RedeemVoucher",o=(0,a.YK)({unlockForFree:{id:`${r}.unlockForFree`,defaultMessage:"Unlock content for free"},unlockSubheader:{id:`${r}.unlockSubheader`,defaultMessage:"Press the button below to unlock the content and start watching."},unlock:{id:`${r}.unlock`,defaultMessage:"Unlock"},error:{id:`${r}.error`,defaultMessage:"The voucher you entered is not valid"}})},1956:(e,t,s)=>{s.r(t),s.d(t,{StripeForm:()=>M,default:()=>R});var a=s(74848),r=s(37427),o=s(50321),l=s(24712),n=s(32689),i=s(39522),c=s(17386),d=s(2302),u=s(5556),p=s.n(u),m=s(96540),h=s(67438),f=s(16683),g=s(1081),x=s(78210),y=s(14727),b=s(54203),v=s(43221),j=s(60697),C=s(50924),w=Object.defineProperty,S=Object.defineProperties,T=Object.getOwnPropertyDescriptors,N=Object.getOwnPropertySymbols,O=Object.prototype.hasOwnProperty,E=Object.prototype.propertyIsEnumerable,A=(e,t,s)=>t in e?w(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,_=(e,t)=>{for(var s in t||(t={}))O.call(t,s)&&A(e,s,t[s]);if(N)for(var s of N(t))E.call(t,s)&&A(e,s,t[s]);return e},P=(e,t)=>S(e,T(t)),k=(e,t,s)=>new Promise(((a,r)=>{var o=e=>{try{n(s.next(e))}catch(e){r(e)}},l=e=>{try{n(s.throw(e))}catch(e){r(e)}},n=e=>e.done?a(e.value):Promise.resolve(e.value).then(o,l);n((s=s.apply(e,t)).next())}));const I=(0,g.j8)({checkoutIds:(0,d.makeSelectCheckoutIds)(),theme:(0,c.makeSelectTheme)()}),$=(0,r.c)(n.STRIPE_PUBLISHABLE_TOKEN);function M({active:e,pickedObjectClasses:t}){const[s,r]=(0,m.useState)(!1),[n,c]=(0,m.useState)(!1),{checkoutIds:d,theme:u}=(0,f.d4)(I),{user:p}=(0,x.Jd)(),g=(0,f.wA)();return(0,a.jsxs)("div",{className:"flex flex-col w-full px-4 pt-5 pb-5 mt-5 border border-black border-solid border-opacity-50 rounded-md shadow-inner justify-items-start\n          "+(e?"":"border-gray-300 transition ease-in-out hover:border-gray-500"),children:[(0,a.jsxs)("div",{className:`flex flex-row items-center text-lg font-medium ${t.titleColorClass}`,children:[(0,a.jsxs)("div",{className:"flex flex-row items-center w-1/2",children:[(0,a.jsx)("input",{readOnly:!0,type:"radio",className:"form-radio mr-2 "+(e?"text-primary":"border-2 border-gray-500 border-solid"),checked:e}),(0,a.jsx)(h.A,_({},j.default.checkout))]}),(0,a.jsxs)("div",{className:"flex items-center justify-end w-1/2 text-right",children:[(0,a.jsx)(l.default,{icon:["fab","cc-visa"],className:`text-2xl ${t.titleColorClass}`}),(0,a.jsx)(l.default,{icon:["fab","cc-mastercard"],className:`ml-1 text-2xl ${t.titleColorClass}`}),(0,a.jsx)(l.default,{icon:["fab","cc-amex"],className:`ml-1 text-2xl ${t.titleColorClass}`})]})]}),e&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(o.default,{loading:s,className:"mt-6 mb-4",onClick:()=>k(this,null,(function*(){let e;c(!1),r(!0),g((0,b.trackCheckoutStep)({step:v.CHECKOUT_STEPS.stripePaymentInit,user:p})),(0,y.track)("CheckoutStripePaymentInit",{step:v.CHECKOUT_STEPS.stripePaymentInit});try{e=yield $}catch(e){return c(!0),r(!1),void console.error(e)}const{paymentError:t}=yield e.redirectToCheckout({sessionId:d.stripe});t&&r(!1)}
1)),dataTestid:"stripe-checkout-button",children:(0,a.jsx)(h.A,_({},i.default.goToCheckout))}),(0,a.jsx)("p",{className:"text-sm italic",children:(0,a.jsx)(h.A,P(_({},j.default.stripeInformation),{values:{platform:u.platform.name}}))}),n&&(0,a.jsx)("span",{className:"mt-4",children:(0,a.jsx)(C.default,{type:"error",className:"rounded-md",children:(0,a.jsx)(h.A,_({},i.default.stripeNotLoaded))})})]})]})}$.catch((()=>{})),M.propTypes={active:p().bool,pickedObjectClasses:p().object};const R=M},42927:(e,t,s)=>{s.r(t),s.d(t,{Success:()=>h,default:()=>f});var a=s(74848),r=(s(96540),s(50924)),o=s(67438),l=s(24712),n=s(71502),i=Object.defineProperty,c=Object.getOwnPropertySymbols,d=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable,p=(e,t,s)=>t in e?i(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,m=(e,t)=>{for(var s in t||(t={}))d.call(t,s)&&p(e,s,t[s]);if(c)for(var s of c(t))u.call(t,s)&&p(e,s,t[s]);return e};function h(){return(0,a.jsx)(r.default,{type:"success",className:"mt-5",children:(0,a.jsxs)("div",{className:"flex flex-row items-center",children:[(0,a.jsx)(l.default,{icon:"check-circle",className:"mr-4"}),(0,a.jsx)(o.A,m({},n.default.success))]})})}const f=h},76611:(e,t,s)=>{s.r(t),s.d(t,{WaitingForUser:()=>h,default:()=>f});var a=s(74848),r=(s(96540),s(50924)),o=s(67438),l=s(24712),n=s(71502),i=Object.defineProperty,c=Object.getOwnPropertySymbols,d=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable,p=(e,t,s)=>t in e?i(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,m=(e,t)=>{for(var s in t||(t={}))d.call(t,s)&&p(e,s,t[s]);if(c)for(var s of c(t))u.call(t,s)&&p(e,s,t[s]);return e};function h(){return(0,a.jsx)(r.default,{type:"success",className:"mt-5",children:(0,a.jsxs)("div",{className:"flex flex-row items-center",children:[(0,a.jsx)(l.default,{icon:"circle-notch",className:"mr-4",spin:!0}),(0,a.jsx)(o.A,m({},n.default.waitingForUser))]})})}const f=h},45827:(e,t,s)=>{s.r(t),s.d(t,{callbackResult:()=>l,paymentRequestSent:()=>o,pollCallback:()=>n,sendPaymentRequest:()=>r});var a=s(14301);const r=(e,t)=>({type:a.SEND_PAYMENT_REQUEST,payload:e,navigate:t}),o=e=>({type:a.PAYMENT_REQUEST_SENT,payload:e}),l=e=>({type:a.CALLBACK_RESULT,payload:e}),n=(e,t)=>({type:a.GET_SWISH_CALLBACK,payload:e,navigate:t})},14301:(e,t,s)=>{s.r(t),s.d(t,{CALLBACK_RESULT:()=>l,GET_SWISH_CALLBACK:()=>o,PAYMENT_REQUEST_SENT:()=>r,SEND_PAYMENT_REQUEST:()=>a,states:()=>n});const a="app/SwishCheckout/SEND_PAYMENT_REQUEST",r="app/SwishCheckout/PAYMENT_REQUEST_SENT",o="app/SwishCheckout/GET_SWISH_CALLBACK",l="app/SwishCheckout/CALLBACK_RESULT",n={init:"INIT",loading:"SENDING_REQUEST",waitingForUser:"WAITING_FOR_USER",success:"SUCCESS",userDenied:"USER_DENIED",error:"ERROR"}},62728:(e,t,s)=>{s.r(t),s.d(t,{SwishForm:()=>H,default:()=>W});var a=s(74848),r=s(50321),o=s(4263),l=s(50924),n=s(39522),i=s(54203),c=s(43221),d=s(2302),u=s(30261),p=s(18512),m=s(5556),h=s.n(m),f=(s(96540),s(67438)),g=s(16683),x=s(1081),y=s(74980),b=s(40260),v=s(78210),j=s(6864),C=s(47767),w=s(14727),S=s(45827),T=s(14301),N=s(71502),O=s(84844),E=s(14378),A=s(79446),_=s(42927),P=s(76611),k=Object.defineProperty,I=Object.defineProperties,$=Object.getOwnPropertyDescriptors,M=Object.getOwnPropertySymbols,R=Object.prototype.hasOwnProperty,D=Object.prototype.propertyIsEnumerable,L=(e,t,s)=>t in e?k(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,U=(e,t)=>{for(var s in t||(t={}))R.call(t,s)&&L(e,s,t[s]);if(M)for(var s of M(t))D.call(t,s)&&L(e,s,t[s]);return e},F=(e,t)=>I(e,$(t));const B=(0,x.j8)({checkoutProvider:(0,d.default)(),swishCheckout:(0,A.default)()}),V=j.Ik().shape({phone:j.Yj().required("A phone number is required to pay with Swish").matches(/^(([+]46)\s*(7)|07)[02369]\s*(\d{4})\s*(\d{3})$/)});function H({active:e,pickedObjectClasses:t}){(0,y.N)({key:"swishCheckout",reducer:O.default}),(0,b.f)({key:"swishCheckout",saga:E.default});const{checkoutProvider:s,swishCheckout:d}=(0,g.d4)(B),m=(0,g.wA)(),{user:h}=(0,v.Jd)(),x=(0,C.Zp)(),j=(0,u.Wx)({initialValues:{phone:""},onSubmit:e=>{m((0,S.sendPaymentRequest)({type:s.item.type,id:s.item.id,phone:e.phone},x)),m((0,i.trackCheckoutStep)({step:c.CHECKOUT_STEPS.swishPaymentInit,user:h})),(0,w.track)("CheckoutPayment",{step:c.CHECKOUT_STEPS.swishPaymentInit})},validationSchema:V});return(0,a.jsxs)("div",{className:"flex flex-col w-full px-4 pt-5 pb-5 mt-5 border border-zinc-600 border-solid border-opacity-50 rounded-md shadow-inner justify-items-start\n          "+(e?"":"border-gray-300 transition ease-in-out hover:border-gray-500"),children:[(0,a.jsxs)("div",{className:`flex flex-row items-center text-lg font-medium ${t.titleColorClass}`,children:[(0,a.jsxs)("div",{className:"flex flex-row items-center w-1/2",children:[(0,a.jsx)("input",{readOnly:!0,t
1ype:"radio",className:"form-radio mr-2 "+(e?"text-primary":"border-2 border-gray-500 border-solid"),checked:e}),"Swish"]}),(0,a.jsx)("div",{className:"flex items-center justify-end w-1/2 text-right",children:(0,a.jsx)("img",{src:p,width:70,alt:"Swish"})})]}),e&&[T.states.init,T.states.error,T.states.userDenied,T.states.loading].includes(d.state)&&(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)("form",{onSubmit:j.handleSubmit,className:"flex flex-col w-full",children:[(0,a.jsxs)("div",{className:"my-4",children:[[T.states.error,T.states.userDenied].includes(d.state)&&(0,a.jsx)(l.default,{type:"error",className:"mb-4",children:(0,a.jsx)(f.A,U({},N.default.somethingWentWrong))}),(0,a.jsx)(f.A,F(U({},N.default.phoneNumber),{children:e=>(0,a.jsx)(o.default,{name:"phone",type:"phone",id:"phone",value:j.values.phone,onChange:j.handleChange,error:j.errors.phone&&j.touched.phone?(0,a.jsx)(f.A,U({},N.default.incorrectPhoneNumber)):null,placeholder:e,className:"bg-white border border-solid rounded-md shadow-none "+(j.errors.phone&&j.touched.phone?"border-red-500":"")})}))]}),(0,a.jsx)(r.default,{loading:d.state===T.states.loading,onClick:()=>{},type:"submit",disabled:j.errors.phone&&j.touched.phone,children:(0,a.jsx)(f.A,U({},n.default.continue))}),(0,a.jsx)("p",{className:`mt-2 text-sm italic ${t.titleColorClass}`,children:(0,a.jsx)(f.A,U({},N.default.swishInformation))})]})}),d.state===T.states.waitingForUser&&(0,a.jsx)(P.default,{}),d.state===T.states.success&&(0,a.jsx)(_.default,{})]})}H.propTypes={active:h().bool,theme:h().object,pickedObjectClasses:h().object};const W=H},71502:(e,t,s)=>{s.r(t),s.d(t,{default:()=>o,scope:()=>r});var a=s(11164);const r="app.containers.SwishCheckout",o=(0,a.YK)({swishInformation:{id:`${r}.swishInformation`,defaultMessage:"Pay using your phone with Swish installed. Currently only available in Sweden."},incorrectPhoneNumber:{id:`${r}.incorrectPhoneNumber`,defaultMessage:"The phone number is not entered correctly"},phoneNumber:{id:`${r}.phoneNumber`,defaultMessage:"Phone number"},waitingForUser:{id:`${r}.waitingForUser`,defaultMessage:"Please verify the purchase in the Swish application."},somethingWentWrong:{id:`${r}.somethingWentWrong`,defaultMessage:"Something went wrong with the request. Please try again."},success:{id:`${r}.success`,defaultMessage:"Köpet lyckades! Skickar dig vidare..."}})},84844:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,initialState:()=>o});var a=s(64852),r=s(14301);const o={state:r.states.init,checkoutId:null},l=(e=o,t)=>(0,a.Ay)(e,(e=>{switch(t.type){case r.SEND_PAYMENT_REQUEST:e.state=r.states.loading;break;case r.PAYMENT_REQUEST_SENT:t.payload.error?e.state=r.states.error:(e.state=r.states.waitingForUser,e.checkoutId=t.payload.message.callback_token);break;case r.CALLBACK_RESULT:0===t.payload.status?e.state=r.states.userDenied:e.state=r.states.success}}))},14378:(e,t,s)=>{s.r(t),s.d(t,{default:()=>p,getCallback:()=>u,paymentRequest:()=>d});var a=s(43786),r=s(32689),o=s(30727),l=s(57644),n=s(72748),i=s(14301),c=s(45827);function*d(e){const{navigate:t}=e,{phone:s,id:l,type:i="LIVESTREAM"}=e.payload,d=yield(0,a.T1)(o.k0);try{if(!s)throw new Error("No phone number provided");const e=`${r.DEFAULT_STAYLIVE_API}payment/${function(e){switch(e){case"LIVESTREAM":return"livestreams";case"VIDEO":return"videos";case"PACKAGE":return"packages";default:return e.toLowerCase()}}(i)}/swish/${l}`,o=new URLSearchParams(window.location.search),u=o.get("embed"),p=o.get("voucher"),m=[];Array.from(o.entries()).forEach((([e,t])=>{e.startsWith("AG_")&&m.push([e,t])}));const h={phoneNumber:s};(u||m.length)&&(h.embed=u||m[0][1]),p&&(h.voucher=p);const f=yield(0,a.T1)(n.Ay,e,{method:"POST",body:JSON.stringify(h),headers:{"Content-Type":"application/json",Authorization:`Bearer ${d}`}});yield(0,a.yJ)((0,c.paymentRequestSent)({error:!1,message:f.message})),yield(0,a.yJ)((0,c.pollCallback)({id:f.message.callback_token},t))}catch(e){yield(0,a.yJ)((0,c.paymentRequestSent)({error:!0}))}}function*u(e){const{navigate:t}=e,{id:s}=e.payload,i=yield(0,a.T1)(o.k0);try{const e=yield(0,a.T1)(n.Ay,`${r.DEFAULT_STAYLIVE_API}payment/callback/${s}`,{headers:{"Content-Type":"application/json",Authorization:`Bearer ${i}`}});null!==e.message.status?(1===e.message.status&&t(`${(0,l.Ms)()}${window.location.search}&success=true`),yield(0,a.yJ)((0,c.callbackResult)({status:e.message.status}))):(yield(0,a.cb)(5e3),yield(0,a.yJ)((0,c.pollCallback)({id:s},t)))}catch(e){yield(0,a.yJ)((0,c.callbackResult)({status:0}))}}function*p(){yield(0,a.p8)(i.SEND_PAYMENT_REQUEST,d),yield(0,a.p8)(i.GET_SWISH_CALLBACK,u)}},79446:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,selectSwishCheckoutDomain:()=>o});var a=s(1081),r=s(84844);const o=e=>e.swishCheckout||r.initialState,l=()=>(0,a.Mz)(o,(e=>e))},53443:(e,t,s)=>{s.r(t),s.d(t,{submitVoucherAction:()=>r,submitVoucherResultAction:()=>o});var a=s(31805);function r(e,t){return{type:a.SUBMIT_VOUCHER,payload:e,navigate:t}}function o(e){return{type:a.SUBMIT_VOUCHER_RESULT,payload:e}}},31805:(e,t,s)=>{s.r(t),s.d(t,{SUBMIT_VOUCHER:()=>a,SUBMIT_VOUCHER_RESULT:()=>r,states:()=>o});const a="app/VoucherCheckout/SUBMIT_VOUCHER",r="app/VoucherCheckout/SUBMIT_VOUCHER_RESULT",o={init:"INIT",loading:"SENDING_REQUEST",voucherIncorrect:"VOUCHER_INCORRECT",voucherPartiallyOff:"VOUCHER_PARTIALLY_OFF"}},30984:(e,t,s)=>{s.r(t),s.d(t,{VoucherCheckout:()=>F,default:()=>B});var a=s(74848),r=s(50321),o=s(24712),l=s(4263),n=s(50924),i=s(54203),c=s(43221),d=s(2302),u=s(30261),p=s(5556),m=s.n(p),h=(s(96540),s(67438)),f=s(16683),g=s(1081),x=s(74980),y=s(40260),b=s(78210),v=s(6864),j=s(47767),C=s(14727),w=s(53443),S=s(31805),T=s(52846),N=s(10476),O=s(59562),E=s(87062),A=Object.defineProperty,_=Object.defineProperties,P=Object.getOwnPropertyDescriptors,k=Object.getOwnPropertySymbols,I=Object.prototype.hasOwnProperty,$=Object.prototype.propertyIsEnumerable,M=(e,t,s)=>t in e?A(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,R=(e,t)=>{for(var s in t||(t={}))I.call(t,s)&&M(e,s,t[s]);if(k)for(var s of k(t))$.call(t,s)&&M(e,s,t[s]);return e},D=(e,t)=>_(e,P(t));const L=(0,g.j8)({voucherCheckout:(0,E.default)(),checkoutProvider:(0,d.default)()}),U=v.Ik().shape({voucher:v.Yj().required("A phone number is required to pay with Swish").min(5,"The voucher is at least 5 characters.")});function F({active:e=!1}){(0,x.N)({key:"voucherCheckout",reducer:N.default}),(0,y.f)({key:"voucherCheckout",saga:O.default});const t=(0,j.Zp)(),{voucherCheckout:s,checkoutProvider:d}=(0,f.d4)(L),{state:p}=s,{user:m}=(0,b.Jd)(),g=(0,f.wA)(),v=(0,u.Wx)({initialValues:{phone:""},onSubmit:e=>{g((0,w.submitVoucherAction)({type:d.item.type,id:d.item.id,voucher:e.voucher},t)),g((0,i.trackCheckoutStep)({step:c.CHECKOUT_STEPS.voucherPaymentInit,user:m})),(0,C.track)("CheckoutPayment",{step:c.CHECKOUT_STEPS.voucherPaymentInit})},validationSchema:U});return(0,a.jsxs)("div",{className:"flex flex-col w-full px-4 pt-5 pb-5 mt-5 border border-black border-opacity-25 border-solid rounded-md shadow-inner justify-items-start",children:[(0,a.jsxs)("div",{className:"text-gray-900 text-lg font-medium flex flex-row items-center "+(e?"":"op
1acity-50"),children:[(0,a.jsxs)("div",{className:"flex flex-row items-center w-1/2",children:[(0,a.jsx)("input",{readOnly:!0,type:"radio",className:"form-radio mr-2 "+(e?"text-primary":"border-gray-500 border-2 border-solid"),checked:e}),(0,a.jsx)(h.A,R({},T.default.voucher))]}),(0,a.jsx)("div",{className:"flex items-center justify-end w-1/2 text-right",children:(0,a.jsx)(o.default,{icon:"gifts"})})]}),e&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:"mt-3 mb-0",children:(0,a.jsx)(h.A,R({},T.default.voucherInformation))}),(0,a.jsxs)("form",{onSubmit:v.handleSubmit,className:"flex flex-col w-full",children:[(0,a.jsxs)("div",{className:"mt-2 mb-4",children:[S.states.voucherIncorrect===p&&(0,a.jsx)(n.default,{type:"error",className:"mb-4",children:(0,a.jsx)(h.A,R({},T.default.voucherError))}),S.states.voucherPartiallyOff===p&&(0,a.jsx)(n.default,{type:"error",className:"mb-4",children:(0,a.jsx)(h.A,R({},T.default.voucherPartiallyOff))}),(0,a.jsx)(h.A,D(R({},T.default.voucher),{children:e=>(0,a.jsx)(l.default,{name:"voucher",type:"voucher",id:"voucher",value:v.values.voucher,onChange:v.handleChange,error:v.errors.voucher?(0,a.jsx)(h.A,R({},T.default.voucherRequired)):null,placeholder:e,className:"bg-white border border-solid rounded-md shadow-none"})}))]}),(0,a.jsx)(r.default,{loading:p===S.states.loading,onClick:()=>{},type:"submit",children:(0,a.jsx)(h.A,R({},T.default.useVoucher))})]})]})]})}F.propTypes={active:m().bool};const B=F},52846:(e,t,s)=>{s.r(t),s.d(t,{default:()=>o,scope:()=>r});var a=s(11164);const r="app.containers.VoucherCheckout",o=(0,a.YK)({voucher:{id:`${r}.voucher`,defaultMessage:"Voucher"},voucherPlaceholder:{id:`${r}.voucherPlaceholder`,defaultMessage:"Enter your voucher here"},useVoucher:{id:`${r}.useVoucher`,defaultMessage:"Use voucher"},voucherInformation:{id:`${r}.voucherInformation`,defaultMessage:"Use a voucher to unlock the content."},voucherError:{id:`${r}.voucherError`,defaultMessage:"Voucher is not valid. Check that you typed the voucher correctly and try again."},voucherRequired:{id:`${r}.voucherRequired`,defaultMessage:"A voucher with a minimum length of 5 characters is required."},voucherPartiallyOff:{id:`${r}.voucherPartiallyOff`,defaultMessage:"Voucher is valid but is required to be 100% off."}})},10476:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,initialState:()=>o});var a=s(64852),r=s(31805);const o={state:"INIT"},l=(e=o,t)=>(0,a.Ay)(e,(e=>{switch(t.type){case r.SUBMIT_VOUCHER:e.state=r.states.loading;break;case r.SUBMIT_VOUCHER_RESULT:t.payload.error&&(e.state=r.states.voucherIncorrect),t.payload.partiallyOff&&(e.state=r.states.voucherPartiallyOff)}}))},59562:(e,t,s)=>{s.r(t),s.d(t,{default:()=>u,submitVoucher:()=>d});var a=s(43786),r=s(72748),o=s(17386),l=s(30727),n=s(32689),i=s(53443),c=s(31805);function*d(e){const{navigate:t}=e,s=yield(0,a.T1)(l.k0),{type:c,id:d,voucher:u}=e.payload;try{if(!d)throw Error("no id provided");const e=yield(0,a.Lt)((0,o.makeSelectPlatform)()),l=encodeURIComponent(u),p=`${n.DEFAULT_STAYLIVE_API}platforms/${e.uid}/vouchers/lookup/${l}?product_type=${c}&product_identifier=${d}`,m=yield(0,a.T1)(r.Ay,p,{method:"GET",headers:{Authorization:`Bearer ${s}`,"Content-Type":"application/json"}});if("PERCENTAGE"===m.message.discount_type&&100===m.message.value)try{yield(0,a.T1)(r.Ay,`${n.DEFAULT_STAYLIVE_API}platforms/${e.uid}/checkouts/redeem?code=${u}`,{method:"POST",body:JSON.stringify({product_type:c,product_identifier:d}),headers:{Authorization:`Bearer ${s}`,"Content-Type":"application/json"}}),t(`${window.location.pathname}${window.location.search}&success=true`)}catch(e){yield(0,a.yJ)((0,i.submitVoucherResultAction)({error:!0}))}else yield(0,a.yJ)((0,i.submitVoucherResultAction)({partiallyOff:!0}))}catch(e){console.debug({err:e}),yield(0,a.yJ)((0,i.submitVoucherResultAction)({error:!0}))}}function*u(){yield(0,a.p8)(c.SUBMIT_VOUCHER,d)}},87062:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,selectVoucherFormDomain:()=>o});var a=s(1081),r=s(10476);const o=e=>e.voucherCheckout||r.initialState,l=()=>(0,a.Mz)(o,(e=>e))},99722:(e,t,s)=>{s.r(t),s.d(t,{default:()=>j});var a=s(74848),r=s(51058),o=(s(96540),s(67438)),l=s(11164),n=s(2890),i=s(5556),c=s.n(i),d=s(39522),u=s(81414),p=Object.defineProperty,m=Object.defineProperties,h=Object.getOwnPropertyDescriptors,f=Object.getOwnPropertySymbols,g=Object.prototype.hasOwnProperty,x=Object.prototype.propertyIsEnumerable,y=(e,t,s)=>t in e?p(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,b=(e,t)=>{for(var s in t||(t={}))g.call(t,s)&&y(e,s,t[s]);if(f)for(var s of f(t))x.call(t,s)&&y(e,s,t[s]);return e},v=(e,t)=>
1m(e,h(t));function j({price:e}){if(!e||!e.discount)return null;if(e.recurring){if("FLAT"===e.discount.discount_type||"PERCENTAGE"===e.discount.discount_type){let t;switch(e.discount.cycles){case"forever":t=(0,a.jsx)("span",{className:"lowercase",children:(0,a.jsx)(o.A,b({},d.default.forever))});break;case 1:t=(0,a.jsx)(o.A,b({},u.default.once));break;default:t=(0,a.jsx)(o.A,v(b({},u.default.recurringPaymentDiscountCycles),{values:{billing_interval:(0,a.jsx)(r.default,{billingInterval:"month",billingIntervalCount:e.discount.cycles})}}))}return(0,a.jsx)(o.A,v(b({},u.default.recurringPaymentDiscount),{values:{discount:"FLAT"===e.discount.discount_type?(0,n.O)(e.discount.value,e.discount.currency):`${e.discount.value} %`,discount_cycles:t}}))}if("TRIAL"===e.discount.discount_type)return(0,a.jsx)(o.A,v(b({},u.default.voucherDaysActivatedInformation),{values:{days:e.discount.value}}));if("SCHEDULED_TRIAL"===e.discount.discount_type){const t=new Date(e.discount.transition_date);return null!=e.discount.value?(0,a.jsx)(o.A,v(b({},u.default.scheduledTrialWithFeeInformation),{values:{discount:(0,n.O)(e.discount.value,e.discount.currency),date:(0,a.jsx)(l.XU,{value:t,day:"2-digit",month:"short",year:"numeric",timeZone:"UTC"})}})):(0,a.jsx)(o.A,v(b({},u.default.scheduledTrialFeelessInformation),{values:{date:(0,a.jsx)(l.XU,{value:t,day:"2-digit",month:"short",year:"numeric",timeZone:"UTC"})}}))}}return(0,a.jsx)(o.A,v(b({},u.default.singlePaymentDiscount),{values:{discount:"FLAT"===e.discount.discount_type?(0,n.O)(e.discount.value,e.discount.currency):`${e.discount.value} %`}}))}j.propTypes={price:c().object}},78571:(e,t,s)=>{s.r(t),s.d(t,{checkVoucher:()=>r,checkVoucherResult:()=>o});var a=s(37861);function r(e,t){return{type:a.CHECK_VOUCHER,payload:e,navigate:t}}function o(e){return{type:a.CHECK_VOUCHER_RESULT,payload:e}}},37861:(e,t,s)=>{s.r(t),s.d(t,{CHECK_VOUCHER:()=>a,CHECK_VOUCHER_RESULT:()=>r});const a="app/VoucherInput/CHECK_VOUCHER",r="app/VoucherInput/CHECK_VOUCHER_RESULT"},98704:(e,t,s)=>{s.r(t),s.d(t,{VoucherInput:()=>$,default:()=>M});var a=s(74848),r=s(96540),o=s(5556),l=s.n(o),n=s(16683),i=s(1081),c=s(67438),d=s(40260),u=s(74980),p=s(2302),m=s(2890),h=s(50321),f=s(24712),g=s(15422),x=s(47767),y=s(99722),b=s(21326),v=s(78571),j=s(19460),C=s(94994),w=s(81414),S=Object.defineProperty,T=Object.defineProperties,N=Object.getOwnPropertyDescriptors,O=Object.getOwnPropertySymbols,E=Object.prototype.hasOwnProperty,A=Object.prototype.propertyIsEnumerable,_=(e,t,s)=>t in e?S(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,P=(e,t)=>{for(var s in t||(t={}))E.call(t,s)&&_(e,s,t[s]);if(O)for(var s of O(t))A.call(t,s)&&_(e,s,t[s]);return e},k=(e,t)=>T(e,N(t));const I=(0,i.j8)({voucherInput:(0,b.default)(),item:(0,p.makeSelectCheckoutItem)()});function $({voucherWarning:e,textColor:t="text-primary"}){var s,o,l,i,p,b,S,T,N,O;(0,u.N)({key:"voucherInput",reducer:j.default}),(0,d.f)({key:"voucherInput",saga:C.default});const E=new URLSearchParams(window.location.search),[A,_]=(0,r.useState)(E.get("voucher")||null),[$,M]=(0,r.useState)(!1),[R,D]=(0,r.useState)(!1),L=(0,n.wA)(),U=(0,x.Zp)(),{voucherInput:F,item:B}=(0,n.d4)(I);return A!==(null==(o=null==(s=null==B?void 0:B.price)?void 0:s.discount)?void 0:o.code)||null===A||$?$?(0,a.jsxs)("div",{children:[(null==(T=null==(S=null==B?void 0:B.price)?void 0:S.discount)?void 0:T.voucher_is_forced)&&(0,a.jsx)("p",{className:`my-2 ${t}`,children:(0,a.jsx)(y.default,{price:B.price})}),(0,a.jsxs)("div",{className:"flex relative flex-row justify-center items-stretch mb-2",children:[(0,a.jsx)(c.A,k(P({},w.default.voucher),{children:e=>(0,a.jsx)("input",{className:"px-2 py-2 w-full text-base rounded-r-none rounded-l-md border border-r-0 border-gray-500 border-solid outline-none form-input focus:outline-none",value:A,onBlur:e=>{setTimeout((()=>{e.target.value.length>1?D(!0):D(!1)}),500)},onChange:e=>_(e.target.value),placeholder:e,autoFocus:!0})})),(0,a.jsx)("button",{onClick:()=>L((0,v.checkVoucher)({voucher:A,product_identifier:B.id,product_type:B.type},U)),disabled:"LOADING"===F.state,type:"button","data-testid":"apply-voucher-button",className:"px-2 text-base font-semibold text-center text-white whitespace-nowrap rounded-md rounded-r-md rounded-l-none border-none transition-all duration-300 cursor-pointer sm:px-4 bg-primary hover:bg-primaryDarker disabled:opacity-50 disabled:cursor-not-allowed",children:(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)("span",{className:"LOADING"===F.state?"invisible":"opacity-100",children:(0,a.jsx)(c.A,P({},w.default.applyVoucher))}),"LOADING"===F.state&&(0,a.jsx)("div",{className:"absolute inset-0",children:(0,a.jsx)(g.default,{size:5,className:"mx-auto"})})]})})]}
1),R&&"true"!==E.get("success")&&"ERROR"!==F.state&&"LOADING"!==F.state&&(0,a.jsx)("div",{className:e.containerClasses,children:(0,a.jsx)("p",{className:e.textClasses,children:(0,a.jsx)(c.A,P({},w.default.voucherInformationText))})}),"ERROR"===F.state&&(0,a.jsx)("div",{className:"mt-0 mb-2 text-red-700",children:(0,a.jsx)(c.A,P({},w.default.voucherNotValid))}),(null==(O=null==(N=null==B?void 0:B.price)?void 0:N.discount)?void 0:O.voucher_is_forced)&&(0,a.jsx)("p",{className:"pt-0 pb-4 text-sm italic",children:(0,a.jsx)(c.A,P({},w.default.vouchersCannotBeStacked))})]}):(0,a.jsxs)("div",{children:[(null==(i=null==(l=null==B?void 0:B.price)?void 0:l.discount)?void 0:i.voucher_is_forced)&&(0,a.jsx)("p",{className:`my-2 ${t}`,children:(0,a.jsx)(y.default,{price:B.price})}),!1===(null==(b=null==(p=null==B?void 0:B.price)?void 0:p.discount)?void 0:b.voucher_applied)&&(0,a.jsx)("p",{className:`my-2 ${t}`,children:(0,a.jsx)(c.A,P({},w.default.forcedVoucherAlreadyUsed))}),(0,a.jsx)(h.default,{onClick:()=>M(!0),basic:!1,color:"transparent",fontSize:"text-sm",size:"pl-0",className:`mt-0 mb-2 text-sm text-left underline ${t}`,children:(0,a.jsx)(c.A,P({},w.default.iHaveAVoucher))})]}):(0,a.jsxs)("div",{className:"mt-0 mb-4",children:[(0,a.jsx)("p",{className:`my-2 ${t}`,children:B.price.discount?(0,a.jsx)(y.default,{price:B.price}):(0,a.jsx)(c.A,k(P({},w.default.voucherDiscountActivatedInformation),{values:{discount:B.price.discount.amount_off?(0,m.O)(B.price.discount.amount_off/100,B.price.discount.currency):`${B.price.discount.percent_off} %`,period:B.price.discount.duration_in_months,voucher:B.price.discount.code.toUpperCase()}}))}),(0,a.jsxs)("span",{className:"px-4 py-2 mt-0 mb-2 text-gray-800 bg-gray-300 rounded-lg",children:[(0,a.jsx)(f.default,{icon:"tag",className:"mt-3 mr-2 text-gray-800"}),B.price.discount.code.toUpperCase(),(0,a.jsx)(f.default,{icon:"times",className:"ml-2 text-gray-800 cursor-pointer hover:text-gray-900",onClick:()=>M(!0)})]})]})}$.propTypes={voucherWarning:l().shape({containerClasses:l().string,textClasses:l().string}),textColor:l().string};const M=$},81414:(e,t,s)=>{s.r(t),s.d(t,{default:()=>o,scope:()=>r});var a=s(11164);const r="app.containers.PaymentFlow.SubscriptionVoucher",o=(0,a.YK)({voucher:{id:`${r}.voucher`,defaultMessage:"Voucher"},iHaveAVoucher:{id:`${r}.iHaveAVoucher`,defaultMessage:"I have a voucher"},voucherDiscountActivatedInformation:{id:`${r}.voucherDiscountActivatedInformation`,defaultMessage:"{discount} off"},voucherNotValid:{id:`${r}.voucherNotValid`,defaultMessage:"This voucher is not valid."},singlePaymentDiscount:{id:`${r}.singlePaymentDiscount`,defaultMessage:"{discount} off."},recurringPaymentDiscount:{id:`${r}.recurringPaymentDiscount`,defaultMessage:"{discount} off {discount_cycles}."},recurringPaymentDiscountCycles:{id:`${r}.recurringPaymentDiscountCycles`,defaultMessage:"for {billing_interval}"},once:{id:`${r}.once`,defaultMessage:"once"},voucherDaysActivatedInformation:{id:`${r}.voucherDaysActivatedInformation`,defaultMessage:"{days} days free"},scheduledTrialWithFeeInformation:{id:`${r}.scheduledTrialWithFeeInformation`,defaultMessage:"{discount} now, then full price starting {date}."},scheduledTrialFeelessInformation:{id:`${r}.scheduledTrialFeelessInformation`,defaultMessage:"Free until {date}, then full price applies."},voucherInformationText:{id:`${r}.voucherInformationText`,defaultMessage:'The entered voucher code has not been applied. Please press "Apply voucher" to activate it.'},applyVoucher:{id:`${r}.applyVoucher`,defaultMessage:"Apply voucher"},vouchersCannotBeStacked:{id:`${r}.vouchersCannotBeStacked`,defaultMessage:"Please note that only one voucher can be used at a time. Applying a new voucher will replace any existing discounts."},forcedVoucherAlreadyUsed:{id:`${r}.forcedVoucherAlreadyUsed`,defaultMessage:"No discount applied as it only applies to new customers."}})},19460:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,initialState:()=>o});var a=s(64852),r=s(37861);const o={state:"INIT"},l=(e=o,t)=>(0,a.Ay)(e,(e=>{switch(t.type){case r.CHECK_VOUCHER:e.state="LOADING";break;case r.CHECK_VOUCHER_RESULT:t.payload.success?e.state="SUCCESS":e.state="ERROR"}}))},94994:(e,t,s)=>{s.r(t),s.d(t,{checkVoucher:()=>u,default:()=>p});var a=s(43786),r=s(32689),o=s(17386),l=s(30727),n=s(72748),i=s(78571),c=s(37861),d=s(57644);function*u(e){try{const{navigate:t}=e,s=yield(0,a.Lt)((0,o.makeSelectPlatform)()),{voucher:c,product_identifier:u,product_type:p}=e.payload,m=encodeURIComponent(c),h=`${r.DEFAULT_STAYLIVE_API}platforms/${s.uid}/vouchers/lookup/${m}?product_type=${p}&product_identifier=${u}`,f=yield(0,a.T1)(l.k0),g={method:"GET",headers:{}};f&&(g.headers={Authorization:`Bearer ${f}`}),yield(0,a.T1)(n.Ay,h,g),yield(0,a.yJ)((0,i.checkVoucherResult)({success:!0}));const x=new URLSearchParams(window.location.search);x.delete("voucher"),x.append("voucher",c),x.delete("date"),x.append("date",Date.now()),t(`${(0,d.Ms)()}?${x.toString()}`)}catch(e){yield(0,a.yJ)((0,i.checkVoucherResult)({success:!1}))}}function*p(){yield(0,a.p8)(c.CHECK_VOUCHER,u)}},21326:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,selectVoucherInputDomain:()=>o});var a=s(1081),r=s(19460);const o=e=>e.voucherInput||r.initialState,l=()=>(0,a.Mz)(o,(e=>e))},49304:(e,t,s)=>{s.r(t),s.d(t,{DEFAULT_ACTION:()=>a});const a="app/PaymentFlow/DEFAULT_ACTION"},73809:(e,t,s)=>{s.r(t),s.d(t,{PaymentFlow:()=>A,default:()=>_});var a=s(74848),r=s(54203),o=s(43221),l=s(2302),n=s(96540),i=s(67438),c=s(16683),d=s(1081),u=s(74980),p=s(5556),m=s.n(p),h=s(40260),f=s(78210),g=s(14727),x=s(60697),y=s(77761),b=s(99209),v=s(1956),j=s(62728),C=Object.defineProperty,w=Object.getOwnPropertySymbols,S=Object.prototype.hasOwnProperty,T=Object.prototype.propertyIsEnumerable,N=(e,t,s)=>t in e?C(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,O=(e,t)=>{for(var s in t||(t={}))S.call(t,s)&&N(e,s,t[s]);if(w)for(var s of w(t))T.call(t,s)&&N(e,s,t[s]);return e};const E=(0,d.j8)({checkoutProvider:(0,l.default)()});function A({pickedObjectClasses:e}){(0,u.N)({key:"paymentFlow",reducer:y.default}),(0,h.f)({key:"paymentFlow",saga:b.default});const{checkoutProvider:t}=(0,c.d4)(E),{user:s}
1=(0,f.Jd)(),[l,d]=(0,n.useState)(t.checkout.swish&&t.checkout.swish.enabled?0:1),p=(0,c.wA)();return(0,n.useEffect)((()=>{var e,a;p((0,r.trackCheckoutStep)({step:o.CHECKOUT_STEPS.choosePayment,user:s})),(0,g.track)("CheckoutChoosePayment",{step:o.CHECKOUT_STEPS.choosePayment,product:null==(e=null==t?void 0:t.item)?void 0:e.title,product_type:null==(a=null==t?void 0:t.item)?void 0:a.type})}),[]),(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:`mb-2 text-xl font-medium ${e.titleColorClass}`,children:(0,a.jsx)(i.A,O({},x.default.choosePaymentMethod))}),t.checkout.swish&&!!t.checkout.swish.enabled&&(0,a.jsx)("div",{onClick:()=>d(0),onKeyPress:()=>d(0),role:"button",tabIndex:-1,className:"outline-none cursor-pointer",children:(0,a.jsx)(j.default,{active:0===l,pickedObjectClasses:e})}),(0,a.jsx)("div",{onClick:()=>d(1),onKeyPress:()=>d(1),role:"button",tabIndex:-1,className:"outline-none cursor-pointer",children:(0,a.jsx)(v.default,{active:1===l,pickedObjectClasses:e})})]})}A.propTypes={pickedObjectClasses:m().object};const _=A},60697:(e,t,s)=>{s.r(t),s.d(t,{default:()=>o,scope:()=>r});var a=s(11164);const r="app.containers.PaymentFlow",o=(0,a.YK)({creditCard:{id:`${r}.creditCard`,defaultMessage:"Credit card"},checkout:{id:`${r}.checkout`,defaultMessage:"Checkout"},stripeInformation:{id:`${r}.stripeInformation`,defaultMessage:"{platform} uses Staylive & Stripe to process purchases online. Everything is encrypted during the purchase, so that no one can access the payment information."},choosePaymentMethod:{id:`${r}.choosePaymentMethod`,defaultMessage:"Choose payment method"}})},77761:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,initialState:()=>o});var a=s(64852),r=s(49304);const o={},l=(e=o,t)=>(0,a.Ay)(e,(()=>{t.type,r.DEFAULT_ACTION}))},99209:(e,t,s)=>{function*a(){}s.r(t),s.d(t,{default:()=>a})},56569:(e,t,s)=>{s.r(t),s.d(t,{PickedObject:()=>N,default:()=>O});var a=s(74848),r=s(51058),o=s(50321),l=s(23114),n=s(39522),i=s(98704),c=s(5556),d=s.n(c),u=s(96540),p=s(67438),m=s(2890),h=s(62654),f=s.n(h),g=s(38267),x=s(30303),y=Object.defineProperty,b=Object.getOwnPropertySymbols,v=Object.prototype.hasOwnProperty,j=Object.prototype.propertyIsEnumerable,C=(e,t,s)=>t in e?y(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,w=(e,t)=>{for(var s in t||(t={}))v.call(t,s)&&C(e,s,t[s]);if(b)for(var s of b(t))j.call(t,s)&&C(e,s,t[s]);return e};const S=g.Ay.span`
2  position: relative;
3
4  ::before {
5    position: absolute;
6    content: '';
7    left: 0;
8    top: 50%;
9    right: 0;
10    border-top: 1px solid;
11    border-color: inherit;
12
13    -webkit-transform: rotate(-5deg);
14    -moz-transform: rotate(-5deg);
15    -ms-transform: rotate(-5deg);
16    -o-transform: rotate(-5deg);
17    transform: rotate(-5deg);
18  }
19`,T=150;function N({item:e,disableVoucher:t=!1,voucherWarning:s,classes:c}){const{titleColorClass:d="text-primary",subtitleColorClass:h="text-primary",priceColorClass:g="text-gray-900",discountPriceColorClass:y="text-red-700",originalPriceColorClass:b="text-gray-400",descriptionColorClass:v="text-gray-900"}=c,[j,C]=(0,u.useState)(!1),N=e.price&&e.price.total_discount&&e.price.price_with_discount_applied||e.price&&e.price.discount&&void 0!==e.price.discount.discounted_price,O=e.description.length>T+75,E=(0,x.A)(f()(e.description),T,{html:!0});return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:`mb-2 text-lg font-medium truncate ${d}`,children:e.title}),e.subtitle?(0,a.jsx)("div",{className:`mb-2 text-lg font-medium ${h}
19`,children:e.subtitle}):null,(0,a.jsxs)("div",{className:`mb-2 text-lg font-medium ${g}`,children:[e.price.recurring&&(0,a.jsxs)(a.Fragment,{children:[`${(0,m.O)(e.price.amount,e.price.currency)} / `,(0,a.jsx)(r.default,{billingInterval:e.price.recurring.billing_interval,billingIntervalCount:e.price.recurring.billing_interval_count})]}),N&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("span",{className:`text-xl ${y}`,children:[(0,m.O)(e.price.price_with_discount_applied||e.price.discount.discounted_price,e.price.currency)," "]}),(0,a.jsx)(S,{className:b,children:(0,m.O)(e.price.amount,e.price.currency)})]}),!N&&!e.price.recurring&&(0,a.jsx)("span",{className:g,children:(0,m.O)(e.price.amount,e.price.currency)})]}),!t&&(0,a.jsx)(i.default,{voucherWarning:s,textColor:h}),(0,a.jsxs)("div",{className:"w-full",children:[(0,a.jsx)("p",{className:`text-lg ${v}`,children:O?(0,a.jsx)(a.Fragment,{children:(0,a.jsx)(l.default,{text:j?e.description:E})}):(0,a.jsx)(l.default,{text:e.description})}),O&&!j&&(0,a.jsx)("div",{className:"mt-1",children:(0,a.jsx)(o.default,{basic:!0,size:"px-1 py-1",className:"w-auto text-base outline-none",onClick:()=>C(!0),children:(0,a.jsx)(p.A,w({},n.default.readMore))})}),O&&j&&(0,a.jsx)("div",{className:"mt-1",children:(0,a.jsx)(o.default,{basic:!0,size:"px-1 py-1",className:"w-auto text-base outline-none",onClick:()=>C(!1),children:(0,a.jsx)(p.A,w({},n.default.showLess))})})]})]})}N.propTypes={item:d().shape({title:d().string,description:d().string,subtitle:d().string,price:d().shape({amount:d().number,currency:d().string,recurring:d().oneOfType([d().shape({billingInterval:d().oneOf(["day","week","month","year"]),billingIntervalCount:d().number}),d().bool])})}),disableVoucher:d().bool,voucherWarning:d().shape({containerClasses:d().string,textClasses:d().string}),classes:d().shape({titleColorClass:d().string,subtitleColorClass:d().string,priceColorClass:d().string,discountPriceColorClass:d().string,originalPriceColorClass:d().string,descriptionColorClass:d().string})};const O=N},16169:(e,t,s)=>{s.r(t),s.d(t,{Stepper:()=>h,default:()=>f});var a=s(74848),r=(s(96540),s(67438)),o=s(5556),l=s.n(o),n=s(91606),i=Object.defineProperty,c=Object.getOwnPropertySymbols,d=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable,p=(e,t,s)=>t in e?i(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,m=(e,t)=>{for(var s in t||(t={}))d.call(t,s)&&p(e,s,t[s]);if(c)for(var s of c(t))u.call(t,s)&&p(e,s,t[s]);return e};function h({currentStep:e=0,stepStylingClasses:t}){const{activeTextClass:s,regularTextClass:o,activeBorderClass:l,regularBorderClass:i}=t;return(0,a.jsx)("div",{className:"relative py-4 w-full",children:(0,a.jsxs)("div",{className:"flex",children:[(0,a.jsx)("div",{className:`absolute w-full border-t border-r-0 border-b-0 border-l-0 border-solid opacity-75 ${i}`,style:{top:"60%",height:"1px",transform:"translate(0, 0)"}}),(0,a.jsx)("div",{className:`absolute w-full border-t border-r-0 border-b-0 border-l-0 border-solid opacity-75 ${l}`,style:{top:"60%",width:0===e?"0%":2===e?"100%":"50%",height:"1px",transform:"translate(0, 0)"}}),(0,a.jsxs)("div",{className:"justify-start w-1/3",children:[(0,a.jsx)("div",{className:`text-lg text-left md:text-base mb-1 ${0===e?"font-medium":""} ${e>=0?s:o}`,children:(0,a.jsx)(r.A,m({},n.default.account))}),(0,a.jsx)("div",{className:"relative mb-2",children:(0,a.jsx)("div",{className:`w-4 h-4 border border-solid ml-0 bg-white rounded-full text-sm text-white flex items-center ${e>=0?l:i}`})})]}),(0,a.jsxs)("div",{className:"w-1/3",children:[(0,a.jsx)("div",{className:`text-lg text-center md:text-base mb-1 ${1===e?"font-medium":""} ${e>=1?s:o}`,children:(0,a.jsx)(r.A,m({},n.default.payment))}),(0,a.jsx)("div",{className:"relative mb-2",children:(0,a.jsx)("div",{className:`w-4 h-4 border border-solid mx-auto bg-white rounded-full text-sm text-white flex items-center ${e>=1?l:i}`})})]}),(0,a.jsxs)("div",{className:"w-1/3",children:[(0,a.jsx)("div",{className:`text-lg text-right md:text-base mb-1 ${2===e?"font-medium":""} ${e>=2?s:o}`,children:(0,a.jsx)(r.A,m({},n.default.startWatching))}),(0,a.jsx)("div",{className:"relative mb-2",children:(0,a.jsx)("div",{className:`w-4 h-4 border border-solid mr-0 ml-auto bg-white rounded-full text-sm text-white flex items-center ${e>=2?l:i}`})})]})]})})}h.propTypes={currentStep:l().number,stepStylingClasses:l().shape({activeTextClass:l().string,regularTextClass:l().string,activeBorderClass:l().string,regularBorderClass:l().string})};const f=h},92840:(e,t,s)=>{s.r(t),s.d(t,{SuccessPage:()=>S,default:()=>T});var a=s(74848),r=s(50321),o=s(24712),l=s(23114),n=s(5556),i=s.n(n),c=(s(96540),s(67438)),d=s(78210),u=s(57644),p=s(40288),m=s(91606),h=Object.defineProperty,f=Object.defineProperties,g=Object.getOwnPropertyDescriptors,x=Object.getOwnPropertySymbols,y=Object.prototype.hasOwnProperty,b=Object.prototype.propertyIsEnumerable,v=(e,t,s)=>t in e?h(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,j=(e,t)=>{for(var s in t||(t={}))y.call(t,s)&&v(e,s,t[s]);if(x)for(var s of x(t))b.call(t,s)&&v(e,s,t[s]);return e},C=(e,t)=>f(e,g(t));const w=new URLSearchParams(window.location.search);function S({purchaseCompleted:e,classes:t={icon:"text-3xl text-primary",title:"mb-0 text-xl md:text-2xl text-gray-900",subtitle:"text-sm text-gray-900 md:text-base"}}){const{user:s}=(0,d.Jd)(),n=w.get("app_url"),i=(()=>
19{if(!n)return null;try{const e=decodeURIComponent(n),t=e.match(/^([a-zA-Z][a-zA-Z0-9+.-]*):/);if(!t)return null;const s=t[1].toLowerCase();return["http","https","javascript","data","vbscript","file","blob"].includes(s)?(console.log("Blocked dangerous URL scheme:",s),null):e}catch(e){return console.error("Error decoding app fallback URL:",e),null}})();return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex flex-row justify-start items-center mb-4",children:[(0,a.jsx)(o.default,{icon:["far","check-circle"],className:t.icon}),(0,a.jsxs)("div",{className:"flex flex-col justify-start ml-4",children:[(0,a.jsx)("h3",{className:t.title,children:(0,a.jsx)(l.default,{text:e.text})}),(0,a.jsx)("p",{className:t.subtitle,children:(0,a.jsx)(c.A,C(j({},m.default.confirmationNotice),{values:{email:s&&s.email?s.email:""}}))})]})]}),(0,a.jsxs)("div",{className:"flex flex-col gap-3",children:[i&&(0,a.jsx)(r.default,{onClick:()=>{window.location.href=i},dataTestid:"checkout-success-open-app",children:(0,a.jsx)(c.A,j({},m.default.openInApp))}),(0,a.jsx)(r.default,{basic:!!i,onClick:()=>{window.location.href=(0,p.i)(w.get("cta"))||`/${(0,u.rN)()||""}`},dataTestid:"checkout-success-continue",children:e.buttonText&&!Object.values(e.buttonText).every((e=>""===e))?(0,a.jsx)(l.default,{text:e.buttonText}):i?(0,a.jsx)(c.A,j({},m.default.continueOnWeb)):(0,a.jsx)(c.A,j({},m.default.startWatching))})]})]})}S.propTypes={purchaseCompleted:i().shape({text:i().oneOfType([i().string,i().object]),buttonText:i().oneOfType([i().string,i().object])}),classes:i().shape({icon:i().string,title:i().string,subtitle:i().string})};const T=S},54203:(e,t,s)=>{s.r(t),s.d(t,{createPaymentSession:()=>r,createPaymentSessionResult:()=>l,trackCheckoutStep:()=>o});var a=s(43221);function r(){const e=new URLSearchParams(window.location.search),t=Array.from(e.entries()).filter((([e,t])=>e.startsWith("AG_")||e.startsWith("em_"))).map((([e,t])=>t));return{type:a.CREATE_PAYMENT_SESSION,payload:{livestreamId:e.get("l"),subscriptionId:e.get("s"),videoId:e.get("v"),packageId:e.get("pa"),embed:parseInt(e.get("embed"),10)||t[0],useEmbedCollection:e.get("u_e_c"),voucher:e.get("voucher")}}}const o=e=>({type:a.TRACK_CHECKOUT_STEP,payload:e}),l=e=>({type:a.CREATE_PAYMENT_SESSION_RESULT,payload:e})},43221:(e,t,s)=>{s.r(t),s.d(t,{CHECKOUT_STEPS:()=>n,CREATE_PAYMENT_SESSION:()=>a,CREATE_PAYMENT_SESSION_RESULT:()=>r,ERROR_STATES:()=>o,TRACK_CHECKOUT_STEP:()=>l});const a="app/CheckoutProvider/CREATE_PAYMENT_SESSION",r="app/CheckoutProvider/CREATE_PAYMENT_SESSION_RESULT",o={geoBlocked:"GEO_BLOCKED",noPaymentRequired:"NO_PAYMENT_REQUIRED",notFound:"NOT_FOUND",notSignedIn:"NOT_SIGNED_IN",notAvailable:"NOT_AVAILABLE",canBuy:"CAN_BUY",canBuyAdmin:"CAN_BUY_ADMIN",hasPaid:"HAS_PAID",hasPaidPastDue:"HAS_PAID_PAST_DUE",notForSale:"NOT_FOR_SALE",externalSubscription:"EXTERNAL_SUBSCRIPTION",userCanUnlock:"USER_CAN_UNLOCK",voucherNotApplicable:"VOUCHER_NOT_APPLICABLE",checkoutProblem:"CHECKOUT_PROBLEM"},l="app/CheckoutProvider/TRACK_CHECKOUT_STEPS",n={beginCheckout:"BEGIN_CHECKOUT",wrongPassword:"WRONG_PASSWORD",choosePayment:"CHOOSE_PAYMENT",success:"SUCCESS",stripePaymentInit:"STRIPE_INIT",stripeDropout:"STRIPE_DROPOUT",swishPaymentInit:"SWISH_INIT",voucherPaymentInit:"VOUCHER_INIT"}},53920:(e,t,s)=>{s.r(t),s.d(t,{CheckoutProvider:()=>J,default:()=>Q});var a=s(74848),r=s(96540),o=s(5556),l=s.n(o),n=s(16683),i=s(1081),c=s(67438),d=s(40260),u=s(74980),p=s(39522),m=s(17386),h=s(15422),f=s(78777),g=s(50321),x=s(78210),y=s(57644),b=s(47767),v=s(14727),j=s(67375),C=s(2302),w=s(40980),S=s(46658),T=s(43221),N=s(54203),O=s(19917),E=s(16169),A=s(92840),_=s(73809),P=s(56569),k=s(70840),I=s(93319),$=s(1802),M=s(30984),R=s(60157),D=s(91606),L=s(39037),U=s(21852),F=s(67894),B=s(40288),V=s(30126),H=Object.defineProperty,W=Object.getOwnPropertySymbols,Y=Object.prototype.hasOwnProperty,K=Object.prototype.propertyIsEnumerable,G=(e,t,s)=>t in e?H(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,z=(e,t)=>{for(var s in t||(t={}))Y.call(t,s)&&G(e,s,t[s]);if(W)for(var s of W(t))K.call(t,s)&&G(e,s,t[s]);return e};const q=(0,i.j8)({checkoutProvider:(0,C.default)(),cmsPreview:(0,m.makeSelectCmsPreviewMode)(),platform:(0,m.makeSelectPlatform)()});function J({showSteps:e=!0,purchaseCompleted:t={text:"You purchase is now completed!",buttonText:null},menu:s,wrapperStylingClasses:o="",cardStylingClasses:l="p-4 bg-white rounded-md shadow-lg",stepStylingClasses:i={activeTextClass:"text-black",regularTextClass:"text-gray-500",activeBorderClass:"border-black",regularBorderClass:"border-gray-500"},validateEmailText:m=null,voucherWarning:C={containerClasses:"flex items-center justify-center p-2 text-center bg-yellow-100 rounded mb-4",textClasses:"font-semibold text-yellow-600"},pickedObjectClasses:H={titleColorClass:"text-primary",subtitleColorClass:"text-primary",priceColorClass:"text-gray-900",discountPriceColorClass:"text-red-700",originalPriceColorClass:"text-gray-400",descriptionColorClass:"text-gray-900"}
19,loginSignupFlowClasses:W={wrapper:"flex flex-col w-full rounded-lg",title:"mb-4 text-2xl font-medium text-gray-900",subtitle:"mb-4 text-lg text-gray-900",connections:{borderColor:"border-zinc-400",textColor:"text-zinc-300"}},signup:Y,successPageClasses:K={icon:"text-3xl text-primary",title:"mb-0 text-xl md:text-2xl text-gray-900",subtitle:"text-sm text-gray-900 md:text-base"},alreadyHaveAccessClasses:G={title:"mb-0 text-xl md:text-2xl text-gray-900",subtitle:"text-lg text-gray-900 mb-4"},giftcardFormClasses:J={label:"block font-medium text-gray-900",input:"mt-2 active:border-primary active:outline-none appearance-none bg-white border border-solid focus focus:border-primary focus:outline-none form-input input pb-4 pt-4 px-3 rounded-md shadow-none w-full",errorText:"mt-1 text-red-600",checkbox:"mt-1 mr-2 border border-solid cursor-pointer form-checkbox border-primary text-primary",sendoutDateLabel:"text-gray-900 text-md"}}){var Q,Z,X;(0,u.N)({key:"checkoutProvider",reducer:w.default}),(0,d.f)({key:"checkoutProvider",saga:S.default});const ee=(0,n.wA)(),{user:te,isLoading:se}=(0,x.Jd)(),ae=(0,b.zy)(),re=(0,F.R)(),oe=new URLSearchParams(window.location.search);(0,r.useEffect)((()=>{(0,V.Gl)()&&le()}),[window.expNative]);const le=()=>{(0,V.Gl)()&&window.expNative.showNativePaywall&&(window.expNative.showNativePaywall(`https://${window.location.hostname}${(0,B.i)(oe.get("cta"))||"/"}`),window.location.href=(0,B.i)(oe.get("cta"))||"/")},[ne,ie]=(0,r.useState)(!1),{checkoutProvider:ce,cmsPreview:de,platform:ue}=(0,n.d4)(q),pe=(null==(Q=null==ce?void 0:ce.checkout)?void 0:Q.embed_options)&&null!==(null==(Z=null==ce?void 0:ce.checkout)?void 0:Z.embed_options);(0,r.useEffect)((()=>{de||(oe.get("l")||oe.get("s")||oe.get("v")||oe.get("pa"))&&(se||ee((0,N.createPaymentSession)()))}),[te,se,null==ae?void 0:ae.search]);const me=(0,r.useMemo)((()=>function({checkoutProvider:e,platform:t,referrerData:s,user:a}){var r;return V.Tv.includes(t.uid)?(0,V.Gu)({checkoutProvider:e,referrerData:s,user:a}).replace("[redirect_uri_cta]",encodeURIComponent(`${new URLSearchParams(window.location.search).get("cta")||"/"}`)):null==(r=null==e?void 0:e.item)?void 0:r.external_subscription_signup_url}({checkoutProvider:ce,platform:ue,referrerData:re,user:te})),[ce,ue,re,te]);(0,r.useEffect)((()=>{var e,t,s,a,r,o;de||ce&&"INIT"!==ce.state&&(oe.get("success")?(ee((0,N.trackCheckoutStep)({step:T.CHECKOUT_STEPS.success,user:te,content:ce})),(0,v.track)("CheckoutSuccess",{props:{step:ce.state,product:null==(e=null==ce?void 0:ce.item)?void 0:e.title,product_type:null==(t=null==ce?void 0:ce.item)?void 0:t.type}})):oe.get("dropout_stripe")?(ee((0,N.trackCheckoutStep)({step:T.CHECKOUT_STEPS.stripeDropout,user:te})),(0,v.track)("CheckoutDropout",{props:{step:ce.state,product:null==(s=null==ce?void 0:ce.item)?void 0:s.title,product_type:null==(a=null==ce?void 0:ce.item)?void 0:a.type}})):!1===[T.ERROR_STATES.canBuy,T.ERROR_STATES.canBuyAdmin,T.ERROR_STATES.notSignedIn].includes(ce.state)&&(ee((0,N.trackCheckoutStep)({step:ce.state,user:te})),(0,v.track)("CheckoutProblem",{props:{step:ce.state,product:null==(r=null==ce?void 0:ce.item)?void 0:r.title,product_type:null==(o=null==ce?void 0:ce.item)?void 0:o.type}})))}));const he=de&&"GIFTCARD"===(null==(X=ce.item)?void 0:X.type);return oe.get("g")||he?(0,a.jsxs)("div",{className:o,children:[(0,a.jsx)(O.default,{settings:s}),(0,a.jsx)("div",{className:"flex flex-col w-full max-w-lg min-h-screen pt-0 mx-auto md:pt-8",children:(0,a.jsx)("div",{className:"flex flex-col content-between w-full p-3 space-y-5 md:p-0",children:(0,a.jsx)(L.default,{cardStylingClasses:l,pickedObjectClasses:H,giftcardFormClasses:J,previewGiftcard:he?ce.item:null})})}),(0,a.jsx)(j.default,{id:"d55fb792-6ab0-476a-8c55-60ee3696ad0a"})]}):(0,a.jsxs)("div",{className:o,children:[s&&(0,a.jsx)(O.default,{settings:s}),(0,a.jsx)("div",{className:"flex flex-col w-full max-w-lg min-h-screen pt-0 mx-auto md:pt-8",children:(0,a.jsxs)("div",{className:"flex flex-col content-between w-full p-3 space-y-5 md:p-0",children:["INIT"===ce.state&&(0,a.jsx)("div",{className:"mx-auto text-center",children:(0,a.jsx)(h.default,{})}),ce.state===T.ERROR_STATES.voucherNotApplicable&&(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(R.default,{header:(0,a.jsx)(c.A,z({},D.default.voucherNotApplicable)),subheader:(0,a.jsx)(c.A,z({},D.default.voucherNotApplicableDesc)),cta:(0,a.jsx)(c.A,z({},p.default.cancel))})}),ce.state===T.ERROR_STATES.notFound&&(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(R.default,{header:(0,a.jsx)(c.A,z({},D.default.notFound)),subheader:(0,a.jsx)(c.A,z({},D.default.notFoundDescription)),cta:(0,a.jsx)(c.A,z({},p.default.continue))})}),ce.state===T.ERROR_STATES.notForSale&&"true"!==oe.get("success")&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(P.default,{item:ce.item,voucherWarning:C,classes:H})}),(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(R.default,{header:(0,a.jsx)(c.A,z({},D.default.notForSale)),subheader:(0,a.jsx)(c.A,z({},D.default.notForSaleDescription)),cta:(0,a.jsx)(c.A,z({},p.default.continue))})})]}),ce.state===T.ERROR_STATES.notAvailable&&"true"!==oe.get("success")&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(P.default,{item:ce.item,disableVoucher:!0,voucherWarning:C,classes:H})}),(0,a.jsxs)(k.default,{cardStylingClasses:l,children:[!ne&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(R.default,{header:(0,a.jsx)(c.A,z({},D.default.useVoucherToUnlock)),subheader:(0,a.jsx)(c.A,z({},D.default.useVoucherToUnlockDescription))}),(0,a.jsx)(g.default,{"data-testid":"unlock-button",onClick:()=>ie(!0),children:(0,a.jsx)(c.A,z({},D.default.unlock))}),(0,a.jsx)(g.default,{basic:!0,"data-testid":"go-back-button",onClick:()=>{window.location.href=(0,B.i)(oe.get("cta"))||"/"},children:(0,a.jsx)(c.A,z({},p.default.goBack))})]}),ne&&(te?(0,a.jsx)(M.default,{active:!0}
19):(0,a.jsx)($.default,{validateEmailText:m,signup:Y,classes:W}))]})]}),ce.state===T.ERROR_STATES.noPaymentRequired&&"true"!==oe.get("success")&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(P.default,{item:ce.item,voucherWarning:C,classes:H})}),(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(R.default,{header:(0,a.jsx)(c.A,z({},D.default.noPaymentNeeded)),subheader:(0,a.jsx)(c.A,z({},D.default.noPaymentNeededDescription)),cta:(0,a.jsx)(c.A,z({},D.default.startWatching))})})]}),ce.state===T.ERROR_STATES.userCanUnlock&&"true"!==oe.get("success")&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(P.default,{item:ce.item,voucherWarning:C,classes:H})}),pe&&(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(I.default,{textColor:H.descriptionColorClass})}),(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(U.default,{item:ce.item})})]}),ce.state===T.ERROR_STATES.externalSubscription&&(0,a.jsxs)(a.Fragment,{children:[!(0,V.aU)()&&(0,a.jsx)(f.default,{url:me,includeSearch:!1}),(0,V.OS)()&&(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(R.default,{header:"Kan inte fortsätta",subheader:"Detta är inte tillgängligt i appen.",cta:(0,a.jsx)(c.A,z({},p.default.continue))})}),(0,V.Gl)()&&(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(g.default,{"data-testid":"continue-bonnier-button",onClick:()=>le(),children:"Fortsätt"})}),(0,a.jsx)("div",{className:"mx-auto text-center",children:(0,a.jsx)(h.default,{})})]}),ce.state===T.ERROR_STATES.geoBlocked&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(P.default,{item:ce.item,voucherWarning:C,classes:H})}),(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(R.default,{header:(0,a.jsx)(c.A,z({},D.default.geoBlocked)),subheader:(0,a.jsx)(c.A,z({},D.default.geoBlockedDescription))})})]}),"INIT"!==ce.state&&("true"===oe.get("success")||"CMS_SUCCESS_PREVIEW"===ce.state)&&(0,a.jsxs)(a.Fragment,{children:[e&&(0,a.jsx)(E.default,{stepStylingClasses:i,currentStep:2}),(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(A.default,{purchaseCompleted:t,classes:K})})]}),ce.state===T.ERROR_STATES.hasPaidPastDue&&"true"!==oe.get("success")&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(P.default,{item:ce.item,voucherWarning:C,classes:H})}),(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(R.default,{header:(0,a.jsx)(c.A,z({},D.default.pastDue)),subheader:(0,a.jsx)(c.A,z({},D.default.pastDueDescription)),setCta:(0,y.rN)()?`${(0,y.rN)()}/account`:"/account",cta:(0,a.jsx)(c.A,z({},D.default.pastDueAccount))})})]}),[T.ERROR_STATES.canBuyAdmin,T.ERROR_STATES.hasPaid].includes(ce.state)&&"true"!==oe.get("success")&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(P.default,{item:ce.item,voucherWarning:C,classes:H})}),(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(R.default,{header:(0,a.jsx)(c.A,z({},D.default.alreadyAccess)),subheader:(0,a.jsx)(c.A,z({},D.default.alreadyAccessDescription)),cta:"true"===oe.get("is_embed")?(0,a.jsx)(c.A,z({},D.default.pastDueAccount)):(0,a.jsx)(c.A,z({},D.default.startWatching)),classes:G})})]}),ce.state===T.ERROR_STATES.notSignedIn&&"true"!==oe.get("success")&&(0,a.jsxs)(a.Fragment,{children:[e&&(0,a.jsx)(E.default,{stepStylingClasses:i,currentStep:0}),(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(P.default,{item:ce.item,voucherWarning:C,classes:H})}),pe&&(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(I.default,{textColor:H.descriptionColorClass})}),!te&&(0,a.jsx)(k.default,{cardStylingClasses:`${l} mt-5`,children:(0,a.jsx)($.default,{validateEmailText:m,signup:Y,classes:W})})]}),T.ERROR_STATES.canBuy===ce.state&&"true"!==oe.get("success")&&(0,a.jsxs)(a.Fragment,{children:[e&&(0,a.jsx)(E.default,{stepStylingClasses:i,currentStep:1}),(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(P.default,{item:ce.item,voucherWarning:C,classes:H})}),pe&&(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(I.default,{textColor:H.descriptionColorClass})}),(0,a.jsxs)(k.default,{cardStylingClasses:l,children:[!te&&(0,a.jsx)($.default,{voucherWarning:C,validateEmailText:m,signup:Y,classes:W}),te&&(0,a.jsx)(_.default,{voucherWarning:C,pickedObjectClasses:H})]})]}),T.ERROR_STATES.checkoutProblem===ce.state&&"true"!==oe.get("success")&&(0,a.jsx)(a.Fragment,{children:(0,a.jsx)(k.default,{cardStylingClasses:l,children:(0,a.jsx)(R.default,{header:(0,a.jsx)(c.A,z({},D.default.checkoutProblem)),subheader:(0,a.jsx)(c.A,z({},D.default.checkoutProblemDesc))})})})]})}),(0,a.jsx)(j.default,{id:"d55fb792-6ab0-476a-8c55-60ee3696ad0a"})]})}
19J.propTypes={showSteps:l().bool,purchaseCompleted:l().shape({text:l().string,buttonText:l().string}),checkoutProvider:l().shape({state:l().string,item:l().shape({title:l().string,type:l().oneOf(["LIVESTREAM","VIDEO","SUBSCRIPTION","PACKAGE"]),id:l().number,description:l().string,price:l().shape({amount:l().number,currency:l().string,recurring:l().oneOfType([l().shape({billingInterval:l().oneOf(["day","week","month","year"]),billingIntervalCount:l().number}),l().bool])})})}),menu:l().shape({logotype:l().string,style:l().object,menuStylingClasses:l().string,linkStylingClasses:l().string}),wrapperStylingClasses:l().string,cardStylingClasses:l().string,stepStylingClasses:l().shape({activeTextClass:l().string,regularTextClass:l().string,activeBorderClass:l().string,regularBorderClass:l().string}),validateEmailText:l().string,voucherWarning:l().shape({containerClasses:l().string,textClasses:l().string}),pickedObjectClasses:l().shape({titleColorClass:l().string,subtitleColorClass:l().string,priceColorClass:l().string,discountPriceColorClass:l().string,originalPriceColorClass:l().string,descriptionColorClass:l().string}),loginSignupFlowClasses:l().shape({wrapper:l().string,title:l().string,subtitle:l().string,connections:l().shape({borderColor:l().string,textColor:l().string})}),signup:l().shape({title:l().shape({text:l().objectOf(l().string),classes:l().string}),description:l().shape({text:l().objectOf(l().string),classes:l().string})}),successPageClasses:l().shape({icon:l().string,title:l().string,subtitle:l().string}),alreadyHaveAccessClasses:l().shape({title:l().string,subtitle:l().string}),giftcardFormClasses:l().shape({label:l().string,input:l().string,errorText:l().string,checkbox:l().string,sendoutDateLabel:l().string})};const Q=J},91606:(e,t,s)=>{s.r(t),s.d(t,{default:()=>o,scope:()=>r});var a=s(11164);const r="app.containers.CheckoutProvider",o=(0,a.YK)({confirmationNotice:{id:`${r}.confirmationNotice`,defaultMessage:"A confirmation has been sent to {email}"},openInApp:{id:`${r}.openInApp`,defaultMessage:"Open app"},continueOnWeb:{id:`${r}.continueOnWeb`,defaultMessage:"Continue on web"},account:{id:`${r}.stepper.account`,defaultMessage:"Account"},payment:{id:`${r}.stepper.payment`,defaultMessage:"Payment"},startWatching:{id:`${r}.stepper.startWatching`,defaultMessage:"Watch"},alreadyAccess:{id:`${r}.alreadyAccess`,defaultMessage:"Already access"},alreadyAccessDescription:{id:`${r}.alreadyAccessDescription`,defaultMessage:"It looks like the account you have signed in with already has access to this."},pastDue:{id:`${r}.pastDue`,defaultMessage:"Inactive subscription"},pastDueDescription:{id:`${r}.pastDueDescription`,defaultMessage:"You are already on a subscribtion, but the payment for your subscription has failed and the subscription is currently inactive. Please retry the payment under account settings."},pastDueAccount:{id:`${r}.pastDueAccount`,defaultMessage:"Go to account settings"},geoBlocked:{id:`${r}.geoBlocked`,defaultMessage:"Not available"},geoBlockedDescription:{id:`${r}.geoBlockedDescription`,defaultMessage:"This content is not available in your area."},noPaymentNeeded:{id:`${r}.noPaymentNeeded`,defaultMessage:"Payment not needed"},noPaymentNeededDescription:{id:`${r}.noPaymentNeededDescription`,defaultMessage:"This content does not require you to pay."},notFound:{id:`${r}.notFound`,defaultMessage:"Not found."},notFoundDescription:{id:`${r}.notFoundDescription`,defaultMessage:"The content you tried to purchase was not found."},notForSale:{id:`${r}.notForSale`,defaultMessage:"Not for sale"},notForSaleDescription:{id:`${r}.notForSaleDescription`,defaultMessage:"The content you tried to access is not for sale."},showLess:{id:`${r}.showLess`,defaultMessage:"Show less"},nothingSelected:{id:`${r}.nothingSelected`,defaultMessage:"Nothing selected"},sortAlphabetically:{id:`${r}.sortAlphabetically`,defaultMessage:"Sort alphabetically"},useVoucherToUnlock:{id:`${r}.useVoucherToUnlock`,defaultMessage:"Use a voucher"},useVoucherToUnlockDescription:{id:`${r}.useVoucherToUnlockDescription`,defaultMessage:"You need a voucher to unlock this content"},unlock:{id:`${r}.unlock`,defaultMessage:"Unlock"},voucherNotApplicable:{id:`${r}.voucherNotApplicable`,defaultMessage:"This voucher can not be used"},voucherNotApplicableDesc:{id:`${r}.voucherNotApplicableDesc`,defaultMessage:"The total amount of the content after applying the voucher is to low"},checkoutProblem:{id:`${r}.checkoutProblem`,defaultMessage:"Server error"},checkoutProblemDesc:{id:`${r}.checkoutProblemDesc`,defaultMessage:"There was an issue when checking out. Please try again later."}})},40980:(e,t,s)=>{s.r(t),s.d(t,{default:()=>l,initialState:()=>o});var a=s(64852),r=s(43221);const o={state:"INIT",error:null,item:{},checkout:{stripe:"",voucher:{enabled:!0},swish:{enabled:!0}}},l=(e=o,t)=>(0,a.Ay)(e,(e=>{switch(t.type){case r.CREATE_PAYMENT_SESSION:e.state="INIT";break;case r.CREATE_PAYMENT_SESSION_RESULT:e.state=t.payload.message.type,t.payload.message.error?(e.item=t.payload.message.content||{},e.error=t.payload.message.error,e.checkout=t.payload.message.checkout):(e.error=!1,e.item=t.payload.message.content,e.checkout=t.payload.message.checkout)}}))},46658:(e,t,s)=>{s.r(t),s.d(t,{createPaymentSession:()=>b,default:()=>v});var a=s(43786),r=s(72748),o=s(32689),l=s(30727),n=s(17386),i=s(43221),c=s(54203),d=Object.defineProperty,u=Object.defineProperties,p=Object.getOwnPropertyDescriptors,m=Object.getOwnPropertySymbols,h=Object.prototype.hasOwnProperty,f=Object.prototype.propertyIsEnumerable,g=(e,t,s)=>t in e?d(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,x=(e,t)=>{for(var s in t||(t={}))h.call(t,s)&&g(e,s,t[s]);if(m)for(var s of m(t))f.call(t,s)&&g(e,s,t[s]);return e},y=(e,t)=>u(e,p(t));function*b(e){const{livestreamId:t,subscriptionId:s,videoId:i,packageId:d,embed:u,voucher:p,useEmbedCollection:m}=e.payload,h=yield(0,a.T1)(l.wz),f=yield(0,a.T1)(l.k0),g=yield(0,a.Lt)((0,n.makeSelectPlatform)());try{const e=`${o.DEFAULT_STAYLIVE_API}platforms/${g.uid}/checkouts/${t?`livestream/${t}`:s?`subscription/${s}`:i?`video/${i}`:d?`package/${d}`:new Error("No type defined")}`,l=yield(0,a.T1)(r.Ay,e,{method:"POST",body:JSON.stringify({return_url:window.location.href,embed:u,use_embed_collection:m,voucher:p}),headers:f?{"Content-Type":"application/json",Authorization:`Bearer ${f}`}:{"Content-Type":"application/json"}});l.message&&(l.message.userData={id:h&&h.metadata?h.metadata.id:null,isLoggedIn:!!h}),yield(0,a.yJ)((0,c.createPaymentSessionResult)({message:l.message,success:!0}))}catch(e){switch(console.error("[Checkout response]",e),e.response.status){case 400:case 401:case 403:yield(0,a.yJ)((0,c.createPaymentSessionResult)({message:y(x({},e.json.message),{error:!0})}
19));break;default:yield(0,a.yJ)((0,c.createPaymentSessionResult)({message:{type:"CHECKOUT_PROBLEM",error:!0}}))}}}function*v(){yield(0,a.p8)(i.CREATE_PAYMENT_SESSION,b)}},2302:(e,t,s)=>{s.r(t),s.d(t,{default:()=>c,makeSelectCheckoutIds:()=>i,makeSelectCheckoutItem:()=>n,makeSelectEmbed:()=>l,selectCheckoutProviderDomain:()=>o});var a=s(1081),r=s(40980);const o=e=>e.checkoutProvider||r.initialState,l=()=>(0,a.Mz)(o,(e=>{var t;return null==(t=null==e?void 0:e.checkout)?void 0:t.embed_options})),n=()=>(0,a.Mz)(o,(e=>e.item)),i=()=>(0,a.Mz)(o,(e=>e.checkout)),c=()=>(0,a.Mz)(o,(e=>e))},32946:(e,t,s)=>{s.r(t),s.d(t,{default:()=>i});var a=s(74848),r=(s(96540),s(5556)),o=s.n(r),l=s(23114);const n=({classes:e,text:t})=>t&&Object.values(t).some((e=>(null==e?void 0:e.length)>0))?(0,a.jsx)("h5",{className:e,children:(0,a.jsx)(l.default,{text:t})}):null;n.propTypes={text:o().object,classes:o().string};const i=n},85882:(e,t,s)=>{s.r(t),s.d(t,{default:()=>i});var a=s(74848),r=(s(96540),s(5556)),o=s.n(r),l=s(23114);const n=({classes:e,text:t})=>(0,a.jsx)("h3",{className:e||"inline-block align-middle m-0 font-medium text-2xl sm:text-3xl md:text-4xl truncate text-gray-900",children:(0,a.jsx)(l.default,{text:t})});n.propTypes={classes:o().string,text:o().string};const i=n},3861:(e,t,s)=>{s.r(t),s.d(t,{contentClickAction:()=>l,loadContentAction:()=>r,loadContentCompletedAction:()=>o});var a=s(15719);function r(e){return{type:a.LOAD_CONTENT,payload:e}}function o(e){return{type:a.LOAD_CONTENT_COMPLETED,payload:e}}function l(e){return{type:a.CONTENT_CLICK,payload:e}}},15719:(e,t,s)=>{s.r(t),s.d(t,{CONTENT_CLICK:()=>o,CONTENT_TYPES:()=>n,LOAD_CONTENT:()=>a,LOAD_CONTENT_COMPLETED:()=>r,STATUS:()=>l,contentTypesWithStatus:()=>i});const a="app/ContentFeed/LOAD_CONTENT",r="app/ContentFeed/LOAD_CONTENT_COMPLETED",o="app/ContentFeed/CONTENT_CLICK",l={inital:"INIT",loading:"LOADING",success:"SUCCESS",error:"ERROR"},n={liveStreamCategories:"LIVESTREAM_CATEGORIES",liveStreamCollection:"LIVESTREAM_COLLECTION",liveStreamChannels:"LIVESTREAM_CHANNELS",liveStreamCollectionCategory:"LIVESTREAM_COLLECTION_CATEGORY",liveStreamChannelTags:"LIVESTREAM_CHANNEL_TAGS",videoCategories:"VIDEO_CATEGORIES",videoCollection:"VIDEO_COLLECTION",videoChannels:"VIDEO_CHANNELS",videoCollectionCategory:"VIDEO_COLLECTION_CATEGORY",videoChannelTags:"VIDEO_CHANNEL_TAGS",videoCollectionTags:"VIDEO_COLLECTION_TAGS",videoPlaylist:"VIDEO_PLAYLIST",livestreamCollectionTags:"LIVESTREAM_COLLECTION_TAGS",videoContinueWatching:"VIDEO_CONTINUE_WATCHING"},i=[n.liveStreamChannels,n.liveStreamCollection,n.livestreamCollectionTags,n.liveStreamChannelTags]},23574:(e,t,s)=>{s.r(t),s.d(t,{ContentFeed:()=>_,default:()=>P});var a=s(74848),r=s(96540),o=s(38267),l=s(5556),n=s.n(l),i=s(82057),c=s(53828),d=s(28946),u=s(70810),p=s(78210),m=s(16683),h=s(1081),f=s(17386),g=s(72748),x=s(60799),y=s(67438),b=s(85882),v=s(56868),j=s(15719),C=Object.defineProperty,w=Object.getOwnPropertySymbols,S=Object.prototype.hasOwnProperty,T=Object.prototype.propertyIsEnumerable,N=(e,t,s)=>t in e?C(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,O=(e,t)=>{for(var s in t||(t={}))S.call(t,s)&&N(e,s,t[s]);if(w)for(var s of w(t))T.call(t,s)&&N(e,s,t[s]);return e},E=(e,t,s)=>new Promise(((a,r)=>{var o=e=>{try{n(s.next(e))}catch(e){r(e)}},l=e=>{try{n(s.throw(e))}catch(e){r(e)}},n=e=>e.done?a(e.value):Promise.resolve(e.value).then(o,l);n((s=s.apply(e,t)).next())}));const A=(0,h.j8)({platform:(0,f.makeSelectPlatform)()});function _({wrapperClasses:e="relative mt-6",containerClasses:t,id:s,title:l,description:n={show:!1,text:{},classes:"mt-1 text-lg truncate text-gray-900"},modalButton:h={showIcon:!1,customHref:{show:!1,url:"/videos"}},type:f,includeCategories:C=!1,showVideoLength:w=!0,cardTitleClasses:S,cardDateClasses:T,displayChannelName:N=!1,tags:_=null,customHref:P=null,showYear:k,hoverMode:I="lift",backgroundImage:$,showTime:M=!0,dateRangeFilter:R=null,cardAspectRatio:D="16/9",cardDensity:L="standard",innerWrapperClasses:U="relative flex items-baseline justify-between px-4 lg:px-10",scrollContainerClasses:F="block pt-2 mb-8 space-x-4 overflow-x-scroll overflow-y-hidden whitespace-nowrap px-4 lg:px-10",dateLabel:B,allTagsRequired:V=!1,progressbarClasses:H}){const W=Array.from(Array(10).keys()),[Y,K]=(0,p.BL)({threshold:1,root:null,rootMargin:"150px"}),[G]=(0,r.useState)(Math.random().toString(36).substring(7)),z=o.Ay.div`
20    background-color: #505050;
21  `,{platform:q}=(0,m.d4)(A),{data:J,error:Q,totalPages:Z,size:X,setSize:ee,isValidating:te,mutate:se}=(0,u.Ay)({type:f,id:s,limit:20,page:1,includeCategories:C,tags:_,revalidateOnFocus:!1,onScreen:(null==K?void 0:K.isIntersecting)||!1,dateRangeFilter:R,sortFunction:(e,t)=>!M&&j.contentTypesWithStatus.includes(f)?"CONNECTED"===e.status?-1:"CONNECTED"===t.status?1:0:0,allTagsRequired:V}),ae=f===j.CONTENT_TYPES.videoContinueWatching?e=>E(this,null,(function*(){try{yield(0,g.tX)(`platforms/${q.uid}/watch-history/${e}`),se(),x.Ay.success((0,a.jsx)(y.A,O({},v.default.removeSuccess)))}catch(e){x.Ay.error((0,a.jsx)(y.A,O({},v.default.removeError)))}})):void 0;return null!==J||Q?Q||!J.length?null:(0,a.jsx)(i.default,{wrapperClasses:e,containerClasses:t,content:J,contentType:f,title:l,description:n,styledTitle:(0,a.jsx)(b.default,O({},l)),modalButton:h,index:G,loadMoreContent:()=>ee?ee(X+1):null,totalPages:Z,currentPagination:X,showVideoLength:w,cardTitleClasses:S,cardDateClasses:T,displayChannelName:N,customHref:P,showYear:k,isValidating:te,hoverMode:I,backgroundImage:$,showTime:M,cardAspectRatio:D,cardDensity:L,innerWrapperClasses:U,scrollContainerClasses:F,isProducts:!1,dateLabel:B,progressbarClasses:H,onRemoveItem:ae}):(0,a.jsxs)("div",{className:"relative mt-6",children:[(0,a.jsx)("div",{className:U,children:(0,a.jsx)(z,{className:"w-1/2 h-10 rounded-md md:w-1/5"})}),(0,a.jsx)(c.default,{className:F,ref:Y,children:W.map((e=>(0,a.jsx)(d.default,{contentType:f,displayChannelName:N,cardAspectRatio:D,cardDensity:L},e)))})]})}
21_.propTypes={id:n().oneOfType([n().string,n().array]).isRequired,title:n().shape({text:n().oneOfType([n().string,n().object]),classes:n().string}),description:n().shape({show:n().bool,text:n().oneOfType([n().string,n().object]),classes:n().string}),modalButton:n().shape({text:n().oneOfType([n().string,n().object]),classes:n().string}),type:n().oneOf(Object.keys(j.CONTENT_TYPES).map((e=>j.CONTENT_TYPES[e]))).isRequired,includeCategories:n().bool,showVideoLength:n().bool,cardTitleClasses:n().string,cardDateClasses:n().string,displayChannelName:n().bool,tags:n().oneOfType([n().string,n().array]),customHref:n().string,showYear:n().bool,wrapperClasses:n().string,containerClasses:n().string,hoverMode:n().oneOf(["lift","zoomLarge","zoomSmall","enlarge"]),backgroundImage:n().shape({show:n().bool,imageUrl:n().string,classes:n().string,tintColor:n().string,tintOpacity:n().oneOfType([n().number,n().string])}),showTime:n().bool,dateRangeFilter:n().shape({start:n().string,end:n().string}),cardAspectRatio:n().string,cardDensity:n().oneOf(["few","standard","many"]),innerWrapperClasses:n().string,scrollContainerClasses:n().string,dateLabel:n().shape({upcomingContainerClasses:n().string,upcomingTextClasses:n().string,liveContainerClasses:n().string,liveTextClasses:n().string}),allTagsRequired:n().bool,progressbarClasses:n().string};const P=_},56868:(e,t,s)=>{s.r(t),s.d(t,{default:()=>r});const a="app.containers.ContentFeed",r=(0,s(11164).YK)({removeSuccess:{id:`${a}.removeSuccess`,defaultMessage:"Video removed from watch history"},removeError:{id:`${a}.removeError`,defaultMessage:"Failed to remove video. Please try again"}})},50397:(e,t,s)=>{s.r(t),s.d(t,{default:()=>a});const a=(0,s(40313).A)((()=>Promise.all([s.e(7774),s.e(3049),s.e(1268),s.e(45),s.e(644),s.e(4899),s.e(2009),s.e(8117),s.e(8740),s.e(2116),s.e(9374),s.e(6486),s.e(6076),s.e(9761),s.e(1326),s.e(4622),s.e(628)]).then(s.bind(s,74501))))},21885:(e,t,s)=>{s.r(t),s.d(t,{changeLocale:()=>r});var a=s(76623);function r(e){return{type:a.CHANGE_LOCALE,locale:e}}},76623:(e,t,s)=>{s.r(t),s.d(t,{CHANGE_LOCALE:()=>a});const a="app/LanguageToggle/CHANGE_LOCALE"},92574:(e,t,s)=>{s.r(t),s.d(t,{LanguageProvider:()=>u,default:()=>m});var a=s(74848),r=s(96540),o=s(5556),l=s.n(o),n=s(16683),i=s(1081),c=s(77267),d=s(73108);function u(e){return(0,a.jsx)(c.A,{locale:e.locale,messages:e.messages[e.locale],children:r.Children.only(e.children)},e.locale)}u.propTypes={locale:l().string,messages:l().object,children:l().element.isRequired};const p=(0,i.Mz)((0,d.makeSelectLocale)(),(e=>({locale:e}))),m=(0,n.Ng)(p,(function(e){return{dispatch:e}}))(u)},79458:(e,t,s)=>{s.r(t),s.d(t,{default:()=>i,initialState:()=>n});var a=s(64852),r=s(76623),o=s(35559);const l=new Date;l.setFullYear(l.getFullYear()+2);const n={locale:o.Xn},i=(e=n,t)=>(0,a.Ay)(e,(e=>{if(t.type===r.CHANGE_LOCALE){e.locale=t.locale;try{document.documentElement.lang=t.locale}catch(e){console.log(e)}}}))},73108:(e,t,s)=>{s.r(t),s.d(t,{makeSelectLocale:()=>l,selectLanguage:()=>o});var a=s(1081),r=s(79458);const o=e=>e.language||r.initialState,l=()=>(0,a.Mz)(o,(e=>e.locale))},41501:(e,t,s)=>{s.r(t),s.d(t,{default:()=>a});const a=(0,s(40313).A)((()=>Promise.all([s.e(7774),s.e(3049),s.e(1268),s.e(45),s.e(644),s.e(4899),s.e(2009),s.e(8117),s.e(8740),s.e(2116),s.e(9374),s.e(6486),s.e(6076),s.e(9761),s.e(1326),s.e(4622),s.e(628)]).then(s.bind(s,8485))))},53613:(e,t,s)=>{s.r(t),s.d(t,{default:()=>a});const a=(0,s(40313).A)((()=>Promise.all([s.e(919),s.e(2285),s.e(2641),s.e(1387),s.e(177),s.e(6392),s.e(7827),s.e(2679),s.e(7774),s.e(3049),s.e(1268),s.e(45),s.e(644),s.e(4899),s.e(2009),s.e(8117),s.e(8740),s.e(2116),s.e(9374),s.e(6486),s.e(6076),s.e(9761),s.e(1326),s.e(4622),s.e(628)]).then(s.bind(s,39637))))},50725:(e,t,s)=>{s.r(t),s.d(t,{PreviewDeploymentSettings:()=>o,default:()=>l}),s(74848);var a=s(96540),r=s(28323);function o(){const[e,t]=a.useState({DEFAULT_API:r.Ay.load("DEFAULT_API")||"https://api.staylive.tv/",DEFAULT_STAYLIVE_API:r.Ay.load("DEFAULT_STAYLIVE_API")||"https://api.staylive.tv/"});return null}s(30261),Object.defineProperty,Object.defineProperties,Object.getOwnPropertyDescriptors,Object.getOwnPropertySymbols,Object.prototype.hasOwnProperty,Object.prototype.propertyIsEnumerable;const l=o}}]);

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.