1import{e as x,r as i,j as e,N as m,L as o}from"./react-vendor-pJj2wC3d.js";import{P as p}from"./PageSeo-Cw5OlS1o.js";import{B as u}from"./Breadcrumbs-BpZ2B7DE.js";import{A as b}from"./index-CCFl4HCQ.js";import{c as h,d as g,a as j}from"./templatesData-BmVdk-vg.js";import{G as f}from"./GuideLink-CYrepVN0.js";import{C as N}from"./check-Cd2WKoU_.js";import{C as y}from"./copy-D0K24jA5.js";import"./createLucideIcon-UjX1GviG.js";function w({text:l,lang:t}){const s=l.split(/(\{[a-z0-9_]+\})/g);return e.jsx("p",{dir:t==="he"?"rtl":"ltr",className:`whitespace-pre-line text-[15px] text-brand leading-relaxed ${t==="he"?"text-right":"text-left"}`,children:s.map((n,r)=>/^\{[a-z0-9_]+\}$/.test(n)?e.jsx("span",{className:"rounded bg-spun-cyan/60 px-1 py-0.5 font-mono text-[13px] text-deep-blue",dir:"ltr",children:n},r):e.jsx("span",{children:n},r))})}function v({t:l}){const[t,s]=i.useState("en"),[n,r]=i.useState(!1),d=l.body[t];i.useEffect(()=>{r(!1)},[t]);const c=async()=>{try{await navigator.clipboard.writeText(d),r(!0)}catch{const a=document.createElement("textarea");a.value=d,document.body.appendChild(a),a.select();try{document.execCommand("copy"),r(!0)}finally{a.remove()}}};return e.jsxs("div",{id:l.slug,className:"rounded-2xl border border-spun-cyan bg-white p-5 sm:p-6",children:[e.jsxs("div",{className:"flex flex-wrap items-start justify-between gap-3 mb-2",children:[e.jsx("h3",{className:"text-lg font-semibold text-brand leading-snug",children:l.name}),e.jsx("div",{className:"flex rounded-full border border-spun-cyan overflow-hidden text-xs font-semibold",role:"group","aria-label":"Template language",children:["en","he"].map(a=>e.jsx("button",{type:"button",onClick:()=>s(a),"aria-pressed":t===a,className:`px-3 py-1 transition-colors ${t===a?"bg-deep-blue text-white":"bg-white text-steel-blue hover:text-brand"}`,children:a==="en"?"English":"×¢×ר×ת"},a))})]}),e.jsxs("p",{className:"text-sm text-steel-blue leading-relaxed mb-4",children:[e.jsx("span",{className:"font-medium text-brand",children:"When to use: "}),l.whenToUse]}),e.jsx("div",{className:"rounded-xl border border-spun-cyan bg-spun-ice/40 p-4 mb-4",children:e.jsx(w,{text:d,lang:t})}),e.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[e.jsxs("p",{className:"text-xs text-steel-blue",children:[e.jsx("span",{className:"font-medium",children:"Variables: "}),l.variables.map(a=>e.jsxs("span",{className:"font-mono text-deep-blue",children:[`{${a}}`," "]},a))]}),e.jsxs("button",{type:"button",onClick:c,className:"inline-flex items-center gap-2 rounded-full bg-deep-blue px-5 py-2 text-sm font-semibold text-white hover:bg-brand transition-colors",children:[n?e.jsx(N,{className:"h-4 w-4"}):e.jsx(y,{className:"h-4 w-4"}),n?"Copied!":"Copy"]})]})]})}function _(){const{slug:l}=x(),t=l?h[l]:void 0;return i.useEffect(()=>{window.scrollTo(0,0)},[l]),t?e.jsxs(e.Fragment,{children:[e.jsx(p,{title:t.metaTitle,description:t.metaDescription,canonicalUrl:g(t.slug)}),e.jsx(u,{items:[{labelKey:"breadcrumb.home",to:"/"},{labelKey:"breadcrumb.templates",to:"/templates"},{labelKey:t.breadcrumbKey}]}),e.jsxs("section",{className:"relative overflow-hidden",children:[e.jsx("div",{className:"absolute inset-0 bg-gradient-to-b from-white to-spun-ice"}),e.jsxs("div",{className:"relative max-w-3xl mx-auto px-6 pt-12 pb-10",children:[e.jsx("p",{className:"text-sm font-semibold uppercase tracking-wider text-gold mb-3",children:"Message Templates"}),e.jsx("h1",{className:"text-3xl sm:text-4xl font-bold tracking-tight text-brand leading-[1.15] mb-4",children:t.title}),t.intro.map(s=>e.jsx("p",{className:"text-base text-steel-blue leading-relaxed mb-3",children:s},s.slice(0,40)))]})]}),e.jsx("section",{className:"py-10 bg-white",children:e.jsx("div",{className:"max-w-3xl mx-auto px-6 space-y-6",children:t.templates.map(s=>e.jsx(v,{t:s},s.slug))})}),e.jsx("section",{className:"py-10 bg-spun-ice",children:e.jsxs("div",{className:"max-w-3xl mx-auto px-6",children:[e.jsx("h2",{className:"text-xl sm:text-2xl font-bold tracking-tight text-brand mb-4",children:"Getting replies, not blocks"}),e.jsx("ul",{className:"list-disc space-y-2 pl-5 marker:text-deep-blue",children:t.tips.map(s=>e.jsx("li",{className:"text-[15px] text-steel-blue leading-relaxed",children:s},s.slice(0,40)))}),t.relatedGuides.length>0&&e.jsxs("p",{className:"text-sm text-steel-blue mt-5",children:[e.jsx("span",{className:"font-medium",children:"Related guides: "}),t.relatedGuides.map((s,n,r)=>
1e.jsxs("span",{children:[e.jsx(f,{to:s.to,className:"text-deep-blue hover:underline",children:s.label}),n<r.length-1?" · ":""]},s.to))]})]})}),e.jsx("section",{className:"py-12 bg-white",children:e.jsx("div",{className:"max-w-3xl mx-auto px-6",children:e.jsxs("div",{className:"rounded-2xl border border-spun-cyan bg-spun-ice p-6 text-center",children:[e.jsx("h2",{className:"text-xl sm:text-2xl font-bold tracking-tight text-brand mb-2",children:"Tired of copy-pasting the same message?"}),e.jsx("p",{className:"text-[15px] text-steel-blue leading-relaxed max-w-2xl mx-auto mb-5",children:"Spun turns the WhatsApp number you already use into a shared team inbox with scheduled messages, auto-replies and broadcasts, so the follow-up sends itself. Flat pricing, free trial."}),e.jsx("a",{href:b,className:"inline-flex items-center gap-2 rounded-full bg-deep-blue px-7 py-3 text-base font-semibold text-white hover:bg-brand shadow-lg shadow-deep-blue/25 transition-all",children:"Start Free Trial"}),e.jsx("p",{className:"mt-3 text-sm",children:e.jsx(o,{to:"/features/",className:"text-deep-blue hover:underline",children:"See everything Spun does"})})]})})}),e.jsx("section",{className:"py-12 bg-spun-ice/50",children:e.jsxs("div",{className:"max-w-3xl mx-auto px-6 text-center",children:[e.jsx("h2",{className:"text-lg font-semibold text-brand mb-4",children:"More WhatsApp templates"}),e.jsx("p",{className:"text-sm text-steel-blue leading-relaxed",children:j.filter(s=>s.slug!==t.slug).map((s,n,r)=>e.jsxs("span",{children:[e.jsx(o,{to:`/templates/${s.slug}`,className:"text-deep-blue hover:underline",children:s.name}),n<r.length-1?" · ":""]},s.slug))})]})})]}):e.jsx(m,{to:"/templates",replace:!0})}export{_ 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.