1import{j as e}from"./editor-BhGk7_S1.js";import{c as W,g as k,u as Z,b as E,a as H,L as z,w as J,x as X,y as Y,z as K}from"./index-BjIHAQhU.js";import{t as F}from"./countryTranslations--xXtAg9U.js";import{B as ee}from"./button-CK76V7Lo.js";import{R as te,C as se,f as ae,T as le,P as ce,O as re}from"./dialog-DDbhAKMR.js";import{X as ie}from"./x-rm1_-8OE.js";import{u as oe}from"./useAuth-D2-kN8CV.js";import{P as ne,L as de}from"./LoginPopup-DdTizF10.js";import{b as u}from"./leaflet-DcfcX7a_.js";import{G as xe}from"./globe-rpSIUeg6.js";import{Z as pe}from"./zap-BAlY3V9-.js";import{E as me}from"./external-link-CS0ljcpf.js";import"./mapbox-BPFQ-Sfv.js";import"./trpc-DqtxhgQo.js";import"./index-CmmlU_cv.js";import"./useSessionId-BP6UZxE1.js";import"./AuthModal-DOX1HBlV.js";import"./CityAutocomplete-t8y1NAcF.js";import"./input-BtSXPsMX.js";import"./languages-CKIgFA9r.js";import"./languageTranslations-BWtqfsq5.js";import"./log-in-CXlq96ds.js";import"./sparkles-d8zLxPkz.js";import"./refresh-cw-A4TQI-r2.js";import"./users-CXg3PGFq.js";import"./message-square-QRsypMbA.js";/** 2 * @license lucide-react v0.453.0 - ISC 3 * 4 * This source code is licensed under the ISC license. 5 * See the LICENSE file in the root directory of this source tree. 6 */const ge=W("Timer",[["line",{x1:"10",x2:"14",y1:"2",y2:"2",key:"14vaq8"}],["line",{x1:"12",x2:"15",y1:"14",y2:"11",key:"17fdiu"}],["circle",{cx:"12",cy:"14",r:"8",key:"1e1u0o"}]]);function ue({...o}){return e.jsx(te,{"data-loc":"client/src/components/ui/sheet.tsx:10","data-slot":"sheet",...o})}function he({...o}){return e.jsx(ce,{"data-loc":"client/src/components/ui/sheet.tsx:28","data-slot":"sheet-portal",...o})}function fe({className:o,...s}){return e.jsx(re,{"data-loc":"client/src/components/ui/sheet.tsx:36","data-slot":"sheet-overlay",className:k("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",o),...s})}function be({className:o,children:s,side:h="right",...M}){return e.jsxs(he,{"data-loc":"client/src/components/ui/sheet.tsx:56",children:[e.jsx(fe,{"data-loc":"client/src/components/ui/sheet.tsx:57"}),e.jsxs(se,{"data-loc":"client/src/components/ui/sheet.tsx:58","data-slot":"sheet-content",className:k("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-300 data-[state=open]:duration-500",h==="right"&&"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",h==="left"&&"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",h==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",h==="bottom"&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",o),...M,children:[s,e.jsxs(ae,{"data-loc":"client/src/components/ui/sheet.tsx:75",className:"ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none",children:[e.jsx(ie,{"data-loc":"client/src/components/ui/sheet.tsx:76",className:"size-4"}),e.jsx("span",{"data-loc":"client/src/components/ui/sheet.tsx:77",className:"sr-only",children:"Close"})]})]})]})}function je({className:o,...s}){return e.jsx("div",{"data-loc":"client/src/components/ui/sheet.tsx:86","data-slot":"sheet-header",className:k("flex flex-col gap-1.5 p-4",o),...s})}function Le({className:o,...s}){return e.jsx(le,{"data-loc":"client/src/components/ui/sheet.tsx:109","data-slot":"sheet-title",className:k("text-foreground font-semibold",o),...s})}function We(){const{t:o,language:s}=Z(),{user:h}=oe(),M=["sure","very_probable","probable","uncertain"],[_,B]=u.useState(1),D=M.slice(0,_+1),[I,T]=u.useState(!1),[x,A]=u.useState(null),{data:C,isLoading:U}=E.lastMile.getLastMileCountries.useQuery({}),{data:f,isLoading:q}=E.lastMile.getLastMileStats.useQuery({}),V=u.useMemo(()=>new Date(2026,3,22,23,59,59),[]),$=()=>{const t=new Date,a=V.getTime()-t.getTime();if(a<=0)return{days:0,hours:0,minutes:0,seconds:0};const r=Math.floor(a/(1e3*60*60*24)),i=Math.floor(a%(1e3*60*60*24)/(1e3*60*60)),n=Math.floor(a%(1e3*60*60)/(1e3*60)),m=Math.floor(a%(1e3*60)/1e3);return{days:r,hours:i,minutes:n,seconds:m}},[N,G]=u.useState($);u.useEffect(()=>{const t=setInterval(()=>G($()),1e3);return()=>clearInterval(t)},[]);const b={sure:s==="fr"?"Certain":"Sure",very_probable:s==="fr"?"Très probable":"Ver
6y Probable",probable:"Probable",uncertain:s==="fr"?"Incertain":"Uncertain"},O={sure:"bg-[oklch(0.33_0.18_259)] text-white",very_probable:"bg-[oklch(0.50_0.15_259)] text-white",probable:"bg-[oklch(0.65_0.12_259)] text-white",uncertain:"bg-[oklch(0.75_0.08_259)] text-white"},w=t=>{const a={sure:0,very_probable:1,probable:2,uncertain:3};return[...t].sort((r,i)=>{const n=a[r.status]??4,m=a[i.status]??4;return n-m})},v=(t,a)=>{if(!t)return"";const r=new Date(t);if(a==="month"){const i=r.toLocaleDateString(s==="fr"?"fr-FR":"en-US",{month:"short"}),n=String(r.getFullYear()).slice(-2);return`${i} ${n}`}return r.toLocaleDateString("fr-FR",{day:"2-digit",month:"2-digit"})},p=u.useMemo(()=>C?C.filter(t=>D.includes(t.bestStatus)):[],[C,D]),Q=p.length,P=100-(f?.participating||0);return U||q?e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:119",className:"min-h-screen flex items-center justify-center bg-background text-foreground",children:[e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:120",className:"starfield"}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:121",className:"flex flex-col items-center gap-4",children:[e.jsx(H,{"data-loc":"client/src/pages/LastMile.tsx:122",className:"w-12 h-12 animate-spin text-primary"}),e.jsx("p",{"data-loc":"client/src/pages/LastMile.tsx:123",className:"text-muted-foreground",children:"Loading Last Mile..."})]})]}):e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:130",className:"min-h-screen bg-background text-foreground",children:[e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:131",className:"starfield"}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:133",className:"relative z-10",children:[e.jsx("header",{"data-loc":"client/src/pages/LastMile.tsx:135",className:"border-b-2 border-b-[#0047FF] bg-gradient-to-r from-[#0a0e27] to-[#0a1a3a] backdrop-blur-sm",children:e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:136",className:"container py-6",children:e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:137",className:"flex justify-between items-center",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:138",children:[e.jsx("h1",{"data-loc":"client/src/pages/LastMile.tsx:139",className:"text-xl md:text-4xl font-bold bg-gradient-to-r from-[#0080FF] to-[#00A3FF] bg-clip-text text-transparent mb-1 md:mb-2",children:s==="fr"?"Dernière Ligne Droite":"Last Mile"}),e.jsx("p",{"data-loc":"client/src/pages/LastMile.tsx:142",className:"text-sm md:text-lg text-muted-foreground",children:s==="fr"?"Les prochains pays à illuminer":"The next countries to illuminate"})]}),e.jsx(z,{"data-loc":"client/src/pages/LastMile.tsx:146",href:"/",children:e.jsx(ee,{"data-loc":"client/src/pages/LastMile.tsx:147",variant:"outline",className:"bg-transparent",children:s==="fr"?"Retour site":"Back to site"})})]})})}),e.jsxs("main",{"data-loc":"client/src/pages/LastMile.tsx:156",className:"container py-8 space-y-8",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:159",className:"flex flex-col items-center gap-1",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:160",className:"flex items-center gap-2 text-muted-foreground text-xs md:text-sm",children:[e.jsx(ge,{"data-loc":"client/src/pages/LastMile.tsx:161",className:"w-4 h-4 text-[oklch(0.60_0.10_259)] shrink-0"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:162",children:s==="fr"?"avant le 22 avril":"until April 22"})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:164",className:"flex items-center gap-1 font-mono font-bold text-[oklch(0.60_0.10_259)]",children:[e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:165",className:"text-2xl md:text-3xl",children:String(N.days).padStart(2,"0")}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:166",className:"text-xl md:text-2xl text-muted-foreground",children:":"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:167",className:"text-2xl md:text-3xl",children:String(N.hours).padStart(2,"0")}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:168",className:"text-xl md:text-2xl text-muted-foreground",children:":"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:169",className:"text-2xl md:text-3xl",children:String(N.minutes).padStart(2,"0")}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:170",className:"text-xl md:text-2xl text-muted-foreground",children:":"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:171",className:"text-2xl md:text-3xl",children:String(N.seconds).padStart(2,"0")})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:173",className:"flex gap-4 text-xs text-muted-foreground
6/60",children:[e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:174",children:s==="fr"?"jours":"days"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:175",children:s==="fr"?"heures":"hours"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:176",children:"min"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:177",children:"sec"})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:182",className:"grid grid-cols-2 gap-3 md:gap-4",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:184",className:"bg-white/5 backdrop-blur-md rounded-xl p-4 md:p-6 border border-white/10 hover:bg-white/10 transition-all",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:185",className:"flex items-center gap-2 md:gap-3 mb-2 md:mb-3",children:[e.jsx(xe,{"data-loc":"client/src/pages/LastMile.tsx:186",className:"w-4 md:w-5 h-4 md:h-5 text-[oklch(0.60_0.10_259)]"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:187",className:"text-xs md:text-sm text-muted-foreground",children:s==="fr"?"Actuels":"Current"})]}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:191",className:"text-2xl md:text-4xl font-bold text-[oklch(0.60_0.10_259)]",children:f?.participating||0}),e.jsx("p",{"data-loc":"client/src/pages/LastMile.tsx:194",className:"text-xs text-muted-foreground mt-1 md:mt-2",children:s==="fr"?"pays":"countries"})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:200",className:"bg-white/5 backdrop-blur-md rounded-xl p-4 md:p-6 border border-white/10 hover:bg-white/10 transition-all",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:201",className:"flex items-center gap-2 md:gap-3 mb-2 md:mb-3",children:[e.jsx(pe,{"data-loc":"client/src/pages/LastMile.tsx:202",className:"w-4 md:w-5 h-4 md:h-5 text-[oklch(0.60_0.10_259)]"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:203",className:"text-xs md:text-sm text-muted-foreground",children:s==="fr"?"Attendus":"Expected"})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:207",className:"text-2xl md:text-4xl font-bold text-[oklch(0.60_0.10_259)]",children:[Q," ",e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:208",className:"text-base md:text-xl font-semibold text-muted-foreground",children:s==="fr"?"attendus":"expected"})]}),e.jsx("p",{"data-loc":"client/src/pages/LastMile.tsx:210",className:"text-xs text-muted-foreground mt-1 md:mt-2",children:s==="fr"?`sur ${P} restants`:`out of ${P} remaining`})]})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:217",className:"bg-white/5 backdrop-blur-md rounded-xl border border-white/10 p-4 md:p-6",children:[e.jsx("h3",{"data-loc":"client/src/pages/LastMile.tsx:218",className:"text-xs font-semibold mb-3 md:mb-4 uppercase tracking-wide",style:{background:"linear-gradient(90deg, #0047FF 0%, #00A3FF 50%, #4AC3FF 100%)",WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent",backgroundClip:"text",color:"transparent"},children:s==="fr"?"Seuil de certitude":"Certainty threshold"}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:221",className:"max-w-md mx-auto px-2",children:e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:222",className:"relative pt-1 pb-1",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:224",className:"relative h-2 bg-gray-700 rounded-full",children:[e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:226",className:"absolute top-0 left-0 h-full w-1/4 bg-[#002FA7] rounded-l-full"}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:227",className:"absolute top-0 left-1/4 h-full w-1/4 bg-[#0047FF]"}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:228",className:"absolute top-0 left-1/2 h-full w-1/4 bg-[#0080FF]"}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:229",className:"absolute top-0 left-3/4 h-full w-1/4 bg-[#00A3FF] rounded-r-full"}),M.map((t,a)=>{const r=a<=_,i=a===_,n=["0%","33.33%","66.66%","100%"];return e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:237",className:`absolute top-1/2 -translate-y-1/2 rounded-full border-2 border-white shadow-md transition-all duration-200 cursor-pointer ${i?"w-5 h-5 bg-white":r?"w-3 h-3 bg-white":"w-3 h-3 bg-gray-500"}`,style:{left:n[a],marginLeft:i?"-10px":"-6px"},onClick:()=>B(a),children:i&&e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:246",className:"absolute inset-0 m-auto w-2.5 h-2.5 rounded-full bg-[#002FA7]"})},t)})]}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:254",className:"flex justify-between mt-3 text-xs text-muted-foreground",children:Object.entries(b).map(([t,a])=>e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:256",children:a},t))})]})})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:264",className:"flex flex-col sm:flex-row gap-3 justify-center items-stretch sm:items-center",children:[e.jsxs("button",{"data-loc":"client/src/pages/LastMile.tsx:265",onClick:()=>{h?window.location.href="/dashboard":T(!0)},className:"w-full sm:w-auto flex items-center justify-center gap-3 bg-[#002FA7] hover:bg-[#0047FF] active:bg-[#001f7a] text-white font-semibold px-6 py-4 rounded-2xl text-sm transition-colors shadow-lg shadow-[#002FA7]/30 border border-[#0047FF]/40",children:[e.jsx(ne,{"data-loc":"client/src/pages/LastMile.tsx:275",className:"w-5 h-5 flex-shrink-0"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:276",children:s==="fr"?"Mettez à jour vos contacts projection":"Update your projection contacts"})]}),e.jsx(z,{"data-loc":"client/src/pages/LastMile.tsx:279",href:"/countries-status",className:"w-full sm:w-auto",children:e.jsxs("button",{"data-loc":"client/src/pages/LastMile.tsx:280",className:"w-full flex items-center justify-center gap-3 bg-transparent hover:bg-white/10 active:bg-white/20 text-white font-semibold px-6 py-4 rounded-2xl text-sm transition-colors border border-white/30 hover:border-white/50",children:[e.jsx(me,{"data-loc":"client/src/pages/LastMile.tsx:281",className:"w-5 h-5 flex-shrink-0"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:282",children:s==="fr"?"Voir la liste complète des pays manquants":"View complete list of missing countries"})]})})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:288",className:"space-y-4 md:space-y-0",children:[e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:290",className:"hidden md:block bg-white/5 backdrop-blur-md rounded-xl border border-white/10 overflow-hidden",children:e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:291",className:"overflow-x-auto",children:e.jsx("table",{"data-loc":"client/src/pages/LastMile.tsx:292",className:"w-full",children:e.jsxs("tbody",{"data-loc":"client/src/pages/LastMile.tsx:293",children:[e.jsx("tr",{"data-loc":"client/src/pages/LastMile.tsx:295",className:"bg-white/5 border-b border-white/10 font-bold",children:e.jsx("td",{"data-loc":"client/src/pages/LastMile.tsx:296",colSpan:6,className:"px-4 py-3 text-center text-accent",children:s==="fr"?"ð¯ Objectif : 100 pays":"ð¯ Target: 100 countries"})}),e.jsxs("tr",{"data-loc":"client/src/pages/LastMile.tsx:301",className:"border-b border-white/10 sticky top-0 bg-[#0a0e27]",children:[e.jsx("th",{"data-loc":"client/src/pages/LastMile.tsx:302",className:"px-4 py-3 text-left text-xs font-semibold text-muted-foreground",children:"#"}),e.jsx("th",{"data-loc":"client/src/pages/LastMile.tsx:303",className:"px-4 py-3 text-left text-xs font-semibold text-muted-foreground",children:"Date"}),e.jsx("th",{"data-loc":"client/src/pages/LastMile.tsx:306",className:"px-4 py-3 text-left text-xs font-semibold text-muted-foreground",children:"ð©"}),e.jsx("th",{"data-loc":"client/src/pages/LastMile.tsx:307",className:"px-4 py-3 text-left text-xs font-semibold text-muted-foreground",children:s==="fr"?"Pays":"Country"}),e.jsx("th",{"data-loc":"client/src/pages/LastMile.tsx:310",className:"px-4 py-3 text-left text-xs font-semibold text-muted-foreground",children:s==="fr"?"Ambassadeur(s)":"Ambassador(s)"}),e.jsx("th",{"data-loc":"client/src/pages/LastMile.tsx:313",className:"px-4 py-3 text-left text-xs font-semibold text-muted-foreground",children:s==="fr"?"Statut":"Status"})]}),p.length>0?p.map((t,a)=>{const r=(f?.participating||0)+a+1,i=r===100,n=a>0?p[a-1]:null,m=n&&n.bestStatus!==t.bestStatus,j=t.contacts.filter(l=>l.status===t.bestStatus&&l.projectedScreeningDate),g=j.length>0?j.reduce((l,c)=>{const d=new Date(l.projectedScreeningDate||new Date),L=new Date(c.projectedScreeningDate||new Date),S=new Date;return Math.abs(L.getTime()-S.getTime())<Math.abs(d.getTime()-S.getTime())?c:l}):null,y=g?v(g.projectedScreeningDate,g.projectedScreeningType):"";return[m&&e.jsx("tr",{"data-loc":"client/src/pages/LastMile.tsx:342",className:"h-1 bg-gradient-to-r from-[#002FA7] via-[#0047FF] to-[#00A3FF]",children:e.jsx("td",{"data-loc":"client/src/pages/LastMile.tsx:343",colSpan:6,className:"h-1 p-0"})},`category-divider-${a}`),i&&e.jsx("tr",{"data-loc":"client/src/pages/LastMile.tsx:347",className:"bg-gradient-to-r from-[#002FA7] to-[#0047FF] hover:from-[#0047FF] hover:to-[#00A3FF] transition-all",children:e.jsxs("td",{"data-loc":"client/src/pages/LastMile.tsx:348",colSpan:6,className:"px-4 py-4 text-center font-bold text-white text-lg",children:["ð¯ ",s==="fr"?"Objectif : 100 pays":"Target: 100 countries"]})},`target-line-${a}`),e.jsx(J,{"data-loc":"client/src/pages/LastMile.tsx:351",children:e.jsxs(X,{"data-loc":"client/src/pages/LastMile.tsx:352",children:[e.jsx(Y,{"data-loc":"client/src/pages/LastMile.tsx:353",asChild:!0,children:e.jsxs("tr",{"data-loc":"client/src/pages/LastMile.tsx:354",className:`border-b border-white/10 hover:bg-white/10 transition-colors cursor-help ${i?"bg-gradient-to-r from-[#002FA7]/30 to-[#0047FF]/30 border-l-4 border-l-[#0047FF]":""}`,children:[e.jsx("td",{"data-loc":"client/src/pages/LastMile.tsx:357",className:"px-4 py-3 font-semibold text-[oklch(0.60_0.10_259)]",children:r}),e.jsx("td",{"data-loc":"client/src/pages/LastMile.tsx:360",className:"px-4 py-3 text-sm text-muted-foreground",children:y}),e.jsx("td",{"data-loc":"client/src/pages/LastMile.tsx:361",className:"px-4 py-3",children:e.jsx("img",{"data-loc":"client/src/pages/LastMile.tsx:362",src:`https://flagcdn.com/w40/${t.alpha2Code.toLowerCase()}.png`,alt:t.countryName,className:"w-6 h-4 object-cover rounded"})}),e.jsx("td",{"data-loc":"client/src/pages/LastMile.tsx:368",className:"px-4 py-3 font-medium",children:(()=>{const l=F(t.countryName,s);return l.length>17?l.substring(0,17)+"...":l})()}),e.jsx("td",{"data-loc":"client/src/pages/LastMile.tsx:369",className:"px-4 py-3 text-sm",children:w(t.contacts).map(l=>`${l.user?.firstName||""} ${l.user?.lastName||""}`.trim()).filter(l=>l.length>0).filter((l,c,d)=>d.indexOf(l)===c).join(", ")}),e.jsx("td",{"data-loc":"client/src/pages/LastMile.tsx:376",className:"px-4 py-3",children:e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:377",className:`px-3 py-1 rounded-full text-xs font-semibold ${O[t.bestStatus]}`,children:b[t.bestStatus]})})]})}),e.jsx(K,{"data-loc":"client/src/pages/LastMile.tsx:383",className:"bg-[#0a0e27] border border-white/20 p-4 max-w-xs",children:e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:384",className:"space-y-3",children:[e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:385",className:"font-bold text-accent",children:F(t.countryName,s)}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:386",className:"space-y-2",children:w(t.contacts).map((l,c)=>e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:388",className:"text-xs space-y-1",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:389",className:"flex items-center gap-2",children:[e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:390",className:`w-2 h-2 rounded-full ${l.status==="sure"?"bg-[oklch(0.33_0.18_259)]":l.status==="very_probable"?"bg-[oklch(0.50_0.15_259)]":l.status==="probable"?"bg-[oklch(0.65_0.12_259)]":"bg-[oklch(0.75_0.08_259)]"}`}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:396",className:"font-semibold",children:b[l.status]})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:398",className:"text-muted-foreground",children:["ð¤ ",l.user?.firstName," ",l.user?.lastName]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:401",className:"text-muted-foreground",children:["ð ",l.city||"N/A"]}),l.projectedScreeningDate&&e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:405",className:"text-muted-foreground",children:["ð
",v(l.projectedScreeningDate,l.projectedScreeningType)]})]},c))}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:412",className:"border-t border-white/10 pt-2 text-xs text-muted-foreground",children:s==="fr"?`${195-(f?.participating||0)} pays manquants`:`${195-(f?.participating||0)} countries missing`})]})})]})},`country-${t.countryId}-${a}
6`)].filter(Boolean)}).flat():e.jsx("tr",{"data-loc":"client/src/pages/LastMile.tsx:424",children:e.jsx("td",{"data-loc":"client/src/pages/LastMile.tsx:425",colSpan:6,className:"px-4 py-8 text-center text-muted-foreground",children:s==="fr"?"Aucun pays trouvé avec les filtres sélectionnés":"No countries found with selected filters"})})]})})})}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:438",className:"md:hidden space-y-3",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:440",className:"flex items-center gap-2 justify-center py-2",children:[e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:441",className:"h-px flex-1 bg-gradient-to-r from-transparent to-[#0047FF]/50"}),e.jsxs("span",{"data-loc":"client/src/pages/LastMile.tsx:442",className:"text-sm font-semibold text-[oklch(0.60_0.10_259)] whitespace-nowrap",children:["ð¯ ",s==="fr"?"Objectif : 100 pays":"Target: 100 countries"]}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:445",className:"h-px flex-1 bg-gradient-to-l from-transparent to-[#0047FF]/50"})]}),p.length>0?p.map((t,a)=>{const r=(f?.participating||0)+a+1,i=a>0?p[a-1]:null,n=i&&i.bestStatus!==t.bestStatus,m=r===100,j=t.contacts.filter(c=>c.status===t.bestStatus&&c.projectedScreeningDate),g=j.length>0?j.reduce((c,d)=>{const L=new Date(c.projectedScreeningDate||new Date),S=new Date(d.projectedScreeningDate||new Date),R=new Date;return Math.abs(S.getTime()-R.getTime())<Math.abs(L.getTime()-R.getTime())?d:c}):null,y=g?v(g.projectedScreeningDate,g.projectedScreeningType):"",l=w(t.contacts).map(c=>`${c.user?.firstName||""} ${c.user?.lastName||""}`.trim()).filter(c=>c.length>0).filter((c,d,L)=>L.indexOf(c)===d).join(", ");return[n&&e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:478",className:"h-1 bg-gradient-to-r from-[#002FA7] via-[#0047FF] to-[#00A3FF] rounded-full"},`category-divider-${a}`),m&&e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:481",className:"bg-gradient-to-r from-[#002FA7] to-[#0047FF] rounded-xl p-4 text-center font-bold text-white text-lg",children:["ð¯ ",s==="fr"?"Objectif : 100 pays":"Target: 100 countries"]},`target-line-${a}`),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:483",className:"bg-white/5 backdrop-blur-md rounded-xl border border-white/10 p-3 hover:bg-white/10 active:bg-white/15 transition-all cursor-pointer",onClick:()=>A({country:t,rowNumber:r,formattedDate:y,ambassadorNames:l}),children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:489",className:"flex items-center gap-2 mb-2",children:[e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:490",className:"text-sm font-bold text-[oklch(0.60_0.10_259)] min-w-fit",children:r}),e.jsx("img",{"data-loc":"client/src/pages/LastMile.tsx:491",src:`https://flagcdn.com/w40/${t.alpha2Code.toLowerCase()}.png`,alt:t.countryName,className:"w-5 h-3 object-cover rounded"}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:496",className:"flex-1 font-semibold text-sm",children:(()=>{const c=F(t.countryName,s);return c.length>17?c.substring(0,17)+"...":c})()}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:497",className:"text-xs text-muted-foreground min-w-fit",children:y})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:500",className:"flex items-center justify-between gap-2",children:[e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:501",className:"text-xs text-muted-foreground flex-1 line-clamp-2",children:l}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:502",className:`px-2 py-1 rounded-full text-xs font-semibold whitespace-nowrap ${O[t.bestStatus]}`,children:b[t.bestStatus]})]})]},`mobile-${t.countryId}-${a}`)].filter(Boolean)}).flat():e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:510",className:"text-center text-muted-foreground py-8",children:s==="fr"?"Aucun pays trouvé avec les filtres sélectionnés":"No countries found with selected filters"})]})]})]}),e.jsx("footer",{"data-loc":"client/src/pages/LastMile.tsx:522",className:"border-t border-border bg-card/50 backdrop-blur-sm mt-12",children:e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:523",className:"container py-6",children:e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:524",className:"text-center text-sm text-muted-foreground",children:s==="fr"?"Rejoignez-nous dans cette dernière ligne droite vers 100 pays illuminés !":"Join us in this final push towards 100 illuminated countries!"})})})]}),e.jsx(de,{"data-loc":"client/src/pages/LastMile.tsx:534",isOpen:I,onClose:()=>T(!1),feature:"contacts"}
6),e.jsx(ue,{"data-loc":"client/src/pages/LastMile.tsx:541",open:!!x,onOpenChange:t=>!t&&A(null),children:e.jsx(be,{"data-loc":"client/src/pages/LastMile.tsx:542",side:"bottom",className:"bg-[#0a0e27] border-t border-white/20 rounded-t-2xl max-h-[80vh] overflow-y-auto",children:x&&e.jsxs(e.Fragment,{children:[e.jsx(je,{"data-loc":"client/src/pages/LastMile.tsx:545",className:"mb-4",children:e.jsxs(Le,{"data-loc":"client/src/pages/LastMile.tsx:546",className:"flex items-center gap-3 text-white",children:[e.jsx("img",{"data-loc":"client/src/pages/LastMile.tsx:547",src:`https://flagcdn.com/w40/${x.country.alpha2Code.toLowerCase()}.png`,alt:x.country.countryName,className:"w-8 h-5 object-cover rounded"}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:552",children:F(x.country.countryName,s)}),e.jsxs("span",{"data-loc":"client/src/pages/LastMile.tsx:553",className:"text-sm font-normal text-muted-foreground ml-auto",children:["#",x.rowNumber]})]})}),e.jsx("div",{"data-loc":"client/src/pages/LastMile.tsx:556",className:"space-y-4",children:w(x.country.contacts).map((t,a)=>e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:558",className:"bg-white/5 rounded-xl p-3 space-y-2",children:[e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:559",className:"flex items-center gap-2",children:[e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:560",className:`w-2.5 h-2.5 rounded-full flex-shrink-0 ${t.status==="sure"?"bg-[oklch(0.33_0.18_259)]":t.status==="very_probable"?"bg-[oklch(0.50_0.15_259)]":t.status==="probable"?"bg-[oklch(0.65_0.12_259)]":"bg-[oklch(0.75_0.08_259)]"}`}),e.jsx("span",{"data-loc":"client/src/pages/LastMile.tsx:566",className:"font-semibold text-sm text-white",children:b[t.status]})]}),e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:568",className:"text-sm text-muted-foreground",children:["ð¤ ",t.user?.firstName," ",t.user?.lastName]}),t.city&&e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:572",className:"text-sm text-muted-foreground",children:["ð ",t.city]}),t.projectedScreeningDate&&e.jsxs("div",{"data-loc":"client/src/pages/LastMile.tsx:577",className:"text-sm text-muted-foreground",children:["ð
",v(t.projectedScreeningDate,t.projectedScreeningType)]})]},a))})]})})})]})}export{We 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.