PageSourceSearch

https://wgoaa.lovable.app/assets/BlogPost-B9gCgXQ-.js

js wgoaa.lovable.app collected 2026-10-03 03:46:29 UTC 17,518 bytes, 2 lines download raw bytes

1import{o as A,j as e,g as f,L as c,s as b,A as B,q as G,H as S}from"./index-DuBrVlzG.js";import{s as q}from"./sanitize-BiMi5Rx5.js";import{C as F,a as O,b as W,c as C}from"./card-cGqlRUPk.js";import{a as L}from"./amara-barnes.jpg.asset-DyXv3N5G.js";import{A as j}from"./arrow-left-CxkZWnrU.js";import"./purify.es-D9RiKzGB.js";const I=({currentPostId:o})=>{const{data:t,isLoading:d}=A({queryKey:["recent-blog-posts"],queryFn:async()=>{const{data:a,error:s}=await b.from("blog_posts").select("id, slug, title, excerpt, author, featured_image, published_at").eq("status","publish").order("published_at",{ascending:!1}).limit(7);if(s)throw s;const m=(a??[]).map(n=>n.id);if(m.length===0)return[];const{data:w}=await b.from("blog_post_categories").select("post_id, category_id, blog_categories(name, slug)").in("post_id",m),g=new Map;return(w??[]).forEach(n=>{const u=g.get(n.post_id)??[];n.blog_categories&&u.push(n.blog_categories),g.set(n.post_id,u)}),(a??[]).map(n=>({...n,categories:g.get(n.id)??[]}))}}),p=a=>a?new Date(a).toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"}):"",i=(t==null?void 0:t.filter(a=>a.id!==o).slice(0,6))??[];return d?e.jsxs("div",{className:"container mx-auto px-4 max-w-6xl mt-16 pt-12 border-t border-primary/20",children:[e.jsx("h2",{className:"text-3xl md:text-4xl text-gray-900 mb-10",children:"Latest Articles"}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8",children:Array.from({length:6}).map((a,s)=>e.jsx(f,{className:"h-80 rounded-xl"},s))})]}):i.length===0?null:e.jsxs("div",{className:"container mx-auto px-4 max-w-6xl mt-16 pt-12 border-t border-primary/20",children:[e.jsx("h2",{className:"text-3xl md:text-4xl text-gray-900 mb-10",children:"Latest Articles"}),e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8",children:i.map(a=>e.jsx(c,{to:`/blog/${a.slug}`,children:e.jsxs(F,{className:"h-full hover:border-primary/50 hover:shadow-xl hover:shadow-primary/5 transition-all bg-white border-gray-200 overflow-hidden group",children:[e.jsx("div",{className:"h-1 bg-rose-gradient"}),a.featured_image?e.jsx("img",{src:a.featured_image,alt:a.title,width:640,height:360,className:"aspect-[16/9] w-full object-cover group-hover:scale-105 transition-transform duration-500",loading:"lazy"}):e.jsx("div",{className:"aspect-[16/9] bg-muted"}),e.jsxs(O,{className:"pb-3",children:[e.jsxs("div",{className:"flex items-center gap-2 flex-wrap mb-2",children:[e.jsx("p",{className:"text-base text-primary font-semibold uppercase tracking-wider font-body",children:p(a.published_at)}),a.author&&e.jsxs("span",{className:"text-base text-gray-700",children:["· ",a.author]})]}),e.jsx(W,{className:"text-xl text-gray-900 leading-snug group-hover:text-primary transition-colors",children:a.title})]}),e.jsxs(C,{children:[e.jsx("p",{className:"text-base text-gray-700 line-clamp-2 mb-3 font-body",children:a.excerpt}),a.categories.length>0&&e.jsx("div",{className:"flex flex-wrap gap-1",children:a.categories.map(s=>e.jsx("span",{className:"text-xs font-semibold uppercase tracking-wider bg-primary/10 text-primary px-2 py-0.5 rounded font-body",children:s.name},s.slug))})]})]})},a.slug))})]})},P=()=>e.jsxs("aside",{className:"border border-primary/30 bg-white rounded-lg p-6 md:p-8 flex flex-col sm:flex-row gap-6 items-start",children:[e.jsx("img",{src:L.url,alt:"Amara Barnes, founder of WGOAA and certified firearms instructor",width:112,height:140,loading:"lazy",className:"w-28 h-36 object-cover rounded-md flex-shrink-0 bg-muted"}),e.jsxs("div",{children:[e.jsx("p",{className:"font-body text-sm uppercase tracking-widest text-primary-text mb-1",children:"About the author"}),e.jsx("h2",{className:"text-2xl md:text-3xl text-gray-900 mb-1",children:e.jsx(c,{to:"/author/amara-barnes",className:"hover:text-primary transition-colors",children:"Amara Barnes"})}),e.jsx("p",{className:"font-body text-sm text-gray-700 mb-3",children:"Certified Firearms Instructor · Founder, WGOAA · 911 Dispatcher"}),e.jsx("p",{className:"font-body text-base text-gray-800 mb-4",children:"Amara founded the Women Gun Owners Association of America in 2021 and has trained more than 17,969 women through the Safe Start Course, the Armed Female Academy, and live events. She works in 911 dispatch, which shapes how she teaches: fit before brand, composure before speed, skill before gear."}),e.jsx(c,{to:"/author/amara-barnes",className:"font-body text-base uppercase tracking-wider text-primary-text hover:underline",children:"More from Amara Barnes →"})]})]}),D="https://order.wgoaa.org/gun-buyer-checklist",k=({variant:o="top"})=>{const t=o==="top";return e.jsxs("aside",{className:"not-prose my-12 rounded-2xl border-2 border-primary/40 bg-white shadow-lg overflow-hidden",children:[e.jsx("div",{className:"h-1.5 bg-rose-gradient"}),e.jsxs("div",{className:"p-6 md:p-8",children:[e.jsx("p",{className:"font-body text-sm font-bold uppercase tracking-widest text-primary-text mb-3",children:"Free · 36 pages · Written for women, by women"}),e.jsx("h2",{className:"text-2xl md:text-3xl text-gray-900 leading-snug mb-3",children:t?"First Time Handgun Buyer's Guide":"Before You Walk Into That Gun Store"}
1),e.jsx("p",{className:"font-body text-lg text-gray-800 mb-4",children:t?e.jsxs(e.Fragment,{children:["For the woman who doesn't want anyone to know she doesn't know. Inside:"," ",e.jsx("strong",{children:"the 5 sentences to say at the counter"}),", the"," ",e.jsx("strong",{children:"6 red flags that mean walk out"}),", the 3 decisions to make at your kitchen table before you spend a dollar, and a 14-point checklist you can print and take with you."]}):e.jsx(e.Fragment,{children:`Why "just get a little revolver, honey" is the worst advice most women are handed — and the one question that settles it. Plus what to do if you can't rack the slide (it's almost never about strength), and the printable 14-point counter checklist.`})}),e.jsxs("ul",{className:"font-body text-base text-gray-800 mb-6 space-y-1.5 list-disc pl-5",children:[e.jsx("li",{children:"What to decide before you leave the house"}),e.jsx("li",{children:"What to say at the counter, word for word"}),e.jsx("li",{children:"What they're allowed to hand you — and when to leave"})]}),e.jsxs("a",{href:D,className:"inline-flex items-center justify-center gap-2 rounded-xl bg-rose-gradient px-7 py-4 font-body text-lg font-bold uppercase tracking-wide text-white shadow-md transition-transform hover:-translate-y-0.5 hover:shadow-xl min-h-[44px]",children:["Get the Free Buyer's Guide ",e.jsx(B,{size:20})]}),e.jsx("p",{className:"font-body text-sm text-gray-600 mt-3",children:"Instant download. No cost, no card, no catch."})]})]})},M=new Set(["beginner-concealed-carry-mistakes-women","best-9mm-handgun-for-women-5-picks-that-are-easy-to-rack","best-concealed-carry-gun-for-women-2026","best-concealed-carry-guns-for-small-women-a-woman-s-guide-to-finding-your-perfect-fit","best-concealed-carry-options-for-women","best-first-gun-for-women","best-guns-for-women-with-weak-grip-or-arthritis","best-handguns-for-women","the-easy-rack-test-5-pistols-women-over-50-can-actually-operate","revolvers-for-women-why-more-instructors-are-starting-here-in-2026","s-w-shield-ez-vs-walther-pdp-f-series-the-honest-verdict-for-women-with-small","the-best-gun-for-womens-self-defense-chosen-calmly-not-in-panic","the-best-home-defense-shotgun-for-women-quiet-power-for-your-castle","the-best-concealed-carry-setup-for-women-who-carry-with-grace","choosing-the-right-everyday-carry-insights-for-responsible-concealed-carry-enthusiasts","embracing-independence-the-journey-of-a-first-time-female-gun-owner","new-to-concealed-carry-where-women-should-start","overcoming-fear-of-guns-women","getting-started-with-dry-firing-an-essential-practice-for-beginners","your-first-steps-to-independence-a-comprehensive-guide-for-female-gun-owners-on-understanding-firearm-basics","your-first-summer-with-firearms-tips-and-tricks-for-a-smooth-transition-into-gun-ownership","your-first-30-days-of-carrying-a-step-by-step-guide-for-women","the-first-30-days-of-carrying-what-every-new-armed-woman-should-expect","what-to-expect-for-your-first-shooting-range-tips-for-a-successful-experience","persisting-beyond-training-the-continuing-journey-of-new-female-gun-owners","why-more-women-are-choosing-concealed-carry","the-permission-you-never-needed-choosing-to-protect-yourself","the-quiet-confidence-guide-to-choosing-your-first-gun-holster","the-new-gun-owners-guide-to-holsters-finding-the-right-fit-for-you","best-defensive-ammo-for-women-what-to-actually-load-in-your-carry-gun","sig-sauer-p365-review-for-women","smith-wesson-mp-shield-review-for-women","glock-43x-review-for-women","walther-pdp-f-review-for-women","ruger-lcp-max-review-for-women"]);function z(o,t=.35){const d=[],p=/<\/(p|h2|h3|ul|ol|blockquote|figure)>/gi;let i;for(;(i=p.exec(o))!==null;)d.push(i.index+i[0].length);if(d.length<4)return[o,""];const a=o.length*t;let s=d[0];for(const m of d)Math.abs(m-a)<Math.abs(s-a)&&(s=m);return[o.slice(0,s),o.slice(s)]}const J=()=>{var u,N,v,_;const{slug:o}=G(),{data:t,isLoading:d}=A({queryKey:["blog-post",o],queryFn:async()=>{const{data:r,error:h}=await b.from("blog_posts").select("*").eq("slug",o).eq("status","publish").maybeSingle();if(h)throw h;if(!r)return null;const{data:l}=await b.from("blog_post_categories").select("blog_categories(name, slug)").eq("post_id",r.id);return{...r,categories:(l??[]).map(x=>
1x.blog_categories).filter(Boolean)}},enabled:!!o}),p=r=>r?new Date(r).toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric"}):"",i=t!=null&&t.content_html?Math.max(1,Math.round(t.content_html.replace(/<[^>]*>/g,"").split(/\s+/).length/200)):0;(u=t==null?void 0:t.seo_schema)==null||u.faq;const a=t!=null&&t.content_html?(()=>{let r=t.content_html.replace(/<h1([^>]*)>/gi,"<h2$1>").replace(/<\/h1>/gi,"</h2>");return r=r.replace(/<p([^>]*)>/,'<p$1 class="speakable-intro">'),r})():"",s=t?`https://www.wgoaa.org/blog/${t.slug}`:void 0,m=t&&((v=(N=t.seo_schema)==null?void 0:N.faq)==null?void 0:v.length)>0?JSON.stringify({"@context":"https://schema.org","@type":"FAQPage",mainEntity:t.seo_schema.faq.map(r=>({"@type":"Question",name:r.question,acceptedAnswer:{"@type":"Answer",text:r.answer}}))}):null,w=t?JSON.stringify({"@context":"https://schema.org","@type":"Article",headline:t.seo_title||t.title,description:t.seo_description,image:t.og_image?[{"@type":"ImageObject",url:t.og_image,width:1200,height:630}]:[],datePublished:t.published_at,dateModified:t.published_at,author:{"@type":"Person",name:t.author||"WGOAA",url:t.author==="Amara Barnes"?"https://www.wgoaa.org/author/amara-barnes":"https://www.wgoaa.org/about-us"},publisher:{"@type":"Organization",name:"Women Gun Owners Association of America",logo:{"@type":"ImageObject",url:"https://www.wgoaa.org/assets/wgoaa-logo.webp"}},mainEntityOfPage:{"@type":"WebPage","@id":s}}):null,g=(_=t==null?void 0:t.seo_schema)==null?void 0:_["@graph"],n=Array.isArray(g)&&g.length>0?JSON.stringify({"@context":"https://schema.org","@graph":g}):null;return d?e.jsxs("div",{children:[e.jsx("div",{className:"bg-brand-black py-16 md:py-24",children:e.jsxs("div",{className:"container mx-auto px-4 max-w-4xl",children:[e.jsx(f,{className:"h-8 w-48 mb-6 bg-muted"}),e.jsx(f,{className:"h-12 w-full bg-muted"})]})}),e.jsx("div",{className:"bg-cream py-12",children:e.jsxs("div",{className:"container mx-auto px-4 max-w-4xl space-y-4",children:[e.jsx(f,{className:"h-6 w-full"}),e.jsx(f,{className:"h-6 w-3/4"})]})})]}):t?e.jsxs("div",{children:[e.jsxs(S,{children:[e.jsx("title",{children:t.seo_title||t.title}),e.jsx("meta",{name:"description",content:t.seo_description}),e.jsx("link",{rel:"canonical",href:s}),e.jsx("meta",{property:"og:type",content:"article"}),e.jsx("meta",{property:"og:site_name",content:"Women Gun Owners Association of America"}),e.jsx("meta",{property:"og:title",content:t.seo_title||t.title}),e.jsx("meta",{property:"og:description",content:t.seo_description}),e.jsx("meta",{property:"og:url",content:s}),e.jsx("meta",{property:"og:image",content:t.og_image}),e.jsx("meta",{property:"og:image:width",content:"1200"}),e.jsx("meta",{property:"og:image:height",content:"630"}),e.jsx("meta",{property:"og:image:alt",content:t.seo_title||t.title}),e.jsx("meta",{property:"article:published_time",content:t.published_at}),e.jsx("meta",{property:"article:author",content:t.author||"WGOAA"}),e.jsx("meta",{name:"author",content:t.author||"WGOAA"}),e.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),e.jsx("meta",{name:"twitter:site",content:"@WGOAA"}),e.jsx("meta",{name:"twitter:title",content:t.seo_title||t.title}),e.jsx("meta",{name:"twitter:description",content:t.seo_description}),e.jsx("meta",{name:"twitter:image",content:t.og_image}),e.jsx("script",{type:"application/ld+json",children:w}),m&&e.jsx("script",{type:"application/ld+json",children:m}),n&&e.jsx("script",{type:"application/ld+json",children:n})]}),t.featured_image?e.jsxs("div",{className:"relative",children:[e.jsx("img",{src:t.featured_image,alt:t.title,width:1200,height:630,loading:"eager",fetchPriority:"high",className:"w5full h-72 md:h-[28rem] object-cover"}),e.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-brand-black via-brand-black/60 to-transparent"}),e.jsx("div",{className:"absolute bottom-0 left-0 right-0 pb-10 pt-16",children:e.jsxs("div",{className:"container mx-auto px-4 max-w-4xl",children:[e.jsxs(c,{to:"/blog",className:"inline-flex items-center gap-1 text-primary text-2xl mb-4 hover:underline font-body",children:[e.jsx(j,{size:16})," Back to Blog"]}),e.jsxs("div",{className:"flex items-center gap-3 mb-4 flex-wrap",children:[e.jsx("p",{className:"text-primary text-2xl font-semibold uppercase tracking-wider font-body",children:p(t.published_at)}
1),t.author&&e.jsxs("span",{className:"text-foreground/60 text-2xl font-body",children:["by"," ",t.author==="Amara Barnes"?e.jsx(c,{to:"/author/amara-barnes",className:"text-primary hover:underline",children:t.author}):t.author]}),i>0&&e.jsxs("span",{className:"text-foreground/60 text-2xl font-body",children:["· ",i," min read"]})]}),t.author==="Amara Barnes"&&e.jsx("p",{className:"text-foreground/70 text-lg font-body mb-4",children:"Certified Firearms Instructor · Founder, WGOAA · 911 Dispatcher"}),e.jsx("h1",{className:"text-4xl md:text-6xl text-foreground leading-tight",children:t.title})]})})]}):e.jsx("section",{className:"bg-brand-black py-16 md:py-24",children:e.jsxs("div",{className:"container mx-auto px-4 max-w-4xl",children:[e.jsxs(c,{to:"/blog",className:"inline-flex items-center gap-1 text-primary text-2xl mb-6 hover:underline font-body",children:[e.jsx(j,{size:16})," Back to Blog"]}),e.jsxs("div",{className:"flex items-center gap-3 mb-4 flex-wrap",children:[e.jsx("p",{className:"text-primary text-2xl font-semibold uppercase tracking-wider font-body",children:p(t.published_at)}),t.author&&e.jsxs("span",{className:"text-foreground/60 text-2xl font-body",children:["by"," ",t.author==="Amara Barnes"?e.jsx(c,{to:"/author/amara-barnes",className:"text-primary hover:underline",children:t.author}):t.author]}),i>0&&e.jsxs("span",{className:"text-foreground/60 text-2xl font-body",children:["· ",i," min read"]})]}),e.jsx("h1",{className:"text-4xl md:text-6xl text-foreground leading-tight",children:t.title})]})}),e.jsx("div",{className:"patriotic-stripe"}),e.jsxs("section",{className:"bg-cream py-16 md:py-24",children:[(()=>{var h;const r=[];return(h=t.categories)!=null&&h.length&&t.categories.forEach(l=>r.push(l.name)),t.focus_keyword&&t.focus_keyword.split(",").forEach(l=>{const x=l.trim();x&&!r.some(y=>y.toLowerCase()===x.toLowerCase())&&r.push(x)}),r.length===0?null:e.jsx("div",{className:"container mx-auto px-4 max-w-4xl mb-8",children:e.jsx("div",{className:"flex flex-wrap gap-2",children:r.map(l=>e.jsx("span",{className:"inline-block px-3 py-1 rounded-full bg-primary/15 text-primary-text font-body text-2xl font-semibold uppercase tracking-wider",children:l},l))})})})(),(()=>{const r=M.has(t.slug),h=q(a),[l,x]=r?z(h):[h,""],y="container mx-auto px-4 max-w-4xl prose prose-xl text-gray-800 prose-headings:text-gray-900 prose-a:text-primary-text prose-wgoaa";return e.jsxs(e.Fragment,{children:[e.jsx("article",{className:y,dangerouslySetInnerHTML:{__html:l}}),r&&x&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"container mx-auto px-4 max-w-4xl",children:e.jsx(k,{variant:"top"})}),e.jsx("article",{className:y,dangerouslySetInnerHTML:{__html:x}})]}),r&&e.jsx("div",{className:"container mx-auto px-4 max-w-4xl",children:e.jsx(k,{variant:"bottom"})})]})})(),t.author==="Amara Barnes"&&e.jsx("div",{className:"container mx-auto px-4 max-w-4xl mt-16",children:e.jsx(P,{})}),e.jsx("div",{className:"container mx-auto px-4 max-w-4xl mt-16 pt-8 border-t border-primary/20",children:e.jsxs(c,{to:"/blog",className:"inline-flex items-center gap-2 text-primary hover:underline font-body text-2xl uppercase tracking-wider",children:[e.jsx(j,{size:16})," Back to all posts"]})}),e.jsx(I,{currentPostId:t.id})]})]}):e.jsx("div",{children:e.jsx("section",{className:"bg-brand-black py-16 md:py-24",children:e.jsxs("div",{className:"container mx-auto px-4 max-w-4xl text-center",children:[e.jsx("h1",{className:"text-3xl text-foreground mb-4",children:"Post Not Found"}),e.jsx(c,{to:"/blog",className:"text-primary hover:underline font-body",children:"← Back to Blog"})]})})})};export{J as default};
2//# sourceMappingURL=BlogPost-B9gCgXQ-.js.map

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.