PageSourceSearch

https://www.headcount.org/_next/static/chunks/3504-a54c5047e9c84ea8.js?dpl=dpl_3MGxDCECT2PjbgfRiwj1dFkMu3P4

js headcount.org collected 2026-09-24 08:48:13 UTC 44,315 bytes, 2 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3504],{3029:(e,t,l)=>{l.d(t,{BallotVocabClient:()=>c});var a=l(95155),s=l(12115),r=l(24033),n=l(86948),i=l(3730),o=l(65142);function c({groups:e,searchPlaceholder:t}){let[l,c]=(0,s.useState)(""),d=l.trim().toLowerCase(),m=t?.trim()||"Search ballot vocab...",u=(0,s.useMemo)(()=>d?e.map(e=>({...e,terms:e.terms.filter(e=>e.searchText.includes(d))})).filter(e=>e.terms.length>0):e,[e,d]);return e.length?(0,a.jsxs)(n.Zp,{className:"w-full",children:[(0,a.jsx)(n.aR,{children:(0,a.jsx)(o.p,{type:"search",value:l,onChange:e=>c(e.target.value),placeholder:m,"aria-label":m})}),(0,a.jsx)(n.Wu,{className:"divide-y divide-black p-0",children:0===u.length?(0,a.jsxs)("p",{className:"p-4 md:p-6",children:["No ballot vocab terms match “",l,"”."]}):u.map(e=>(0,a.jsxs)("section",{children:[(0,a.jsx)("div",{className:"border-b border-black bg-neutral-100 px-4 py-2 md:px-6",children:(0,a.jsx)(n.ZB,{children:e.categoryName})}),(0,a.jsx)("div",{className:"divide-y divide-black",children:e.terms.map(e=>(0,a.jsxs)(i.Collapsible,{className:"group",defaultOpen:!1,children:[(0,a.jsx)(i.CollapsibleTrigger,{asChild:!0,children:(0,a.jsxs)("div",{className:"group-data-[state=open]:border-b group-data-[state=open]:border-black group-data-[state=open]:bg-neutral-100 flex w-full cursor-pointer flex-row items-center justify-between gap-3 bg-white p-4 py-3 font-bold transition-colors hover:bg-neutral-100 md:px-6",children:[(0,a.jsx)(n.ZB,{className:"min-w-0 flex-1 text-left",children:e.name}),(0,a.jsx)(r.A,{"aria-hidden":"true",className:"shrink-0 transition-transform duration-200 -rotate-90 group-data-[state=open]:rotate-0"})]})}),(0,a.jsx)(i.CollapsibleContent,{children:(0,a.jsx)("div",{className:"px-4 pb-4 pt-4 md:px-6",children:(0,a.jsx)("p",{children:e.definition})})})]},e.id))})]},e.categoryId))})]}):null}},3331:(e,t,l)=>{l.d(t,{CampaignCarouselClient:()=>u});var a=l(95155),s=l(12115),r=l(15239),n=l(37808),i=l(45124),o=l(85481),c=l(2953),d=l(64269),m=l(51409);function u({campaigns:e,inactiveLabel:t,showYear:l=!1,icon:u,iconLeft:h,iconRight:p}){let[x,f]=(0,s.useState)(),g=e.length,b=(0,o.T)(x,g);if(!g)return null;let j=t?.trim()||void 0,v=3===g?[...e,...e]:e,w=(0,d.cn)("basis-[85%] sm:basis-[75%]",g<=2?"md:basis-[70%] lg:basis-[65%]":3===g?"basis-3/4 md:basis-1/2 lg:basis-[35%]":"md:basis-1/2 lg:basis-1/3");return(0,a.jsx)(i.i,{ariaLabel:"Featured campaigns",setApi:f,opts:{align:"center",containScroll:!1,loop:g>1},iconLeft:h,iconRight:p,count:g,current:b,onSelect:e=>x?.scrollTo(e),children:(0,a.jsx)(n.Wk,{className:"ml-0",children:v.map((e,t)=>{let s=function(e){let t=e.image;if(!t||"string"==typeof t)return null;let l=t.sizes?.medium||t.sizes?.large,a=l?.url||t.url;return a?{url:a,width:l?.width||t.width||void 0,height:l?.height||t.height||void 0}:null}(e),i=function(e){if(!e.endDate)return!1;let t=new Date(e.endDate);if(Number.isNaN(t.getTime()))return!1;let l=1e4*t.getUTCFullYear()+(t.getUTCMonth()+1)*100+t.getUTCDate(),a=new Date;return l>=1e4*a.getUTCFullYear()+(a.getUTCMonth()+1)*100+a.getUTCDate()}(e),o=i?function(e){if("iframe"===e.linkType)return e.slug?`/campaigns/${e.slug}`:"#";let t=e.link;if(!t?.value)return"#";let l=t.value;return"string"==typeof l?"#":(0,c.f)(l)}(e):null,h=t%g,p=!!j&&!i,x=new Date(e.endDate),f=Number.isNaN(x.getTime())?null:x.getUTCFullYear(),v=(0,a.jsxs)("article",{className:(0,d.cn)("theme-card mt-4 mb-6 overflow-hidden border transition-all mx-auto w-full max-w-[80vw] md:max-w-125",h!==b&&"scale-95 origin-center"),children:[(0,a.jsxs)("div",{className:"relative aspect-square w-full",children:[u&&(0,a.jsx)(m.R,{icon:u,className:(0,d.cn)("absolute w-12 h-12 -top-4 -right-4 z-10 transition-all duration-700 animate-twinkle",h===b?"scale-100":"scale-0")}),s?(0,a.jsx)(r.default,{src:s.url,alt:e.name,fill:!0,sizes:"(max-width: 640px) 85vw, (max-width: 768px) 75vw, (max-width: 1024px) 50vw, 33vw",className:"w-full h-full object-cover"}):(0,a.jsx)("p",{children:"No image"})]}),(0,a.jsxs)("div",{className:"flex flex-1 flex-col items-center justify-center gap-1 px-theme-button-px py-theme-button-py text-center bg-theme-button-primary-background border-t border-theme-surface-border",children:[(0,a.jsx)("h3",{children:e.name}),p?(0,a.jsx)("p",{children:j}):null,l&&!i&&f?(0,a.jsx)("p",{children:f}):null]})]});return(0,a.jsx)(n.CarouselItem,{className:(0,d.cn)(w,"pl-0"),children:o?(0,a.jsx)("a",{href:o,className:"no-underline",children:v}):v},`${e.id}-${t}`)})})})}},10875:(e,t,l)=>{l.d(t,{BlogListClient:()=>i});var a=l(95155),s=l(12115),r=l(15239);function n({post:e,showDescription:t}
1){let l=t?e.description?.trim():null,s=l?"min-h-[10rem]":"h-[10rem]";return(0,a.jsx)("article",{className:"theme-card overflow-hidden border p-0",children:(0,a.jsxs)("a",{href:e.href,className:`grid ${s} transition-opacity hover:opacity-90 ${e.featuredImage?"grid-cols-[minmax(0,10rem)_1fr]":""}`,children:[e.featuredImage&&(0,a.jsx)("div",{className:"relative h-full w-full border-r border-theme-card-border",children:(0,a.jsx)(r.default,{src:e.featuredImage.url,alt:e.featuredImage.alt,fill:!0,sizes:"(max-width: 768px) 100vw, 10rem",className:"object-cover"})}),(0,a.jsxs)("div",{className:"flex flex-col justify-center gap-1 px-4 py-5 md:px-6",children:[(0,a.jsx)("p",{className:"theme-card-title",children:e.title}),e.publishDate&&(0,a.jsx)("p",{className:"theme-card-content",children:e.publishDate}),l&&(0,a.jsx)("p",{className:"theme-card-content",children:l})]})]})})}function i({categoryIds:e,hasNextPage:t,initialPosts:l,limit:r,loadingMessage:i,nextPage:o,showDescription:c}){let d=i?.trim()||"Loading more posts...",[m,u]=(0,s.useState)(l),[h,p]=(0,s.use
1State)(t),[x,f]=(0,s.useState)(o??null),[g,b]=(0,s.useState)(!1),[j,v]=(0,s.useState)(null),w=(0,s.useRef)(null),N=e.join(","),y=(0,s.useCallback)(async()=>{if(h&&x&&!g){b(!0),v(null);try{let e=new URLSearchParams({categoryIds:N,limit:String(r),page:String(x),showDescription:c?"true":"false"}),t=await fetch(`/api/blog-posts?${e.toString()}`),l=await t.json();if(!t.ok)return void v(l.error||"Could not load more blog posts.");u(e=>{let t=new Set(e.map(e=>e.id)),a=(l.posts||[]).filter(e=>!t.has(e.id));return[...e,...a]}),p(!!l.hasNextPage),f(l.nextPage??null)}catch{v("Could not load more blog posts.")}finally{b(!1)}}},[N,h,g,r,x,c]);return((0,s.useEffect)(()=>{let e=w.current;if(!e||!h||g||j)return;let t=new IntersectionObserver(e=>{e.some(e=>e.isIntersecting)&&y()},{rootMargin:"600px 0px"});return t.observe(e),()=>t.disconnect()},[j,h,g,y]),m.length)?(0,a.jsxs)("section",{className:"flex w-full flex-col gap-theme-md md:gap-theme-lg",children:[(0,a.jsx)("div",{className:"flex flex-col gap-theme-md md:gap-theme-lg",children:m.map(e=>(0,a.jsx)(n,{post:e,showDescription:c},e.id))}),h&&(0,a.jsx)("div",{ref:w,className:"flex min-h-10 items-center justify-center",children:j?(0,a.jsxs)("button",{type:"button",className:"theme-card-content underline",onClick:()=>void y(),children:[j," Try again."]}):(0,a.jsx)("p",{className:"theme-card-content","aria-live":"polite",children:g?d:"Scroll to load more posts."})})]}):null}},21517:(e,t,l)=>{l.d(t,{StatesCardClient:()=>x});var a=l(95155),s=l(12115),r=l(86651),n=l(24033),i=l(86948),o=l(3730),c=l(63817),d=l(26333),m=l(65142),u=l(51409),h=l(73101),p=l(64269);function x({title:e,displayMode:t="accordion",searchPlaceholder:l,defaultOpen:s="none",selectorLabel:r,emptyStateText:n,icon:i,entries:o}){return o.length?"single"===t?(0,a.jsx)(j,{title:e,selectorLabel:r,emptyStateText:n,icon:i,entries:o}):(0,a.jsx)(f,{title:e,searchPlaceholder:l,defaultOpen:s,entries:o}):null}function f({title:e,searchPlaceholder:t,defaultOpen:l="none",entries:n}){let[o,c]=(0,s.useState)(""),d=o.trim().toLowerCase(),u=d.length>0,h=(0,s.useMemo)(()=>u?n.filter(e=>e.searchText.includes(d)):n,[n,u,d]);return(0,a.jsxs)("section",{className:"flex w-full flex-col gap-4",children:[e?(0,a.jsx)("h3",{className:"text-lg font-bold",children:e}):null,(0,a.jsxs)("div",{className:"relative w-full",children:[(0,a.jsx)(r.A,{"aria-hidden":"true",className:"pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground"}),(0,a.jsx)(m.p,{type:"search",value:o,onChange:e=>c(e.target.value),placeholder:t??"Search states…","aria-label":t??"Search states",className:"pl-9"})]}),0===h.length?(0,a.jsxs)("p",{className:"text-sm text-muted-foreground",children:["No states match “",o,"”."]}):(0,a.jsx)(i.Zp,{className:"w-full",children:(0,a.jsx)(i.Wu,{className:"divide-y divide-black p-0",children:h.map((e,t)=>{var s,r;return(0,a.jsx)(g,{entry:e,defaultOpen:(s=l,r=t,!!u||"all"===s||"first"===s&&0===r)},`${e.id}-${u?"search":"default"}`)})})})]})}function g({entry:e,defaultOpen:t}){return(0,a.jsxs)(o.Collapsible,{className:"group",defaultOpen:t,children:[(0,a.jsx)(o.CollapsibleTrigger,{asChild:!0,children:(0,a.jsxs)("div",{className:(0,p.cn)("flex w-full cursor-pointer flex-row items-center justify-between gap-3 bg-white p-4 py-3 font-bold transition-colors hover:bg-neutral-100","group-data-[state=open]:border-b group-data-[state=open]:border-black group-data-[state=open]:bg-neutral-100"),children:[(0,a.jsx)("span",{className:"min-w-0 flex-1 text-left",children:e.name}),(0,a.jsx)(n.A,{"aria-hidden":"true",className:"shrink-0 text-muted-foreground transition-transform duration-200 -rotate-90 group-data-[state=open]:rotate-0"})]})}),(0,a.jsx)(o.CollapsibleContent,{children:(0,a.jsx)("div",{className:"bg-white p-theme-md md:p-theme-lg",children:e.rendered})})]})}function b(e){let t=e?.trim().toUpperCase();return t&&/^[A-Z]{2}$/.test(t)?t:null}function j({title:e,selectorLabel:t="Select your state",emptyStateText:l,icon:r,entries:o}){let m=(0,h.A)(),[p,x]=(0,s.useState)(!1),[f,g]=(0,s.useState)(()=>b(m?.currentState)??null);(0,s.useEffect)(()=>{let e=function(e){let t=null;try{t=window.localStorage.getItem("state")}catch{t=null}return b(e)||b(t)||b(function(e){if("undefined"==typeof document)return null;let t=document.cookie.split("; ").find(t=>t.startsWith(`${e}=`))?.split("=")[1];return t?decodeURIComponent(t):null}("user-state"))}(m?.currentState);e&&g(t=>t===e?t:e)},[m?.currentState]);let j=(0,s.useMemo)(()=>o.find(e=>e.abbreviation===f)??null,[o,f]),v=(0,s.useMemo)(()=>o.reduce((e,t)=>
1{let l=t.name.charAt(0).toUpperCase();return e[l]||(e[l]=[]),e[l].push(t),e},{}),[o]);return(0,a.jsx)("section",{className:"flex w-full flex-col gap-4",children:(0,a.jsxs)(i.Zp,{className:"w-full text-left",children:[(0,a.jsxs)(i.aR,{className:"flex flex-row items-center gap-3",children:[r?(0,a.jsx)(u.R,{icon:r,className:"h-10 w-10 shrink-0"}):null,(0,a.jsx)(i.ZB,{className:"min-w-0 flex-1",children:e}),(0,a.jsx)(i.X9,{children:(0,a.jsxs)(d.AM,{open:p,onOpenChange:x,children:[(0,a.jsx)(d.Wv,{asChild:!0,children:(0,a.jsxs)("button",{type:"button",className:"flex shrink-0 flex-row items-center gap-1 rounded-full bg-black px-4 py-2 text-sm text-white",children:[j?.name||t,(0,a.jsx)(n.A,{className:"h-4 w-4"})]})}),(0,a.jsx)(d.hl,{className:"p-0",align:"end",children:(0,a.jsxs)(c.uB,{children:[(0,a.jsx)(c.G7,{placeholder:"Search for your state..."}),(0,a.jsx)(c.oI,{children:Object.entries(v).sort(([e],[t])=>e.localeCompare(t)).map(([e,t])=>(0,a.jsx)(c.L$,{heading:e,children:t.map(e=>(0,a.jsx)(c.h_,{value:e.name,onSelect:()=>{g(e.abbreviation),x(!1),m?.setState(e.abbreviation)},className:"cursor-pointer",children:e.name},e.id))},e))})]})})]})})]}),(0,a.jsx)(i.Wu,{className:"p-theme-md md:p-theme-lg",children:j?j.rendered:(0,a.jsx)("p",{className:"theme-card-accent text-sm",children:l})})]})})}},22053:(e,t,l)=>{l.d(t,{BiosLexicalClient:()=>o});var a=l(95155),s=l(15239),r=l(70019),n=l(86948),i=l(51834);function o({bios:e}){return e.length?(0,a.jsx)("section",{className:"w-full",children:(0,a.jsx)("div",{className:"grid grid-cols-2 gap-4 md:grid-cols-3 lg:grid-cols-5",children:e.map(e=>{let t=function(e){if(!e||"string"==typeof e)return null;let t=e.sizes?.medium||e.sizes?.large,l=t?.url||e.url;return l?{url:l,width:t?.width||e.width||void 0,height:t?.height||e.height||void 0,alt:e.alt||"",objectPosition:function(e){let t="number"==typeof e.focalX?e.focalX:50,l="number"==typeof e.focalY?e.focalY:50;if("number"!=typeof e.focalX&&"number"!=typeof e.focalY)return;let a=Math.min(100,Math.max(0,t)),s=Math.min(100,Math.max(0,l));return`${a}% ${s}%`}(e)}:null}(e.image);return(0,a.jsxs)(i.lG,{children:[(0,a.jsx)(i.zM,{asChild:!0,children:(0,a.jsx)("button",{type:"button",className:"w-full text-left focus:outline-none focus-visible:ring-2 focus-visible:ring-ring",children:(0,a.jsxs)(n.Zp,{className:"theme-bio h-full cursor-pointer",children:[t?(0,a.jsx)("div",{className:"relative aspect-square w-full",children:(0,a.jsx)(s.default,{src:t.url,alt:t.alt||e.name,fill:!0,sizes:"(max-width: 768px) 100vw, (max-width: 1200px) 50vw, 33vw",className:"object-cover",style:{objectPosition:t.objectPosition}})}):null,(0,a.jsxs)(n.aR,{className:"flex-1 flex flex-col",children:[(0,a.jsx)(n.ZB,{children:e.name}),e.title?(0,a.jsx)(n.BT,{className:"mb-auto",children:e.title}):null]})]})})}),(0,a.jsxs)(i.Cf,{className:"flex max-h-[90vh] w-[min(94vw,64rem)] flex-col overflow-hidden p-0 sm:max-w-4xl",children:[(0,a.jsxs)(i.c7,{children:[(0,a.jsx)(i.L3,{children:e.name}),e.title?(0,a.jsx)(i.rr,{children:e.title}):null]}),(0,a.jsxs)("div",{className:"min-h-0 flex-1 overflow-y-auto p-4 md:p-6",children:[t?(0,a.jsx)("div",{className:"relative mb-4 aspect-[16/9] w-full overflow-hidden rounded-md border",children:(0,a.jsx)(s.default,{src:t.url,alt:t.alt||e.name,fill:!0,sizes:"(max-width: 768px) 94vw, 1024px",className:"object-cover",style:{objectPosition:t.objectPosition}})}):null,e.bio?(0,a.jsx)(r.s,{data:e.bio,className:"flex flex-col content-block-text w-full gap-theme-md md:gap-theme-lg"}):null]})]})]},e.id)})})}):null}},30541:(e,t,l)=>{l.d(t,{ProjectCarouselClient:()=>u});var a=l(95155),s=l(15239),r=l(12115),n=l(37808),i=l(45124),o=l(85481),c=l(64269),d=l(2953);function m(e){if(!e.logo||"string"==typeof e.logo)return null;let t=e.logo,l=t.sizes?.medium||t.sizes?.large,a=l?.url||t.url;return a?{id:e.id,name:e.name,href:"string"==typeof e.link?"#":(0,d.f)(e.link),logoUrl:a,logoAlt:t.alt||e.name}:null}function u({projects:e,iconLeft:t,iconRight:l}){let[d,u]=(0,r.useState)(),h=e.map(m).filter(e=>null!==e),p=h.length,x=(0,o.T)(d,p);if(!h.length)return null;let f=3===p?[...h,...h]:h,g=(0,c.cn)("basis-[62%] sm:basis-[42%]",p<=2?"md:basis-[34%] lg:basis-[26%]":3===p?"md:basis-[28%] lg:basis-[22%]":"md:basis-[24%] lg:basis-[18%]");return(0,a.jsx)(i.i,{ariaLabel:"Projects carousel",setApi:u,opts:{align:"center",containScroll:!1,loop:p>1},iconLeft:t,iconRight:l,count:p,current:x,onSelect:e=>d?.scrollTo(e),children:(0,a.jsx)(n.Wk,{className:"ml-0 py-2",children:f.map((e,t)=>
1(0,a.jsx)(n.CarouselItem,{className:(0,c.cn)(g,"px-1.5 sm:px-2"),children:(0,a.jsx)("a",{href:e.href,className:"block no-underline",children:(0,a.jsxs)("article",{className:"theme-card mx-auto my-4 aspect-square w-full max-w-[220px] md:max-w-[240px] lg:max-w-[260px] border p-5",children:[(0,a.jsx)("div",{className:"relative h-full w-full",children:(0,a.jsx)(s.default,{src:e.logoUrl,alt:e.logoAlt,fill:!0,sizes:"(max-width: 640px) 62vw, (max-width: 768px) 42vw, (max-width: 1024px) 28vw, 260px",className:"object-contain"})}),(0,a.jsx)("span",{className:"sr-only",children:e.name})]})})},`${e.id}-${t}`))})})}},36750:(e,t,l)=>{l.d(t,{Q2:()=>a});let a=["AL","AK","AZ","AR","CA","CO","CT","DE","FL","GA","HI","ID","IL","IN","IA","KS","KY","LA","ME","MD","MA","MI","MN","MS","MO","MT","NE","NV","NH","NJ","NM","NY","NC","ND","OH","OK","OR","PA","RI","SC","SD","TN","TX","UT","VT","VA","WA","WV","WI","WY","DC"]},40407:(e,t,l)=>{l.d(t,{BlogCarouselClient:()=>u});var a=l(95155),s=l(12115),r=l(15239),n=l(37808),i=l(45124),o=l(85481),c=l(51409),d=l(64269);let m={"row-1":"bg-theme-row-1","row-2":"bg-theme-row-2","row-3":"bg-theme-row-3","row-4":"bg-theme-row-4","row-5":"bg-theme-row-5","card-bg":"bg-theme-card-background"};function u({posts:e,showFeaturedImage:t=!0,size:l="large",background:u="card-bg",icon:h,iconLeft:p,iconRight:x}){let[f,g]=(0,s.useState)(),b=Array.isArray(e)?e:[],j=b.length,v=(0,o.T)(f,j);if(!b.length)return null;let w="small"===l,N=3===j?[...b,...b]:b,y=w?(0,d.cn)("basis-[62%] sm:basis-[42%]",j<=2?"md:basis-[34%] lg:basis-[26%]":3===j?"md:basis-[28%] lg:basis-[22%]":"md:basis-[24%] lg:basis-[18%]"):(0,d.cn)("basis-[85%] sm:basis-[75%]",j<=2?"md:basis-[70%] lg:basis-[65%]":3===j?"basis-3/4 md:basis-1/2 lg:basis-[35%]":"md:basis-1/2 lg:basis-1/3"),C=w?"max-w-[220px] md:max-w-[240px] lg:max-w-[260px]":"max-w-[80vw] md:max-w-125",k=w?"(max-width: 640px) 62vw, (max-width: 768px) 42vw, (max-width: 1024px) 28vw, 260px":"(max-width: 640px) 85vw, (max-width: 768px) 75vw, (max-width: 1024px) 50vw, 33vw",S=m[u??"card-bg"];return(0,a.jsx)(i.i,{ariaLabel:"Blog carousel",setApi:g,opts:{align:"center",containScroll:!1,loop:j>1},iconLeft:p,iconRight:x,count:j,current:v,onSelect:e=>f?.scrollTo(e),children:(0,a.jsx)(n.Wk,{className:"ml-0",children:N.map((e,l)=>{let s=l%j===v,i=t?e.featuredImage:null;return(0,a.jsx)(n.CarouselItem,{className:(0,d.cn)(y,"pl-0"),children:(0,a.jsx)("a",{href:e.href,className:"no-underline",children:(0,a.jsxs)("article",{className:(0,d.cn)("theme-card relative mx-auto mt-4 mb-6 flex w-full flex-col overflow-hidden border transition-all",C,!s&&"scale-95 origin-center"),children:[h?(0,a.jsx)(c.R,{icon:h,className:(0,d.cn)("absolute -top-4 -right-4 z-10 h-12 w-12 transition-all duration-700 animate-twinkle",s?"scale-100":"scale-0")}):null,i?(0,a.jsx)("div",{className:"relative aspect-[4/3] w-full",children:(0,a.jsx)(r.default,{src:i.url,alt:i.alt,fill:!0,sizes:k,className:"h-full w-full object-cover"})}):null,(0,a.jsxs)("div",{className:(0,d.cn)("flex flex-1 flex-col items-center justify-center px-4 py-5 text-center","text-theme-card-primary",S,i&&"theme-card-div
1ider border-t",i?"min-h-[9rem]":w?"min-h-[14rem]":"min-h-[18rem]"),children:[(0,a.jsx)("h3",{children:e.title}),e.description?(0,a.jsx)("p",{className:(0,d.cn)("theme-card-content mt-2 font-normal",w&&"text-sm"),children:e.description}):null]})]})})},`${e.id}-${l}`)})})})}},41348:(e,t,l)=>{l.d(t,{default:()=>g});var a=l(95155),s=l(12115),r=l(67083),n=l(3998),i=l(86948),o=l(81032),c=l(65142),d=l(64269),m=l(75373),u=l(30926);let h=(0,u.createServerReference)("40ebcd748320dd7f9f39686b066c6ba61a15b14234",u.callServer,void 0,u.findSourceMapURL,"verifyRegistrationAction");var p=l(36750);let x={firstName:"",lastName:"",address:"",address2:"",city:"",state:"",zip:"",lat:null,lng:null,email:"",phone:"",smsOptIn:!1,emailOptIn:!1};function f({row:e}){return(0,a.jsxs)("div",{className:"min-w-0",children:[(0,a.jsx)("p",{children:[e.name_first,e.name_middle,e.name_last,e.name_suffix].filter(Boolean).join(" ").trim()||"Voter name"}),(0,a.jsx)("p",{children:e.addr_address_residential?.trim()||"Address unavailable"}),e.addr_address2_residential?.trim()?(0,a.jsx)("p",{children:e.addr_address2_residential}):null,(0,a.jsx)("p",{children:[e.addr_city_residential,[e.addr_state_residential,e.addr_zip_residential].filter(Boolean).join(" ")].filter(Boolean).join(", ")||"City, ST ZIP"})]})}function g({buttonsIfFound:e=[],buttonsIfNotFound:t=[],everyAction:l}){let u=(0,s.useId)(),[g,b]=(0,s.useState)("form"),[j,v]=(0,s.useState)(x),[w,N]=(0,s.useState)([]),[y,C]=(0,s.useState)(null),[k,S]=(0,s.useState)(!1),[I,$]=(0,s.useState)(null),A=(0,s.useMemo)(()=>Array.isArray(e)?e.filter(e=>!!e):[],[e]),O=(0,s.useMemo)(()=>Array.isArray(t)?t.filter(e=>!!e):[],[t]),M=(e,t)=>{v(l=>({...l,[e]:t}))},T=()=>{b("form"),v(x),N([]),C(null),$(null)},z=async e=>{if(e.preventDefault(),!k){if($(null),!j.city.trim())return void $("Please enter your city.");if(!j.state)return void $("Please select your state.");if(!/^\d{5}(-?\d{4})?$/.test(j.zip.trim()))return void $("Please enter a valid ZIP code.");if(l.enabled&&l.showSmsOptIn&&j.smsOptIn&&j.phone.replace(/\D/g,"").length<10)return void $("Please enter a valid phone number for SMS opt-in.");if(l.enabled&&l.showEmailOptIn&&j.emailOptIn){let e=j.email.trim().toLowerCase();if(!e||!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e))return void $("Please enter a valid email address for email opt-in.")}S(!0);try{let e=l.enabled&&(l.showSmsOptIn||l.showEmailOptIn)&&(j.smsOptIn||j.emailOptIn)?{smsOptIn:!!l.showSmsOptIn&&j.smsOptIn,emailOptIn:!!l.showEmailOptIn&&j.emailOptIn,phone:l.showSmsOptIn&&j.smsOptIn?j.phone:void 0,email:l.showEmailOptIn&&j.emailOptIn?j.email:void 0}:void 0,t=await h({firstName:j.firstName,lastName:j.lastName,address:j.address,address2:j.address2||void 0,city:j.city,state:j.state,zip:j.zip,everyAction:e});if(!t.ok)return void $(t.message);if(N(t.matches),0===t.matches.length)return void b("not-found");if(1===t.matches.length){C(t.matches[0]),b("registered");return}b("select")}catch(e){console.error("VerifyRegistration submit failed",e),$("Something went wrong. Please try again.")}finally{S(!1)}}},_=y?.civitech_voter_status?.trim()||y?.sos_voter_status?.trim()||"Registered";return(0,a.jsxs)(a.Fragment,{children:["form"===g?(0,a.jsxs)("form",{className:"flex flex-col gap-theme-md w-full",onSubmit:z,noValidate:!0,children:[(0,a.jsx)(i.Zp,{children:(0,a.jsxs)(i.Wu,{className:"flex flex-col gap-theme-md p-6 md:p-8",children:[(0,a.jsxs)("div",{className:"grid gap-theme-md sm:grid-cols-2",children:[(0,a.jsxs)(o.MG,{children:[(0,a.jsx)("label",{htmlFor:`${u}-first`,className:"theme-label",children:"First name"}),(0,a.jsx)(c.p,{id:`${u}-first`,required:!0,autoComplete:"given-name",placeholder:"Jane",value:j.firstName,onChange:e=>M("firstName",e.target.value)})]}),(0,a.jsxs)(o.MG,{children:[(0,a.jsx)("label",{htmlFor:`${u}-last`,className:"theme-label",children:"Last name"}),(0,a.jsx)(c.p,{id:`${u}-last`,required:!0,autoComplete:"family-name",placeholder:"Doe",value:j.lastName,onChange:e=>M("lastName",e.target.value)})]})]}),(0,a.jsxs)(o.MG,{children:[(0,a.jsx)("label",{htmlFor:`${u}-address`,className:"theme-label",children:"Address"}),(0,a.jsx)(r.Z,{id:`${u}-address`,required:!0,value:j.address,onValueChange:e=>{M("address",e)},onPlaceSelected:e=>{M("address",e.address),M("city",e.city),M("state",e.state),M("zip",e.zip),M("lat",e.lat),M("lng",e.lng)}})]}),(0,a.jsxs)(o.MG,{children:[(0,a.jsxs)("label",{htmlFor:`${u}-address2`,className:"theme-label",children:["Apartment, suite, etc.",(0,a.jsx)("span",{className:"ml-1 text-muted-foreground",children:"(optional)"})]}),(0,a.jsx)(c.p,{id:`${u}-address2`,autoComplete:"address-line2",placeholder:"Apt 4B",value:j.address2,onChange:e=>M("address2",e.target.value)})]}),(0,a.jsxs)(o.MG,{children:[(0,a.jsx)("label",{htmlFor:`${u}-city`,className:"theme-label",children:"City"}),(0,a.jsx)(c.p,{id:`${u}-city`,required:!0,autoComplete:"address-level2",placeholder:"City",value:j.city,onChange:e=>M("city",e.target.value)})]}),(0,a.jsxs)("div",{className:"grid gap-theme-md sm:grid-cols-2",children:[(0,a.jsxs)(o.MG,{children:[(0,a.jsx)("label",{htmlFor:`${u}-state`,className:"theme-label",children:"State"}),(0,a.jsxs)("select",{id:`${u}-state`,required:!0,autoComplete:"address-level1",value:j.state,onChange:e=>M("state",e.target.value),className:(0,d.cn)("theme-input w-full min-w-0 appearance-none bg-[image:var(--theme-select-chevron,none)] bg-[length:1rem_1rem] bg-[position:right_0.75rem_center] bg-no-repeat pr-9 transition-[color,box-shadow] outline-none","focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50","aria-invalid:border-destructive aria-invalid:ring-destructive/20"),children:[(0,a.jsx)("option",{value:"",disabled:!0,children:"Select a state"}),p.Q2.map(e=>(0,a.jsx)("option",{value:e,children:e},e))]})]}),(0,a.jsxs)(o.MG,{children:[(0,a.jsx)("label",{htmlFor:`${u}-zip`,className:"theme-label",children:"ZIP code"}),(0,a.jsx)(c.p,{id:`${u}-zip`,required:!0,autoComplete:"postal-code",inputMode:"numeric",placeholder:"12345",maxLength:10,value:j.zip,onChange:e=>M("zip",e.target.value)})]})]}),l.enabled&&l.showSmsOptIn?(0,a.jsxs)(o.MG,{children:[(0,a.jsxs)("label",{htmlFor:`${u}-phone`,className:"theme-label",children:["Phone",j.smsOptIn?null:(0,a.jsx)("span",{className:"ml-1 text-muted-foreground",children:"(optional)"})]}),(0,a.jsx)(c.p,{id:`${u}-phone`,type:"tel",autoComplete:"tel",placeholder:"(555) 555-5555",value:j.phone,onChange:e=>M("phone",e.target.value),required:j.smsOptIn})]}):null,l.enabled&&l.showEmailOptIn?(0,a.jsxs)(o.MG,{children:[(0,a.jsxs)("label",{htmlFor:`${u}-email`,className:"theme-label",children:["Email",j.emailOptIn?null:(0,a.jsx)("span",{className:"ml-1 text-muted-foreground",children:"(optional)"})]}),(0,a.jsx)(c.p,{id:`${u}-email`,type:"email",autoComplete:"email",placeholder:"[email protected]",value:j.email,onChange:e=>M("email",e.target.value),required:j.emailOptIn})]}):null,l.enabled&&(l.showSmsOptIn||l.showEmailOptIn)?(0,a.jsxs)("div",{className:"space-y-3 border-t pt-4",children:[l.showSmsOptIn?(0,a.jsxs)("label",{className:"flex items-start gap-3 text-sm leading-relaxed cursor-pointer",children:[(0,a.jsx)("input",{type:"checkbox",checked:j.smsOptIn,onChange:e=>M("smsOptIn",e.target.checked),className:"mt-0.5 size-4 shrink-0",style:{accentColor:"var(--button-primary-background)"}}),(0,a.jsx)("span",{children:l.smsOptInLabel})]}):null,l.showEmailOptIn?(0,a.jsxs)("label",{className:"flex items-start gap-3 text-sm leading-relaxed cursor-pointer",children:[(0,a.jsx)("input",{type:"checkbox",checked:j.emailOptIn,onChange:e=>M("emailOptIn",e.target.checked),className:"mt-0.5 size-4 shrink-0",style:{accentColor:"var(--button-primary-background)"}}),(0,a.jsx)("span",{children:l.emailOptInLabel})]}):null]}):null,I?(0,a.jsx)("p",{role:"alert",style:{color:"var(--color-theme-button-destructive-background)"},children:I}):null]})}),(0,a.jsx)(n.$,{type:"submit",className:"w-full",disabled:k,children:k?"Checking…":"Check registration"})]}):(0,a.jsx)(i.Zp,{className:"w-full",children:(0,a.jsxs)(i.Wu,{className:"p-6 md:p-8",children:["select"===g?(0,a.jsxs)("div",{className:"space-y-5",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("h3",{children:"Select your voter record"}),(0,a.jsxs)("p",{children:["We found ",w.length," possible matches. Select the one that looks like you."]})]}),(0,a.jsx)("div",{className:"flex flex-col gap-3",children:w.map((e,t)=>(0,a.jsxs)("button",{type:"button",className:"flex w-full items-start justify-between gap-3 rounded-md border p-4 text-left transition hover:bg-muted/40",onClick:()=>{C(e),b("registered")},children:[(0,a.jsx)(f,{row:e}
1),(0,a.jsx)("span",{"aria-hidden":!0,className:"text-muted-foreground",children:"→"})]},`${e.id_sos_civitech}-${e.state}-${t}`))}),(0,a.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,a.jsx)(n.$,{type:"button",variant:"outline",className:"w-full",onClick:()=>b("not-found"),children:"None of these are me"}),(0,a.jsx)("button",{type:"button",className:"text-sm text-muted-foreground underline underline-offset-2 hover:text-foreground",onClick:()=>b("form"),children:"Back"})]})]}):null,"registered"===g&&y?(0,a.jsxs)("div",{className:"space-y-5",children:[(0,a.jsxs)("div",{className:"space-y-1",children:[(0,a.jsx)("h3",{children:"You're currently registered to vote"}),(0,a.jsx)("p",{children:"Here's the voter record we matched with your information."})]}),(0,a.jsxs)("div",{className:"flex items-start justify-between gap-3 rounded-md border p-4",children:[(0,a.jsx)(f,{row:y}),(0,a.jsx)("span",{className:"shrink-0 rounded-full border bg-primary px-3 py-1 text-xs font-medium text-primary-foreground",children:_})]}),(0,a.jsx)("button",{type:"button",className:"text-sm text-muted-foreground underline underline-offset-2 hover:text-foreground",onClick:T,children:"Search again"})]}):null,"not-found"===g?(0,a.jsxs)("div",{className:"space-y-5",children:[(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsx)("h3",{children:"No results found"}),(0,a.jsx)("p",{children:"We couldn't find you based on the information you provided. Here are a few possible reasons why:"}),(0,a.jsxs)("ul",{className:"list-disc space-y-1 pl-6 text-sm text-muted-foreground",children:[(0,a.jsx)("li",{children:"You aren't registered to vote"}),(0,a.jsx)("li",{children:"Different first or last name spelling"}),(0,a.jsx)("li",{children:"Old or incorrect address"}),(0,a.jsx)("li",{children:"You recently registered to vote"})]})]}),(0,a.jsx)(n.$,{type:"button",variant:"outline",className:"w-full",onClick:T,children:"Search again"})]}):null]})}),"registered"===g&&y?A.map((e,t)=>(0,a.jsx)(m.A,{button:e,className:"w-full"},e.id??`found-${t}`)):null,"not-found"===g?O.map((e,t)=>(0,a.jsx)(m.A,{button:e,className:"w-full"},e.id??`not-found-${t}`)):null]})}},47813:(e,t,l)=>{l.d(t,{CardBlockClient:()=>p});var a=l(95155),s=l(12115),r=l(24033),n=l(64269),i=l(51409),o=l(86948),c=l(3730),d=l(65142);let m={"row-1":{backgroundColor:"var(--row-1-bg)"},"row-2":{backgroundColor:"var(--row-2-bg)"},"row-3":{backgroundColor:"var(--row-3-bg)"},"row-4":{backgroundColor:"var(--row-4-bg)"},"row-5":{backgroundColor:"var(--row-5-bg)"}};function u(e){return(e||"").trim().toLowerCase()}
1function h(e){return 0===e?"border-t-0":"theme-card-divider border-t"}function p({fields:e}){let[t,l]=(0,s.useState)(""),p=e.cardStyle||"default",x=Array.isArray(e.cardItems)?e.cardItems:[],f=!!e.collapsible,g=!!(u(e.title)||u(e.description)),b="default"!==p?m[p]:void 0,j=u(t),v=x.find(e=>"search"===e.type)?.placeholder||"Search card items...",w=j?x.filter(e=>"search"===e.type||u(e.title).includes(j)):x,N=g?(0,a.jsxs)(o.aR,{className:(0,n.cn)("flex flex-row items-center gap-3",f&&"cursor-pointer"),children:[e.icon&&(0,a.jsx)(i.R,{icon:e.icon,className:"h-10 w-10 shrink-0"}),(0,a.jsxs)("div",{className:"min-w-0 flex-1",children:[e.title&&(0,a.jsx)(o.ZB,{children:e.title}),e.description&&(0,a.jsx)(o.BT,{children:e.description})]}),f&&(0,a.jsx)(r.A,{className:"ml-auto h-5 w-5 shrink-0 text-muted-foreground transition-transform duration-200 group-data-[state=closed]:-rotate-90"})]}):null,y=(0,a.jsx)(o.Wu,{className:"p-0",children:w.map((e,s)=>{let o=e.id||`${e.type||"item"}-${s}`;if("search"===e.type)return(0,a.jsx)("div",{className:(0,n.cn)("px-4 py-3",h(s)),children:(0,a.jsx)(d.p,{type:"search",value:t,onChange:e=>l(e.target.value),placeholder:v,"aria-label":v})},o);if("divider"===e.type)return(0,a.jsx)("div",{className:(0,n.cn)("px-4 py-2 text-sm font-semibold uppercase tracking-wide",h(s)),children:e.divider||""},o);if("link"===e.type)return(0,a.jsxs)("a",{href:e.href||"#",className:(0,n.cn)("theme-card-div
1ider theme-card-content flex flex-row items-center gap-4 px-5 py-3.5 no-underline transition-opacity hover:opacity-90",h(s)),children:[e.icon&&(0,a.jsx)(i.R,{icon:e.icon,className:"link-icon h-8 w-8 shrink-0"}),(0,a.jsxs)("div",{children:[(0,a.jsx)("div",{className:"text-[length:var(--button-font-size-mobile)] font-[var(--button-font-weight)] [text-transform:var(--button-text-transform,none)] md:text-[length:var(--button-font-size-desktop)]",children:e.title}),e.description&&(0,a.jsx)("div",{className:"theme-card-accent",children:e.description})]})]},o);if("collapsible"===e.type)return(0,a.jsxs)(c.Collapsible,{defaultOpen:!1,className:h(s),children:[(0,a.jsx)(c.CollapsibleTrigger,{asChild:!0,children:(0,a.jsxs)("div",{className:"group flex w-full cursor-pointer items-center gap-3 p-4 md:p-6 transition-colors hover:bg-muted/50",children:[e.icon&&(0,a.jsx)(i.R,{icon:e.icon,className:"h-8 w-8 shrink-0"}),e.title?(0,a.jsx)("div",{className:"theme-card-title min-w-0 flex-1 font-semibold",children:e.title}):(0,a.jsx)("div",{className:"min-w-0 flex-1"}),(0,a.jsx)(r.A,{className:"h-4 w-4 shrink-0 text-muted-foreground transition-transform duration-200 group-data-[state=closed]:-rotate-90"})]})}),(0,a.jsx)(c.CollapsibleContent,{children:e.content?(0,a.jsx)("div",{className:"px-4 pb-4 pt-0 md:px-6 md:pb-6",children:e.content}):null})]},o);let m=!!(e.icon||e.title);return(0,a.jsxs)("div",{className:(0,n.cn)("space-y-2 p-4 md:p-6",h(s)),children:[m?(0,a.jsxs)("div",{className:"flex items-center gap-3",children:[e.icon&&(0,a.jsx)(i.R,{icon:e.icon,className:"h-8 w-8 shrink-0"}),e.title?(0,a.jsx)("div",{className:"theme-card-title min-w-0 flex-1 font-semibold",children:e.title}):null]}):null,e.content??null]},o)})});return(0,a.jsx)("div",{className:"w-full",children:f&&g?(0,a.jsx)(c.Collapsible,{defaultOpen:!0,className:"w-full",children:(0,a.jsxs)(o.Zp,{className:"text-left",style:b,children:[(0,a.jsx)(c.CollapsibleTrigger,{asChild:!0,children:(0,a.jsx)("div",{className:"group",children:N})}),(0,a.jsx)(c.CollapsibleContent,{children:y})]})}):(0,a.jsxs)(o.Zp,{className:"text-left",style:b,children:[N,y]})})}},51675:(e,t,l)=>{l.d(t,{PartnerCarouselClient:()=>p});var a=l(95155),s=l(15239),r=l(12115),n=l(37808),i=l(45124),o=l(85481),c=l(80141),d=l(64269),m=l(2953);let u={"row-1":"bg-theme-row-1","row-2":"bg-theme-row-2","row-3":"bg-theme-row-3","row-4":"bg-theme-row-4","row-5":"bg-theme-row-5","card-bg":"bg-theme-card-background",transparent:""};function h(e){let t=e.logo&&"string"!=typeof e.logo?e.logo:null,l=t?.sizes?.medium||t?.sizes?.large,a=l?.url||t?.url||null;return{id:e.id,name:e.name,href:e.link&&"string"!=typeof e.link&&(0,m.f)(e.link)||null,logoUrl:a,logoAlt:t?.alt||e.name,objectPosition:t?function(e){let t="number"==typeof e.focalX?e.focalX:50,l="number"==typeof e.focalY?e.focalY:50;if("number"!=typeof e.focalX&&"number"!=typeof e.focalY)return;let a=Math.min(100,Math.max(0,t)),s=Math.min(100,Math.max(0,l));return`${a}% ${s}%`}(t):void 0}}function p({partners:e,hidePartnersWithNoImage:t=!1,size:l="small",treatmentType:m="logo",logoFit:p="contain",logoPadding:x="padding",carouselType:f="default",speed:g,stopOnHover:b=!0,background:j="card-bg",maxHeight:v,iconLeft:w,iconRight:N}){let[y,C]=(0,r.useState)(),k=e.map(h).filter(e=>!t||e.logoUrl),S=k.length,I=(0,o.T)(y,S),{containerRef:$,cycleCopies:A,cycleRef:O}=(0,c.j)({enabled:"marquee"===f,itemCount:S});if(!k.length)return null;let M=3===S?[...k,...k]:k,T="small"==("large"===l?"large":"small"),z=T?(0,d.cn)("basis-[62%] sm:basis-[42%]",S<=2?"md:basis-[34%] lg:basis-[26%]":3===S?"md:basis-[28%] lg:basis-[22%]":"md:basis-[24%] lg:basis-[18%]"):(0,d.cn)("basis-[85%] sm:basis-[75%]",S<=2?"md:basis-[70%] lg:basis-[65%]":3===S?"basis-3/4 md:basis-1/2 lg:basis-[35%]":"md:basis-1/2 lg:basis-1/3"),_=T?"(max-width: 640px) 62vw, (max-width: 768px) 42vw, (max-width: 1024px) 28vw, 260px":"(max-width: 640px) 85vw, (max-width: 768px) 75vw, (max-width: 1024px) 50vw, 600px",L="cover"===p?"object-cover":"object-contain",R="image"===m,P="none"!==x,F="transparent"===j,q=u[j??"card-bg"],Z=function(e){if("number"==typeof e&&Number.isFinite(e)&&!(e<=0))return Math.floor(e)}(v),B=Array.from({length:A}).flatMap(()=>k),E=T?"w-[220px] md:w-[240px] lg:w-[260px]":"w-[85vw] sm:w-[75vw] md:w-[50vw] lg:w-[600px]",D=`${B.length*("number"==typeof g&&Number.isFinite(g)&&g>0?g:T?7:9)}s`,W=T?"pl-4 md:pl-5 lg:pl-6":"pl-4 md:pl-6",U=T?260:600,Y=Z?{maxHeight:`${Z}px`,maxWidth:`min(${U}px, ${Z}px)`}:void 0;function G(e,t,l=!1,r=!1){let n=(0,a.jsx)("article",{style:Y,className:(0,d.cn)("mx-auto mb-6 aspect-square w-full overflow-hidden transition-all",!F&&"theme-card border",!r&&"mt-4",T?"max-w-[220px] md:max-w-[240px] lg:max-w-[260px]":"max-w-[80vw] md:max-w-125",!t&&"origin-center scale-95",!R&&P&&"p-5",!F&&q,!e.logoUrl&&"flex items-center justify-center text-center"),children:e.logoUrl?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"relative h-full w-full",children:(0,a.jsx)(s.default,{src:e.logoUrl,alt:e.logoAlt||e.name,fill:!0,sizes:_,className:(0,d.cn)("h-full w-full",R?"object-cover":(0,d.cn)("brightness-0",L)),style:{objectPosition:R?e.objectPosition:void 0}})}),(0,a.jsx)("span",{className:"sr-only",children:e.name})]}):(0,a.jsx)("p",{children:e.name})});return e.href&&!l?(0,a.jsx)("a",{href:e.href,className:"no-underline",target:"_blank",rel:"noopener noreferrer",children:n}):n}return"marquee"===f?(0,a.jsx)("section",{"aria-label":"Partners carousel",className:"w-screen overflow-hidden",children:(0,a.jsx)("div",{ref:$,className:"group flex overflow-hidden",children:(0,a.jsx)("div",{className:(0,d.cn)("flex w-max animate-image-carousel-marquee motion-reduce:animate-none",!1!==b&&"group-hover:[animation-play-state:paused]"),style:{"--image-carousel-marquee-duration":D},children:[0,1].map(e=>(0,a.jsx)("div",{ref:0===e?O:void 0,className:"flex shrink-0","aria-hidden":e>0,children:B.map((t,l)=>(0,a.jsx)("div",{className:(0,d.cn)("shrink-0 px-3",E),children:G(t,!0,e>0,!0)},`${t.id}-${e}-${l}`))},e))})})}):(0,a.jsx)(i.i,{ariaLabel:"Partners carousel",setApi:C,opts:{align:"center",containScroll:!1,loop:S>1},iconLeft:w,iconRight:N,count:S,current:I,onSelect:e=>y?.scrollTo(e),children:(0,a.jsx)(n.Wk,{className:T?"-ml-4 md:-ml-5 lg:-ml-6 py-2":"-ml-4 md:-ml-6 py-2",children:M.map((e,t)=>{let l=t%S;return(0,a.jsx)(n.CarouselItem,{className:(0,d.cn)(z,W),children:G(e,l===I)},`${e.id}-${t}`)})})})}},62302:(e,t,l)=>{l.r(t),l.d(t,{SectionCard:()=>o});var a=l(95155);l(12115);var s=l(24033),r=l(86948),n=l(3730),i=l(64269);function o(e){let{defaultOpen:t=!0,className:l,contentClassName:o,bareContent:c=!1,headerDivider:d=!0,children:m}=e,u="trigger"in e?e.trigger:null,h="title"in e?e.title:null,p="description"in e?e.description:null,x="icon"in e?e.icon:null;return(0,a.jsx)(n.Collapsible,{defaultOpen:t,className:"w-full",children:(0,a.jsxs)(r.Zp,{className:(0,i.cn)("w-full text-left",l),children:[(0,a.jsx)(n.CollapsibleTrigger,{asChild:!0,children:(0,a.jsxs)("div",{className:(0,i.cn)("group flex w-full cursor-pointer flex-row items-center gap-3 p-4 transition-colors hover:bg-muted/50 md:p-6",d&&"theme-card-div
1ider data-[state=open]:border-b"),children:[u||(0,a.jsxs)(a.Fragment,{children:[x?(0,a.jsx)("span",{className:"shrink-0",children:x}):null,(0,a.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,a.jsx)(r.ZB,{children:h}),p?(0,a.jsx)(r.BT,{className:"mt-1",children:p}):null]})]}),(0,a.jsx)(s.A,{"aria-hidden":"true",className:"ml-auto h-5 w-5 shrink-0 text-muted-foreground transition-transform duration-200 group-data-[state=closed]:-rotate-90"})]})}),(0,a.jsx)(n.CollapsibleContent,{children:c?m:(0,a.jsx)(r.Wu,{className:(0,i.cn)("space-y-6 p-4 md:p-6",o),children:m})})]})})}},67083:(e,t,l)=>{l.d(t,{Z:()=>i});var a=l(95155),s=l(65142),r=l(64269),n=l(12115);function i({value:e,onValueChange:t,onPlaceSelected:l,id:i,placeholder:o="Address",className:c,required:d,disabled:m}){let[u,h]=(0,n.useState)([]),[p,x]=(0,n.useState)(!1),[f,g]=(0,n.useState)(!1),[b,j]=(0,n.useState)(null),[v,w]=(0,n.useState)(null),N=(0,n.useRef)(!1),y=(0,n.useRef)(null);(0,n.useEffect)(()=>{let e=y.current;if(!e)return;let t=t=>{e.contains(t.target)||x(!1)};return document.addEventListener("pointerdown",t),()=>{document.removeEventListener("pointerdown",t)}},[]),(0,n.useEffect)(()=>{let t=e.trim();if(m||!t||t.length<3){h([]),j(null),g(!1);return}if(!N.current||v)return;let l=new AbortController,a=window.setTimeout(async()=>{try{g(!0),j(null);let e=await fetch(`/api/google-places?input=${encodeURIComponent(t)}`,{signal:l.signal});if(!e.ok)throw Error("Failed to load address suggestions.");let a=await e.json(),s=Array.isArray(a.predictions)?a.predictions:[];h(s),x(!0)}catch(e){if(l.signal.aborted)return;h([]),j(e instanceof Error?e.message:"Failed to load address suggestions.")}finally{l.signal.aborted||g(!1)}},250);return()=>{l.abort(),clearTimeout(a)}},[m,v,e]);let C=async e=>{w(e.placeId),g(!0),j(null);try{let a=await fetch(`/api/google-places?placeId=${encodeURIComponent(e.placeId)}`);if(!a.ok)throw Error("Failed to load selected address details.");let s=await a.json(),r=s.address||e.description;t(r),l({address:r,city:s.city||"",state:s.state||"",zip:s.zip||"",lat:"number"==typeof s.lat?s.lat:null,lng:"number"==typeof s.lng?s.lng:null}),h([]),x(!1)}catch(e){j(e instanceof Error?e.message:"Failed to load selected address details.")}finally{g(!1)}};return(0,a.jsxs)("div",{className:(0,r.cn)("relative",c),ref:y,children:[(0,a.jsx)(s.p,{id:i,required:d,disabled:m,autoComplete:"street-address",placeholder:o,value:e,onFocus:()=>{u.length>0&&x(!0)},onChange:e=>{var l;return l=e.target.value,void(N.current=!0,t(l),w(null),j(null),l.trim().length<3&&(h([]),x(!1)))}}),p&&u.length>0||f?(0,a.jsx)("div",{className:"theme-card absolute z-20 mt-2 max-h-60 w-full overflow-auto rounded-md border shadow-lg",children:f?(0,a.jsx)("div",{className:"p-3 text-sm",children:"Searching addresses..."}):u.map(e=>(0,a.jsx)("button",{type:"button",className:"block w-full border-b px-3 py-2 text-left text-sm last:border-b-0 hover:bg-black/5",onClick:()=>C(e),children:e.description},e.placeId))}):null,b?(0,a.jsx)("p",{className:"mt-2 text-sm text-red-600",children:b}):null]})}},67179:(e,t,l)=>{l.d(t,{VolunteerFaqsLexicalClient:()=>m});var a=l(95155),s=l(12115),r=l(86651),n=l(24033),i=l(62302),o=l(86948),c=l(3730),d=l(65142);function m({groups:e}){let[t,l]=(0,s.useState)(""),n=t.trim().toLowerCase(),i=n.length>0,o=(0,s.useMemo)(()=>i?e.map(e=>({...e,faqs:e.faqs.filter(e=>e.searchText.includes(n))})).filter(e=>e.faqs.length>0):e,[e,i,n]);return e.length?(0,a.jsxs)("section",{className:"flex w-full flex-col gap-theme-md md:gap-theme-lg",children:[(0,a.jsxs)("div",{className:"relative w-full",children:[(0,a.jsx)(r.A,{"aria-hidden":"true",className:"pointer-events-none absolute left-3 top-1/2 h-4 w-4 -translate-y-1/2 text-muted-foreground"}),(0,a.jsx)(d.p,{type:"search",value:t,onChange:e=>l(e.target.value),placeholder:"Search FAQs...","aria-label":"Search volunteer FAQs",className:"pl-9"})]}),0===o.length?(0,a.jsxs)("p",{className:"text-sm text-muted-foreground",children:["No FAQs match “",t,"”."]}):o.map(e=>(0,a.jsx)(u,{group:e,hasQuery:i},e.categoryId))]}):null}function u({group:e,hasQuery:t}){return(0,a.jsx)(i.SectionCard,{defaultOpen:!0,title:e.categoryName,bareContent:!0,children:(0,a.jsx)(o.Wu,{className:"divide-y divide-black p-0",children:e.faqs.map(e=>(0,a.jsx)(h,{faq:e,defaultOpen:t}
1,`${e.id}-${t?"search":"default"}`))})},`${e.categoryId}-${t?"search":"default"}`)}function h({faq:e,defaultOpen:t}){return(0,a.jsxs)(c.Collapsible,{className:"group",defaultOpen:t,children:[(0,a.jsx)(c.CollapsibleTrigger,{asChild:!0,children:(0,a.jsxs)("div",{className:"flex w-full cursor-pointer flex-row items-center justify-between gap-theme-md bg-white p-4 py-3 font-bold transition-colors hover:bg-neutral-100 group-data-[state=open]:border-b group-data-[state=open]:border-black group-data-[state=open]:bg-neutral-100",children:[(0,a.jsx)("span",{className:"min-w-0 flex-1 text-left",children:e.question}),(0,a.jsx)(n.A,{"aria-hidden":"true",className:"shrink-0 text-muted-foreground transition-transform duration-200 -rotate-90 group-data-[state=open]:rotate-0"})]})}),(0,a.jsx)(c.CollapsibleContent,{children:(0,a.jsx)("div",{className:"bg-white px-4 pb-4 pt-4 text-sm",children:e.answer})})]})}},86948:(e,t,l)=>{l.d(t,{BT:()=>o,Wu:()=>d,X9:()=>c,ZB:()=>i,Zp:()=>r,aR:()=>n,wL:()=>m});var a=l(95155);l(12115);var s=l(64269);function r({className:e,style:t,...l}){return(0,a.jsx)("div",{"data-slot":"card",style:t,className:(0,s.cn)("theme-card overflow-hidden flex flex-col border",e),...l})}function n({className:e,...t}){return(0,a.jsx)("div",{"data-slot":"card-header",className:(0,s.cn)("@container/card-header theme-card-div
1ider p-4 md:p-6 border-b grid auto-rows-min grid-rows-[auto_auto] items-start gap-1.5 has-data-[slot=card-action]:grid-cols-[1fr_auto]",e),...t})}function i({className:e,...t}){return(0,a.jsx)("div",{"data-slot":"card-title",className:(0,s.cn)("theme-card-title leading-none font-semibold",e),...t})}function o({className:e,...t}){return(0,a.jsx)("div",{"data-slot":"card-description",className:(0,s.cn)("theme-card-accent theme-card-content",e),...t})}function c({className:e,...t}){return(0,a.jsx)("div",{"data-slot":"card-action",className:(0,s.cn)("col-start-2 row-span-2 row-start-1 self-start justify-self-end",e),...t})}function d({className:e,...t}){return(0,a.jsx)("div",{"data-slot":"card-content",className:(0,s.cn)("theme-card-content",e),...t})}function m({className:e,...t}){return(0,a.jsx)("div",{"data-slot":"card-footer",className:(0,s.cn)("theme-card-divider flex border-t items-center p-4 md:p-6",e),...t})}}}]);
2//# sourceMappingURL=3504-a54c5047e9c84ea8.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.