1import{q as h,D as v,u as y,a7 as k,a9 as z,v as B,w as f,r as x,a6 as C,ak as I,o as l,d as e,f as r,c as d,t as i,b as p,N as j,e as D}from"./CbmoqRZ0.js";(function(){try{var n=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},s=new n.Error().stack;s&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[s]="3aa53835-cdba-402f-992e-7915f24aaef0",n._sentryDebugIdIdentifier="sentry-dbid-3aa53835-cdba-402f-992e-7915f24aaef0")}catch{}})();const M={class:"max-w-[50rem] flex flex-col mx-auto size-full"},N={class:"flex items-center justify-center"},$={class:"text-center py-10 px-4 sm:px-6 lg:px-8"},S={key:0,class:"text-center flex items-center justify-center mb-10"},T={key:1,class:"text-center flex items-center justify-center mb-10"},W={key:2},A={class:"block text-2xl font-bold text-neutral-900 sm:text-4xl mb-10"},E={class:"mt-3 text-lg text-neutral-600"},L={class:"mt-5 flex flex-col justify-center items-center gap-2 sm:flex-row sm:gap-3"},V={key:3},R={class:"block text-2xl font-bold text-neutral-900 sm:text-4xl mb-10"},q={class:"mt-3 text-lg text-neutral-600"},F={class:"mt-auto text-center py-5"},O={class:"max-w-7xl mx-auto px-4 sm:px-6 lg:px-8"},U=h({__name:"confirm",async setup(n){let s,u;const{t:m}=v(),_=y().params.subscriberId,a=x(),c=x();try{const{data:o,error:t}=([s,u]=k(()=>z(`/api/newsletter/subscriber/${_}/confirm`,{method:"POST"},"$n8UWMRp0aY")),s=await s,u(),s);o.value&&(c.value=o.value),t.value&&(t.value.statusCode===400&&t.value.statusMessage==="Subscriber already verified"||(a.value=m("errors.generic")))}catch{a.value=m("errors.generic")}return(o,t)=>{const b=j,w=I("i18n-t"),g=C;return l(),B(g,{name:"landing-subscription"},{default:f(()=>[e("div",M,[t[4]||(t[4]=e("header",{class:"mb-auto flex flex-wrap sm:justify-start sm:flex-nowrap z-50 w-full text-sm"},null,-1)),e("main",N,[e("div",$,[r(a)?(l(),d("div",T,[...t[1]||(t[1]=[e("svg",{class:"text-red-600 h-32 w-32",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},[e("path",{d:"M256 48a208 208 0 1 1 0 416 208 208 0 1 1 0-416zm0 464A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM175 175c-9.4 9.4-9.4 24.6 0 33.9l47 47-47 47c-9.4 9.4-9.4 24.6 0 33.9s24.6 9.4 33.9 0l47-47 47 47c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9l-47-47 47-47c9.4-9.4 9.4-24.6 0-33.9s-24.6-9.4-33.9 0l-47 47-47-47c-9.4-9.4-24.6-9.4-33.9 0z"})],-1)])])):(l(),d("div",S,[...t[0]||(t[0]=[e("svg",{class:"text-neutral-900 h-32 w-32",fill:"currentColor",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},[e("path",{d:"M256 48a208 208 0 1 1 0 416 208 208 0 1 1 0-416zm0 464A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM369 209c9.4-9.4 9.4-24.6 0-33.9s-24.6-9.4-33.9 0l-111 111-47-47c-9.4-9.4-24.6-9.4-33.9 0s-9.4 24.6 0 33.9l64 64c9.4 9.4 24.6 9.4 33.9 0L369 209z"})],-1)])])),r(a)?(l(),d("div",V,[e("h1",R,i(o.$t("errors.somethingWentWrong")),1),e("p",q,i(r(a)),1)])):(l(),d("div",W,[e("h1",A,i(o.$t("confirmSubscription.title",{newsletter:r(c)?.name})),1),e("p",E,i(o.$t("confirmSubscription.description")),1),e("div",L,[p(b,{class:"w-full sm:w-auto py-3 px-4 inline-flex justify-center items-center gap-x-2 text-sm font-semibold rounded-lg border border-transparent bg-neutral-900 text-white hover:bg-neutral-700 disabled:opacity-50 disabled:pointer-events-none",to:r(c)?.url},{default:f(()=>[t[2]||(t[2]=e("svg",{class:"flex-shrink-0 size-4",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},[e("path",{d:"m15 18-6-6 6-6"})],-1)),D(" "+i(o.$t("common.backTo",{blog:r(c)?.name})),1)]),_:1},8,["to"])])]))])]),e("footer",F,[e("div",O,[p(w,{keypath:"footer.poweredBy",tag:"p",class:"text-sm text-neutral-500"},{brand:f(()=>[...t[3]||(t[3]=[e("a",{class:"text-neutral-900 decoration-2 underline underline-offset-2 font-medium hover:text-neutral-600 hover:decoration-neutral-500",href:"https://writizzy.com",target:"_blank",rel:"noopener nofollow"},"Writizzy",-1)])]),_:1})])])])]),_:1})}}});
1export{U as default};
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.