PageSourceSearch

https://kathrynfinney.com/assets/NewsletterCtaWeekly-D678jiVQ.js

js kathrynfinney.com collected 2026-09-25 02:50:54 UTC 4,701 bytes, 1 lines download raw bytes

1import{r as s,u as M,h as q,j as e,E as B,M as R,s as W}from"./main-exKlCx7X.js";function Y({source:t,tone:j="light",buttonLabel:y,layout:u="inline",className:k,shape:N="pill"}){const[x,c]=s.useState(""),[o,m]=s.useState(""),{validity:n,valid:g,onBlur:v,setTouched:$}=M(o),{token:S,widget:F,reset:f}=q(t),p=s.useRef(null),[l,i]=s.useState("idle"),[b,d]=s.useState(""),r=j==="dark";async function C(a){if(a.preventDefault(),l==="loading")return;if(!g){$(!0),setTimeout(()=>R(p.current),0);return}i("loading"),d("");const w=await W({email:o,firstName:x,source:t,medium:"draft_cta",turnstileToken:S});w.ok?(i("ok"),d("You're in. Watch your inbox for the next issue."),m(""),c(""),f()):(i("error"),d(w.error??"Something went wrong."),f())}const h=N==="square"?"rounded-[4px]":"rounded-full",T=`h-12 w-full ${h} border px-5 text-base outline-none transition-colors focus:border-yellow focus:ring-2 focus:ring-foreground/30 md:text-sm ${n.state==="invalid"?"border-red-500":n.state==="valid"?"border-emerald-600":r?"border-background/25 bg-background/5 text-background placeholder:text-background/55":"border-foreground
1/20 bg-background text-foreground placeholder:text-foreground/45"}`,E=`h-12 w-full ${h} border px-5 text-base outline-none transition-colors focus:border-yellow focus:ring-2 focus:ring-foreground/30 md:text-sm ${r?"border-background/25 bg-background/5 text-background placeholder:text-background/55":"border-foreground/20 bg-background text-foreground placeholder:text-foreground/45"}`,D=`group inline-flex h-12 items-center justify-center gap-2 rounded-full px-7 text-[12px] font-semibold uppercase tracking-[0.18em] transition-all duration-200 disabled:opacity-60 ${r?"bg-yellow text-foreground hover:brightness-95":"bg-foreground text-background hover:bg-yellow hover:text-foreground"}`;return e.jsxs("form",{ref:p,onSubmit:C,className:`flex w-full flex-col gap-2 ${k??""}`,children:[e.jsx("label",{htmlFor:`${t}-name`,className:"sr-only",children:"First name"}),e.jsx("input",{id:`${t}-name`,type:"text",autoComplete:"given-name",value:x,onChange:a=>c(a.target.value),placeholder:"First name",className:E}),e.jsxs("div",{className:`flex w-full flex-col gap-2 ${u==="inline"?"sm:flex-row":""}`,children:[e.jsx("label",{htmlFor:`${t}-email`,className:"sr-only",children:"Email address"}),e.jsx("input",{id:`${t}-email`,type:"email",inputMode:"email",autoComplete:"email",required:!0,"aria-invalid":n.state==="invalid","aria-describedby":`${t}-email-msg`,value:o,onChange:a=>m(a.target.value),onBlur:v,placeholder:"Email address",className:`${T} ${u==="inline"?"flex-1":""}`}),e.jsx("button",{type:"submit",disabled:l==="loading"||!g,className:D,children:l==="loading"?"Sending":y})]}),e.jsx(B,{id:`${t}-email-msg`,validity:n,tone:r?"dark":"light"}),e.jsx("div",{className:"mt-1",children:F}),b&&e.jsx("p",{"aria-live":"polite",className:`mt-1 text-xs ${l==="ok"?r?"text-background/70":"text-foreground/65":"text-red-600"}`,children:b})]})}function I({source:t="insights_weekly"}={}){return e.jsx("section",{"aria-label":"Build the Damn Thing newsletter — weekly",className:"bg-cream py-16 md:py-24",children:e.jsxs("div",{className:"mx-auto max-w-[760px] px-5 text-center sm:px-6 md:px-10",children:[e.jsxs("div",{className:"flex items-center justify-center gap-3",children:[e.jsx("span",{"aria-hidden":!0,className:"h-px w-10 bg-yellow"}),e.jsx("p",{className:"text-[11px] font-semibold uppercase tracking-[0.3em] text-foreground/55",children:"The Newsletter"}),e.jsx("span",{"aria-hidden":!0,className:"h-px w-10 bg-yellow"})]}),e.jsx("h2",{className:"mt-6 font-serif text-[2.25rem] font-medium leading-[1.05] text-foreground md:text-[3rem]",children:"Build the Damn Thing, weekly."}),e.jsx("p",{className:"mx-auto mt-5 max-w-[560px] text-base leading-relaxed text-foreground/70 md:text-lg",children:"Practical writing on building, ownership, and wealth. Sent every week. Yours if you’re done waiting for permission."}),e.jsxs("ul",{className:"mx-auto mt-8 flex max-w-[420px] items-center justify-between border-y border-foreground
1/15 py-4 text-[11px] font-semibold uppercase tracking-[0.3em] text-foreground/65",children:[e.jsx("li",{children:"Weekly"}),e.jsx("li",{"aria-hidden":!0,className:"h-3 w-px bg-foreground/20"}),e.jsx("li",{children:"Short read"}),e.jsx("li",{"aria-hidden":!0,className:"h-3 w-px bg-foreground/20"}),e.jsx("li",{children:"Free"})]}),e.jsxs("div",{className:"mx-auto mt-8 max-w-[460px] text-left",children:[e.jsx(Y,{source:t,buttonLabel:"Subscribe",layout:"stacked",shape:"square"}),e.jsx("p",{className:"mt-4 text-center text-xs leading-relaxed text-foreground/55",children:"For you if you’re done waiting for permission."})]})]})})}export{I as N};

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.