PageSourceSearch

https://disasterexpotexas.com/assets/Ambassadors-BHNdeQwX.js

js disasterexpotexas.com collected 2026-09-28 12:11:11 UTC 16,946 bytes, 1 lines download raw bytes

1import{j as e}from"./vendor-ui-CezFABrC.js";import{t as K,u as P,Q as H,R as q,X as I,w as Q,x as U,y as W,T as E,E as _,S as G,I as Y,a as Z,b as X,c as J,d as ee,e as z,g as se,L as te,B as le,D as ae,N as re,P as oe,F as ne,U as F,s as ie,V as ce}from"./index-Rt0ORiw_.js";import{u as de}from"./vendor-data-kfxz6GN9.js";import{h as me,r as i}from"./vendor-react-BKa71ujQ.js";import"./vendor-dnd-CuNJvw6T.js";import"./vendor-charts-DDSFMeER.js";import"./vendor-editor-Dg0kxhZ2.js";import"./vendor-motion-ClyPiY3v.js";import"./vendor-carousel-ClXKjko3.js";const xe=({name:t,photoUrl:d,title:r,company:m,companyLogoUrl:o,linkedinUrl:p,onClick:f})=>e.jsx("div",{onClick:f,className:"h-full",children:e.jsxs("div",{className:"h-full flex flex-col group cursor-pointer bg-white rounded-lg overflow-hidden transition-all duration-300 border border-gray-200 shadow-sm hover:shadow-md",children:[e.jsxs("div",{className:"relative aspect-square overflow-hidden bg-muted",children:[d?e.jsx("img",{src:d,alt:`${t??"Ambassador"} photo`,className:"w-full h-full object-cover object-top transition-transform duration-500 group-hover:scale-105"}):e.jsx("div",{className:"w-full h-full flex items-center justify-center bg-gradient-to-br from-primary/10 to-accent/10",children:e.jsx("span",{className:"text-4xl font-bold text-muted-foreground/30",children:(t??"?").charAt(0)})}),o&&e.jsx("div",{className:"absolute bottom-2 right-2 w-16 h-16 rounded-full border-2 border-border/60 flex items-center justify-center p-2 bg-background shadow-sm overflow-hidden",children:e.jsx("img",{src:o,alt:`${m} logo`,className:"w-full h-full object-contain"})})]}),e.jsxs("div",{className:"p-4 space-y-1 flex-grow",children:[e.jsx("h3",{className:"font-bold text-base text-foreground group-hover:text-primary transition-colors line-clamp-1",children:t??"Ambassador"}),r&&e.jsx("p",{className:"text-sm text-gray-600 line-clamp-1",children:r}),m&&e.jsx("p",{className:"text-sm text-gray-600 line-clamp-1",children:m})]}),p&&e.jsx("div",{className:"flex items-center gap-2 px-4 pb-4 opacity-0 group-hover:opacity-100 transition-opacity duration-300",children:e.jsx("div",{className:"p-1.5 rounded-md bg-primary/10 text-primary hover:bg-primary hover:text-white transition-all duration-200",children:e.jsx(K,{className:"h-3.5 w-3.5"})})})]})}),b="#0A0A0A",g="#FFFFFF",T="#F5F1EA",x="#E85D1F",pe="rgba(10,10,10,0.6)",L="rgba(10,10,10,0.4)",D="'Archivo Black', 'Inter', system-ui, sans-serif",he=({ambassador:t,open:d,onOpenChange:r})=>{const m=me(),{data:o}=P(),[p,f]=i.useState(!1);i.useEffect(()=>{const n="gf-archivo-black";if(document.getElementById(n))return;const c=document.createElement("link");c.id=n,c.rel="stylesheet",c.href="https://fonts.googleapis.com/css2?family=Archivo+Black&display=swap",document.head.appendChild(c)},[]),i.useEffect(()=>(d?(document.body.style.overflow="hidden",document.body.classList.add("modal-open")):(document.body.style.overflow="",document.body.classList.remove("modal-open")),()=>{document.body.style.overflow="",document.body.classList.remove("modal-open")}),[d]);const C=async()=>{var w;if(!t)return;const c=`https://${((w=o==null?void 0:o.event_domain)==null?void 0:w.replace(/^https?:\/\//,""))||window.location.host}/ambassadors/${W(t.name)}`;await navigator.clipboard.writeText(c),f(!0),setTimeout(()=>f(!1),2e3)};if(!t)return null;const j=t.name.trim().split(/\s+/),v=j[0],h=j.slice(1).join(" "),N=t.title&&t.company?`${t.title} @ ${t.company}`:t.title||t.company||"Event Ambassador";return e.jsx(H,{open:d,onOpenChange:r,children:e.jsxs(q,{className:"!max-w-6xl w-[96vw] !max-h-[92vh] h-[92vh] p-0 gap-0 border-0 rounded-2xl shadow-2xl [&>button]:hidden overflow-hidden grid-rows-1",style:{background:g,color:b,fontFamily:"'Inter', system-ui, sans-serif"},children:[e.jsx("button",{onClick:()=>r(!1),className:"absolute top-4 right-4 sm:top-6 sm:right-6 z-50 p-2.5 rounded-full transition-all hover:bg-black/5","aria-label":"Close",style:{color:b},children:e.jsx(I,{className:"w-5 h-5"})}),e.jsxs("div",{className:"flex flex-col h-full min-h-0 overflow-hidden",children:[e.jsxs("div",{className:"relative h-40 sm:h-48 shrink-0",style:{background:g},children:[e.jsx("div",{className:"absolute inset-0 opacity-10 z-10",style:{backgroundImage:"url('https://www.transparenttextures.com/patterns/topography.png')"}}),t.photo_url&&e.jsx("img",{src:t.photo_url,alt:"","aria-hidden":!0,
1className:"absolute inset-0 w-full h-full object-cover opacity-15 grayscale"}),e.jsx("div",{className:"absolute inset-0 z-20",style:{background:"linear-gradient(to top, #FFFFFF, transparent)"}}),e.jsx("div",{className:"absolute -bottom-12 left-6 sm:left-12 z-30",children:e.jsx("div",{className:"w-32 h-32 sm:w-44 sm:h-44 rounded-full border-[6px] overflow-hidden shadow-2xl",style:{borderColor:g,background:T},children:t.photo_url?e.jsx("img",{src:t.photo_url,alt:t.name,className:"w-full h-full object-cover object-top"}):e.jsx("div",{className:"w-full h-full flex items-center justify-center",style:{background:T},children:e.jsx("span",{className:"text-5xl font-bold",style:{fontFamily:D,color:x},children:t.name.charAt(0)})})})})]}),e.jsx("div",{className:"flex-1 overflow-y-auto speaker-modal-scroll","data-lenis-prevent":!0,children:e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-12 gap-8 lg:gap-14 p-6 sm:p-8 md:p-12 pt-16 sm:pt-16",children:[e.jsxs("div",{className:"md:col-span-7 space-y-10 min-w-0",children:[e.jsxs("header",{children:[e.jsxs("div",{className:"flex items-center gap-3 mb-4",children:[e.jsx("span",{className:"px-3 py-1 text-[10px] font-bold tracking-[0.2em] uppercase rounded-sm",style:{background:x,color:g},children:"Ambassador"}),e.jsx("div",{className:"h-px flex-1",style:{background:"rgba(10,10,10,0.12)"}})]}),e.jsxs("h1",{className:"text-4xl sm:text-5xl lg:text-6xl font-extrabold leading-[1.05] tracking-tight",style:{fontFamily:D,color:b},children:[v,h&&e.jsxs(e.Fragment,{children:[" ",e.jsx("span",{style:{color:x},children:h})]})]}),e.jsx("p",{className:"text-lg sm:text-xl mt-3 font-light tracking-wide italic",style:{color:pe},children:N})]}),e.jsxs("section",{className:"space-y-4",children:[e.jsx("h3",{className:"text-xs font-bold tracking-[0.3em] uppercase",style:{color:x},children:"About The Ambassador"}),t.bio?e.jsx("p",{className:"leading-relaxed text-base sm:text-lg font-light whitespace-pre-wrap",style:{color:"rgba(10,10,10,0.85)"},children:t.bio}):e.jsx("p",{style:{color:L},children:"Biography coming soon."})]})]}),e.jsxs("div",{className:"md:col-span-5 space-y-8",children:[e.jsxs("div",{className:"space-y-4",children:[e.jsx("button",{onClick:()=>{r(!1),m("/registration")},className:"w-full py-4 sm:py-5 rounded-xl transition-all font-black tracking-widest text-sm hover:brightness-110",style:{background:x,color:g},children:"REGISTER TO ATTEND"}),e.jsxs("div",{className:"flex gap-3",children:[t.linkedin_url&&e.jsxs("a",{href:t.linkedin_url,target:"_blank",rel:"noopener noreferrer",className:"flex-1 flex items-center justify-center gap-2 py-3 px-4 border rounded-xl transition-colors hover:bg-black/5",style:{borderColor:"rgba(10,10,10,0.12)",color:b},children:[e.jsx(K,{className:"w-4 h-4"}),e.jsx("span",{className:"text-xs font-bold tracking-wider",children:"CONNECT"})]}),e.jsxs("button",{onClick:C,className:"flex-1 flex items-center justify-center gap-2 py-3 px-4 border rounded-xl transition-colors hover:bg-black/5",style:{borderColor:"rgba(10,10,10,0.12)",color:b},children:[p?e.jsx(Q,{className:"w-4 h-4",style:{color:x}}):e.jsx(U,{className:"w-4 h-4"}),e.jsx("span",{className:"text-xs font-bold tracking-wider",children:p?"COPIED":"SHARE"})]})]})]}),t.company&&e.jsxs("div",{className:"p-5 sm:p-6 rounded-2xl border",style:{background:T,borderColor:"rgba(10,10,10,0.06)"},children:[e.jsx("p",{className:"text-[10px] font-bold uppercase tracking-widest mb-4",style:{color:L},children:"Representing"}),e.jsxs("div",{className:"flex items-center gap-4",children:[t.company_logo_url?e.jsx("div",{className:"w-12 h-12 rounded-lg flex items-center justify-center p-1.5 shrink-0 overflow-hidden",style:{background:g},children:e.jsx("img",{src:t.company_logo_url,alt:`${t.company} logo`,className:"w-full h-full object-contain"})}):e.jsx("div",{className:"w-12 h-12 rounded-lg flex items-center justify-center shrink-0",style:{background:g},children:e.jsx("span",{className:"font-bold text-lg",style:{fontFamily:D,color:x},children:t.company.charAt(0)})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h4",{className:"font-bold tracking-tight truncate",style:{color:b},children:t.company}),t.title&&e.jsx("p",{className:"text-xs truncate",style:{color:L},children:t.title})]})]})]})]})]})}),e.jsx("div",{className:"h-1 w-full shrink-0",style:{background:"rgba(10,10,10,0.08)"},children:e.jsx("div",{className:"h-full w-1/3",style:{background:x}})})]})]})})},ke=()=>{P();const[t,d]=i.useState(null),[r,m]=i.useState(""),[o,p]=i.useState("all"),[f,C]=i.useState(null),[j,v]=i.useState(!1),[h,N]=i.useState(!1),{data:n,isLoading:c}=de({queryKey:["ambassadors"],queryFn:async()=>{const{data:s,error:l}=await ie.from("ambassadors").select("*").eq("is_active",!0).order("display_order",{ascending:!0}).order("name",{ascending:!0});if(l)throw l;return(s||[]).filter(a=>ce(a.visible_on_shows,F))}}),w="ABCDEFGHIJKLMNOPQRSTUVWXYZ".split(""),S=i.useMemo(()=>{const s=new Set;
1return(n||[]).forEach(l=>l.company&&s.add(l.company)),Array.from(s).sort((l,a)=>l.localeCompare(a))},[n]),k=i.useMemo(()=>{if(!n)return[];let s=n;if(t&&(s=s.filter(l=>(l.name??"").toUpperCase().startsWith(t))),r.trim()){const l=r.toLowerCase();s=s.filter(a=>{var u,y,$;return(a.name??"").toLowerCase().includes(l)||((u=a.title)==null?void 0:u.toLowerCase().includes(l))||((y=a.company)==null?void 0:y.toLowerCase().includes(l))||(($=a.bio)==null?void 0:$.toLowerCase().includes(l))})}return o!=="all"&&(s=s.filter(l=>l.company===o)),s},[n,t,r,o]),V=s=>{const l=(s.visible_on_shows??[]).filter(Boolean);return l.length===0?F:l.length===1?l[0]:l.find(a=>a!==F)??l[0]},M=s=>{var l;return((l=E.find(a=>a.key===s))==null?void 0:l.label.replace(/\s*\(Parent\)\s*$/i,""))??s},R=i.useMemo(()=>{const s=new Map;return k.forEach(a=>{const u=V(a),y=s.get(u)??[];y.push(a),s.set(u,y)}),[...E.map(a=>a.key),...Array.from(s.keys()).filter(a=>!E.some(u=>u.key===a))].filter(a=>s.has(a)).map(a=>({key:a,label:M(a),items:s.get(a)}))},[k]),O=()=>{d(null),m(""),p("all"),N(!1)},A=(t?1:0)+(r.trim()?1:0)+(o!=="all"?1:0),B=i.useMemo(()=>[{id:"ambassadors-hero",component:e.jsx("section",{className:"relative pt-2 pb-8 md:pt-4 md:pb-12",children:e.jsxs("div",{className:"relative overflow-hidden",children:[e.jsxs("div",{className:"flex items-center justify-between py-2 mb-6 text-[11px] uppercase tracking-[0.2em] font-medium text-foreground/70 border-y border-foreground
1/20",children:[e.jsx("span",{children:"The Ambassador Edit"}),e.jsx("span",{className:"hidden sm:inline",children:"Vol. 01 · Championing The Show"}),e.jsx("span",{children:c?"—":`${(n==null?void 0:n.length)??0} Ambassadors`})]}),e.jsxs("div",{className:"animate-fade-up",children:[e.jsx(_,{pageName:"ambassadors",sectionName:"hero",contentKey:"eyebrow",defaultValue:"Our Advocates",className:"block text-xs md:text-sm uppercase tracking-[0.3em] text-primary font-semibold mb-3",as:"span"}),e.jsx(_,{pageName:"ambassadors",sectionName:"hero",contentKey:"title",defaultValue:"Ambassadors",className:"font-display uppercase leading-[0.85] tracking-tight text-foreground text-[15vw] md:text-[8rem] lg:text-[10rem] mb-4",as:"h1"}),e.jsx(_,{pageName:"ambassadors",sectionName:"hero",contentKey:"subtitle",defaultValue:"The leaders, advocates and champions representing the show across the resilience community.",className:"block font-serif italic text-lg md:text-xl text-foreground/70 leading-snug",as:"p"})]}),e.jsx("div",{className:"mt-6 border-b border-foreground
1/20"})]})})},{id:"ambassadors-list",component:e.jsxs("section",{className:"pb-8",children:[e.jsx("div",{className:"sticky top-0 z-[110] -mx-4 px-4 py-3 md:py-4 bg-background/95 backdrop-blur-xl border-b border-foreground/10 shadow-[0_10px_30px_hsl(var(--foreground)/0.08)] mb-8",children:e.jsxs("div",{className:"flex flex-col gap-3",children:[e.jsxs("div",{className:"flex flex-col lg:flex-row lg:items-center gap-3",children:[e.jsxs("div",{className:"relative flex-1 min-w-0",children:[e.jsx(G,{className:"absolute left-4 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground"}),e.jsx(Y,{type:"text",placeholder:"Search ambassadors, titles, companies…",value:r,onChange:s=>{m(s.target.value)},className:"pl-11 pr-10 h-11 border border-foreground/15 rounded-full bg-background focus-visible:ring-1 focus-visible:ring-primary","aria-label":"Search ambassadors"}),r&&e.jsx("button",{onClick:()=>{m("")},className:"absolute right-3 top-1/2 -translate-y-1/2 p-1 rounded-full hover:bg-muted","aria-label":"Clear search",children:e.jsx(I,{className:"h-4 w-4 text-muted-foreground"})})]}),e.jsxs("div",{className:"flex flex-wrap gap-2",children:[S.length>0&&e.jsxs(Z,{value:o,onValueChange:s=>{p(s)},children:[e.jsx(X,{className:"h-11 min-w-[180px] max-w-[240px] rounded-full border-foreground
1/15 bg-background",children:e.jsx(J,{placeholder:"Company"})}),e.jsxs(ee,{className:"bg-background z-50 max-h-72",children:[e.jsx(z,{value:"all",children:"All companies"}),S.map(s=>e.jsx(z,{value:s,children:s},s))]})]}),e.jsxs("button",{onClick:()=>N(s=>!s),className:`h-11 px-4 inline-flex items-center gap-2 rounded-full border text-sm font-medium transition-colors ${h||t?"bg-foreground text-background border-foreground":"bg-background border-foreground/15 hover:bg-muted"}`,"aria-expanded":h,"aria-label":"Toggle A to Z filter",children:[e.jsx(se,{className:"h-4 w-4"}),"A–Z",t?` · ${t}`:""]}),A>0&&e.jsxs("button",{onClick:O,className:"h-11 px-4 inline-flex items-center gap-2 rounded-full text-sm font-medium text-foreground/70 hover:text-foreground",children:[e.jsx(I,{className:"h-4 w-4"})," Clear (",A,")"]})]})]}),h&&e.jsx("div",{className:"flex flex-wrap gap-1.5 pt-1 animate-fade-in",children:w.map(s=>{const l=t===s;return e.jsx("button",{onClick:()=>{d(l?null:s)},className:`h-8 w-8 text-xs font-bold rounded-full transition-all ${l?"bg-primary text-primary-foreground scale-110":"bg-muted text-foreground/70 hover:bg-foreground hover:text-background"}`,"aria-pressed":l,children:s},s)})})]})}),c?e.jsx("div",{className:"flex justify-center items-center py-20",children:e.jsx(te,{className:"h-12 w-12 animate-spin text-primary"})}):k.length>0?e.jsx("div",{className:"space-y-14",children:R.map(s=>e.jsxs("div",{children:[e.jsxs("div",{className:"flex items-end justify-between gap-4 mb-6",children:[e.jsxs("div",{children:[e.jsx("span",{className:"block text-[10px] uppercase tracking-[0.3em] text-primary font-semibold mb-1",children:"Show"}),e.jsx("h2",{className:"font-display uppercase leading-none tracking-tight text-foreground text-2xl md:text-4xl",children:s.label})]}),e.jsxs("span",{className:"text-[11px] uppercase tracking-[0.18em] text-foreground/60 whitespace-nowrap pb-1",children:[s.items.length," ",s.items.length===1?"Ambassador":"Ambassadors"]})]}),e.jsx("div",{className:"grid grid-cols-2 md:grid-cols-3 lg:grid-cols-5 auto-rows-fr gap-3 md:gap-5 animate-fade-in",children:s.items.map((l,a)=>e.jsxs("div",{className:"col-span-1 group relative",style:{animationDelay:`${a*30}ms`},children:[e.jsxs("div",{className:"absolute -top-2 -left-1 z-10 font-display text-xs md:text-sm text-primary/80 select-none",children:["№ ",String(a+1).padStart(2,"0")]}),e.jsx("div",{className:"absolute inset-0 -m-1 rounded-xl border border-transparent group-hover:border-primary/40 transition-colors pointer-events-none"}),e.jsx(xe,{id:l.id,name:l.name,bio:l.bio||void 0,photoUrl:l.photo_url||void 0,title:l.title||void 0,company:l.company||void 0,companyLogoUrl:l.company_logo_url||void 0,linkedinUrl:l.linkedin_url||void 0,onClick:()=>{C(l),v(!0)}})]},l.id))})]},s.key))}):e.jsxs("div",{className:"text-center py-24 border border-dashed border-foreground
1/15 rounded-xl",children:[e.jsx("p",{className:"font-display text-3xl md:text-4xl text-foreground/80 mb-2",children:"Nothing matches."}),e.jsx("p",{className:"text-muted-foreground mb-6",children:"Try clearing a filter or widening your search."}),A>0&&e.jsx(le,{onClick:O,variant:"outline",children:"Reset filters"})]})]})}],[n,t,r,o,k,R,c,h,A,S]);return e.jsxs(e.Fragment,{children:[e.jsx(ae,{titlePrefix:"Ambassadors",description:"Meet the ambassadors championing {eventName}. {eventDate} at {eventLocation}.",keywords:"{eventName}, ambassadors, advocates, community leaders, {eventLocation}"}),e.jsxs("div",{className:"min-h-screen flex flex-col bg-background pt-page theme-light",children:[e.jsx(re,{}),e.jsx("main",{className:"flex-1 container mx-auto px-4 pt-page pb-12",children:e.jsx(oe,{pageName:"ambassadors",sections:B})}),e.jsx(he,{ambassador:f,open:j,onOpenChange:v}),e.jsx(ne,{})]})]})};export{ke 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.