1import{b as J,r as P,j as t}from"./vendor-react-Db0o_2QY.js";import{L as $}from"./app-BKG4hivw.js";import{S as H}from"./Seo-B-CcsmWK.js";import{P as O}from"./public-layout-CUBgyO1p.js";import{U as K}from"./users-CiPR_PDo.js";import{A as E}from"./arrow-right-DrT9wYrf.js";import{Z as V}from"./zap-DV08TNut.js";import{C as z}from"./circle-check-DWiTpIHD.js";import{M as B}from"./map-pin-nDzWoviZ.js";import{M as G}from"./message-square-C9YwWVI_.js";import{T as Q}from"./trending-up-CK1HwFQ9.js";/* empty css */import"./silent-boundary-D1TGHIC4.js";import"./mail-BqzCD901.js";import"./createLucideIcon-DIwWA-hv.js";import"./x-PCuC7deo.js";import"./menu-CV_FroTN.js";import"./star-3OwSVyC6.js";import"./external-link-BqB_e0fn.js";const W={join:"ð",request:"ð",swap:"â
"};function X(s){return s<60?`${s}m ago`:s<1440?`${Math.floor(s/60)}h ago`:`${Math.floor(s/1440)}d ago`}function ee(s){const e=J.c(27),{city:l}=s,i=`/community/${l.slug}`;let a;e[0]!==l.name?(a=t.jsx("h3",{className:"text-base font-black text-slate-900 group-hover:text-brand-indigo",children:l.name}),e[0]=l.name,e[1]=a):a=e[1];let b;e[2]===Symbol.for("react.memo_cache_sentinel")?(b=t.jsx("p",{className:"mt-0.5 text-xs font-medium text-slate-400",children:"Community"}),e[2]=b):b=e[2];let w;e[3]!==a?(w=t.jsxs("div",{children:[a,b]}),e[3]=a,e[4]=w):w=e[4];let u;e[5]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx("div",{className:"flex h-10 w-10 shrink-0 items-center justify-center rounded-xl bg-brand-indigo/10",children:t.jsx(K,{className:"h-5 w-5 text-brand-indigo"})}),e[5]=u):u=e[5];let r;e[6]!==w?(r=t.jsxs("div",{className:"mb-4 flex items-start justify-between gap-2",children:[w,u]}),e[6]=w,e[7]=r):r=e[7];let n;e[8]!==l.member_count?(n=t.jsx("p",{className:"text-lg font-black text-slate-900",children:l.member_count}),e[8]=l.member_count,e[9]=n):n=e[9];let o;e[10]===Symbol.for("react.memo_cache_sentinel")?(o=t.jsx("p",{className:"text-[10px] font-bold tracking-wide text-slate-400 uppercase",children:"Members"}),e[10]=o):o=e[10];let c;e[11]!==n?(c=t.jsxs("div",{className:"rounded-xl bg-slate-50 px-3 py-2.5 text-center",children:[n,o]}),e[11]=n,e[12]=c):c=e[12];let m;e[13]!==l.post_count?(m=t.jsx("p",{className:"text-lg font-black text-brand-indigo",children:l.post_count}),e[13]=l.post_count,e[14]=m):m=e[14];let d;e[15]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx("p",{className:"text-[10px] font-bold tracking-wide text-slate-400 uppercase",children:"Discussions"}),e[15]=d):d=e[15];let x;e[16]!==m?(x=t.jsxs("div",{className:"rounded-xl bg-slate-50 px-3 py-2.5 text-center",children:[m,d]}),e[16]=m,e[17]=x):x=e[17];let h;e[18]!==x||e[19]!==c?(h=t.jsxs("div",{className:"mb-4 grid grid-cols-2 gap-2",children:[c,x]}),e[18]=x,e[19]=c,e[20]=h):h=e[20];let g;e[21]===Symbol.for("react.memo_cache_sentinel")?(g=t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx("span",{className:"h-1.5 w-1.5 animate-pulse rounded-full bg-emerald-400"}),t.jsx("span",{className:"text-[11px] font-medium text-slate-400",children:"Active"})]}),e[21]=g):g=e[21];let p;e[22]===Symbol.for("react.memo_cache_sentinel")?(p=t.jsxs("div",{className:"mt-auto flex items-center justify-between border-t border-slate-100 pt-3",children:[g,t.jsxs("span",{className:"flex items-center gap-1 text-xs font-bold text-brand-indigo group-hover:underline",children:["Join ",t.jsx(E,{className:"h-3 w-3"})]})]}),e[22]=p):p=e[22];let f;return e[23]!==i||e[24]!==h||e[25]!==r?(f=t.jsxs($,{href:i,className:"group flex flex-col rounded-2xl border border-slate-200 bg-white p-5 shadow-sm transition-all hover:border-brand-indigo/40 hover:shadow-md",children:[r,h,p]}),e[23]=i,e[24]=h,e[25]=r,e[26]=f):f=e[26],f}function ve(s){const e=J.c(46),{cities:l,stats:i,activityFeed:a}=s,[b,w]=P.useState(0),u=a.length>0;let r,n;e[0]!==a.length||e[1]!==u?(r=()=>{if(!u)return;const Y=setInterval(()=>w(Z=>(Z+1)%a.length),3500);return()=>clearInterval(Y)},n=[a.length,u],e[0]=a.length,e[1]=u,e[2]=r,e[3]=n):(r=e[2],n=e[3]),P.useEffect(r,n);const o=u?a[b]:null;let c;e[4]===Symbol.for("react.memo_cache_sentinel")?(c=t.jsx(H,{title:"UK Driving Test Community | Discuss Test Dates | TestSwap",description:"Join your local UK driving test community. Discuss test dates, share tips, swap dates with learners in your city. Free to join â no card required.",canonical:"https://testswap.com/community",robots:"index, follow"}),e[4]=c):c=e[4];let m;e[5]===Symbol.for("react.memo_cache_sentinel")?(m=t.jsxs("div",{className:"pointer-events-none absolute inset-0",children:[t.jsx("div",{className:"absolute top-0 right-0 h-[500px] w-[500px] translate-x-1/3 -translate-y-1/4 rounded-full bg-brand-indigo/15 blur-3xl"}),t.jsx("div",{className:"absolute bottom-0 left-0 h-[400px] w-[400px] -translate-x-1/3 translate-y-1/3 rounded-full bg-emerald-900/20 blur-3xl"})]}),e[5]=m):m=e[5];let d;e[6]!==o||e[7]!==b?(d=o&&t.jsxs("div",{className:"mb-4 inline-flex items-center gap-2.5 rounded-full border border-white/20 bg-white/10 px-4 py-2 text-xs font-bold text-white backdrop-blur-sm",children:[t.jsxs("span",{className:"relative flex h-2 w-2 shrink-0",children:[t.jsx("span",{className:"absolute inline-flex h-full w-full animate-ping rounded-full bg-emerald-400 opacity-75"}),t.jsx("span",{className:"relative inline-flex h-2 w-2 rounded-full bg-emerald-400"})]}),t.jsxs("span",{children:[W[o.type]," ",o.text," ·"," ",X(o.mins_ago)]},b)]}),e[6]=o,e[7]=b,e[8]=d):d=e[8];let x,h;e[9]===Symbol.for("react.memo_cache_sentinel")?(x=t.jsxs("h1",{className:"mb-4 text-4xl font-black tracking-tight text-white sm:text-5xl lg:text-6xl",children:["Join Your City's",t.jsx("br",{}),t.jsx("span",{className:"text-brand-indigo",children:"Test Date Community"})]}),h=t.jsx("p",{className:"mb-8 text-lg font-medium text-white/60 sm:text-xl",children:"Connect with learners in your city. Discuss test dates, share tips, and swap dates â like a Facebook group for UK learners."}),e[9]=x,e[10]=h):(x=e[9],h=e[10]);let g;e[11]===Symbol.for("react.memo_cache_sentinel")?(g=t.jsxs("div",{className:"flex flex-wrap justify-center gap-3",children:[t.jsxs("a",{href:"#cities",className:"inline-flex items-center gap-2 rounded-xl bg-brand-indigo px-7 py-3 text-sm font-black text-white shadow-lg shadow-brand-indigo/30 transition-all hover:bg-brand-indigo/90",children:["Choose Your City"," ",t.jsx(E,{className:"h-4 w-4"})]}),t.jsx($,{href:"/register",className:"inline-flex items-center gap-2 rounded-xl border border-white/20 bg-white/10 px-7 py-3 text-sm font-bold text-white backdrop-blur-sm transition-all hover:bg-white/20",children:"Register for TestSwap"})]}),e[11]=g):g=e[11];let p;e[12]!==d?(p=t.jsxs("div",{className:"mx-auto max-w-3xl text-center",children:[d,x,h,g]}),e[12]=d,e[13]=p):p=e[13];let f;e[14]!==i.total_learners?(f={value:i.total_learners,label:"Learners Registered",icon:K},e[14]=i.total_learners,e[15]=f):f=e[15];
1const L=i.active_requests.toLocaleString()+"+";let j;e[16]!==L?(j={value:L,label:"Active Swap Requests",icon:V},e[16]=L,e[17]=j):j=e[17];const R=i.completed_swaps.toLocaleString()+"+";let y;e[18]!==R?(y={value:R,label:"Successful Swaps",icon:z},e[18]=R,e[19]=y):y=e[19];let N;e[20]!==i.centres?(N=i.centres.toString(),e[20]=i.centres,e[21]=N):N=e[21];let v;e[22]!==N?(v={value:N,label:"UK Test Centres",icon:B},e[22]=N,e[23]=v):v=e[23];let _;e[24]!==f||e[25]!==j||e[26]!==y||e[27]!==v?(_=t.jsx("div",{className:"mt-12 grid grid-cols-2 overflow-hidden rounded-2xl border border-white/10 bg-white/5 backdrop-blur-sm md:grid-cols-4",children:[f,j,y,v].map(le)}),e[24]=f,e[25]=j,e[26]=y,e[27]=v,e[28]=_):_=e[28];let S;e[29]!==_||e[30]!==p?(S=t.jsxs("section",{className:"relative overflow-hidden bg-gradient-to-br from-slate-900 via-brand-indigo/20 to-slate-900 py-16 sm:py-20",children:[m,t.jsxs("div",{className:"relative mx-auto max-w-7xl px-4 sm:px-6 lg:px-8",children:[p,_]})]}),e[29]=_,e[30]=p,e[31]=S):S=e[31];let T;e[32]===Symbol.for("react.memo_cache_sentinel")?(T=t.jsxs("div",{className:"mx-auto max-w-2xl text-center",children:[t.jsx("h2",{className:"mb-2 text-2xl font-black text-slate-900",children:"How the community works"}),t.jsx("p",{className:"mb-8 text-sm text-slate-500",children:"Simple, free, no account needed â just pick your city and join"})]}),e[32]=T):T=e[32];let I;e[33]===Symbol.for("react.memo_cache_sentinel")?(I=t.jsx("section",{className:"bg-white py-12",children:t.jsxs("div",{className:"mx-auto max-w-7xl px-4 sm:px-6 lg:px-8",children:[T,t.jsx("div",{className:"mx-auto grid max-w-4xl grid-cols-1 gap-6 sm:grid-cols-3",children:[{step:"1",title:"Pick your city",desc:"Choose the city closest to your test centre from the list below."},{step:"2",title:"Sign up in seconds",desc:"Enter your name, email and confirm your city â no password needed."},{step:"3",title:"Join the conversation",desc:"Post about your test date, ask questions, or find someone to swap with."}].map(se)})]})}),e[33]=I):I=e[33];let M;e[34]===Symbol.for("react.memo_cache_sentinel")?(M=t.jsxs("div",{className:"mb-8 flex items-center gap-3",children:[t.jsx(G,{className:"h-6 w-6 text-brand-indigo"}),t.jsx("h2",{className:"text-xl font-black text-slate-900",children:"Choose your city"})]}),e[34]=M):M=e[34];let k;e[35]!==l?(k=l.map(te),e[35]=l,e[36]=k):k=e[36];let C;e[37]!==k?(C=t.jsx("section",{id:"cities",className:"bg-slate-50 py-12",children:t.jsxs("div",{className:"mx-auto max-w-7xl px-4 sm:px-6 lg:px-8",children:[M,t.jsx("div",{className:"grid grid-cols-2 gap-4 sm:grid-cols-3 lg:grid-cols-4",children:k})]})}),e[37]=k,e[38]=C):C=e[38];let A,D,F;e[39]===Symbol.for("react.memo_cache_sentinel")?(A=t.jsx(Q,{className:"mx-auto mb-4 h-8 w-8 text-white/40"}),D=t.jsx("h2",{className:"mb-3 text-2xl font-black text-white sm:text-3xl",children:"Also want to swap your actual test date?"}),F=t.jsx("p",{className:"mb-8 text-sm font-medium text-white/70",children:"The community is for discussions. For the real swap â register on TestSwap and our engine matches you automatically."}),e[39]=A,e[40]=D,e[41]=F):(A=e[39],D=e[40],F=e[41]);let U;e[42]===Symbol.for("react.memo_cache_sentinel")?(U=t.jsx("section",{className:"bg-brand-indigo py-16",children:t.jsxs("div",{className:"mx-auto max-w-3xl px-6 text-center",children:[A,D,F,t.jsxs($,{href:"/register",className:"inline-flex items-center gap-2 rounded-xl bg-white px-8 py-3.5 text-sm font-black tracking-wider text-brand-indigo uppercase shadow-lg transition-all hover:bg-slate-50",children:["Find a Swap Free ",t.jsx(E,{className:"h-4 w-4"})]})]})}),e[42]=U):U=e[42];let q;return e[43]!==S||e[44]!==C?(q=t.jsxs(O,{children:[c,S,I,C,U]}),e[43]=S,e[44]=C,e[45]=q):q=e[45],q}function te(s){return t.jsx(ee,{city:s},s.slug)}function se(s){return t.jsxs("div",{className:"flex gap-4 rounded-2xl border border-slate-100 bg-slate-50 p-5",children:[t.jsx("div",{className:"flex h-9 w-9 shrink-0 items-center justify-center rounded-xl bg-brand-indigo text-sm font-black text-white",children:s.step}),t.jsxs("div",{children:[t.jsx("p",{className:"font-bold text-slate-900",children:s.title}),t.jsx("p",{className:"mt-1 text-sm text-slate-500",children:s.desc})]})]},s.step)}function le(s,e){return t.jsxs("div",{className:"border-r border-b border-white/10 px-6 py-5 text-center last:border-r-0 md:border-b-0",children:[t.jsx(s.icon,{className:"mx-auto mb-2 h-5 w-5 text-white/30"}),t.jsx("div",{className:"text-2xl font-black text-white",children:s.value}),t.jsx("div",{className:"mt-1 text-[11px] font-bold tracking-widest text-white/40 uppercase",children:s.label})]},e)}export{ve 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.