PageSourceSearch

https://scoutsland.live/assets/entries/pages_compare.EbB7JyEZ.js

js scoutsland.live collected 2026-09-24 15:06:22 UTC 76,502 bytes, 2 lines download raw bytes

1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/chunks/chunk-JiCGQFNx.js","assets/chunks/chunk-Bo93X7SF.js","assets/chunks/chunk-CHOJ5Glp.js","assets/chunks/chunk-BdElISNf.js","assets/chunks/chunk-CEAvvLL5.js","assets/chunks/chunk-BlzVP_eY.js","assets/chunks/chunk-DWRExnMd.js","assets/chunks/chunk-Cn4GVL-M.js","assets/chunks/chunk-DmcL_7MB.js","assets/chunks/chunk-CnHYs1F6.js","assets/chunks/chunk-CzbI8tLL.js","assets/chunks/chunk-C-UfU5A5.js","assets/static/nprogress-5d152ab6.BgDCIyLK.css","assets/static/src_index-b3c78705.ChNrBWWn.css","assets/chunks/chunk-BI2aRVOj.js","assets/chunks/chunk-TiwWf78u.js","assets/chunks/chunk-CGT97Nbv.js"])))=>i.map(i=>d[i]);
2!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e.SENTRY_RELEASE={id:"9e472f3e094179af382f7eda6fa5a83ac80b4f6e"};var a=(new e.Error).stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="72570156-ac36-4f9c-b731-1fa8c5254912",e._sentryDebugIdIdentifier="sentry-dbid-72570156-ac36-4f9c-b731-1fa8c5254912")}catch(r){}}();import{b4 as e,Q as a,D as r,T as t,S as s,l as n,bu as l,c as o,ch as i,c4 as c,ci as d,cj as p,ck as m,cl as g,cm as u,cn as h,B as y,aZ as x,a_ as f,a$ as b,b0 as k,b1 as v}from"../chunks/chunk-BdElISNf.js";import{r as w,f as j,j as N,c as S}from"../chunks/chunk-Bo93X7SF.js";import{u as _}from"../chunks/chunk-DerQNOfF.js";import{_ as P}from"../chunks/chunk-CEAvvLL5.js";import{C}from"../chunks/chunk-CHOJ5Glp.js";import{u as T}from"../chunks/chunk-DFKZF4-A.js";import{u as A}from"../chunks/chunk-CuyckMVM.js";import{C as I,c as E,g as L,S as $,b as M,P as F,e as z,f as R,M as D,h as U,d as B,u as K}from"../chunks/chunk-B4VkCD0l.js";import{P as O,R as W}from"../chunks/chunk-Bw5PRiA-.js";import{u as G}from"../chunks/chunk-Cn4GVL-M.js";import{j as q,P as V,X as H,S as Q,L as Y,e as Z,b8 as X,bj as J,l as ee,I as ae,d as re}from"../chunks/chunk-DmcL_7MB.js";import{P as te}from"../chunks/chunk-gnskCfkM.js";import{P as se,b as ne}from"../chunks/chunk-4M2Zh3rp.js";import{g as le}from"../chunks/chunk-BEtEkLKr.js";import{f as oe}from"../chunks/chunk-BKgRON4Z.js";import{S as ie}from"../chunks/chunk-P3vavva0.js";import{F as ce}from"../chunks/chunk-CgsEAsam.js";import{P as de}from"../chunks/chunk-BsjMLXFB.js";import{u as pe,O as me}from"../chunks/chunk-m4bVLiDW.js";import{S as ge}from"../chunks/chunk-Bia9Gjv-.js";import"../chunks/chunk-BlzVP_eY.js";import"../chunks/chunk-DWRExnMd.js";import"../chunks/chunk-CnHYs1F6.js";import"../chunks/chunk-CzbI8tLL.js";import"../chunks/chunk-C-UfU5A5.js";/* empty css                      *//* empty css                      */import"../chunks/chunk-BI2aRVOj.js";import"../chunks/chunk-BQ1IMUhO.js";import"../chunks/chunk-IdDwco0T.js";import"../chunks/chunk-CGT97Nbv.js";import"../chunks/chunk-C2OFsX1l.js";import"../chunks/chunk-Ck2PeENA.js";import"../chunks/chunk-Br98umI6.js";import"../chunks/chunk-LHHZSE2X.js";import"../chunks/chunk-DqJOdBNJ.js";import"../chunks/chunk-DK1_4-JS.js";import"../chunks/chunk-C7hKzbI1.js";import"../chunks/chunk-BI3hKMgg.js";import"../chunks/chunk-B-2dMFZf.js";import"../chunks/chunk-CHc2Nb78.js";const ue=[{key:"all",labelKey:"playerPage.comparison.presets.all",label:"All"},{key:"offense",labelKey:"playerPage.comparison.presets.offense",label:"Offense"},{key:"passing",labelKey:"playerPage.comparison.presets.passing",label:"Passing"},{key:"defense",labelKey:"playerPage.comparison.presets.defense",label:"Defense"},{key:"key_passes",labelKey:"playerPage.comparison.presets.keyPasses",label:"Key Passes"},{key:"goalkeeping",labelKey:"playerPage.comparison.presets.goalkeeping",label:"Goalkeeping"}],he={offense:["goals","expected_goals","expected_goals_on_target","assists","expected_assists","chances_created","big_chances_created","big_chances_missed","shots_on_target","shots_total","shots_off_target","shots_blocked","successful_dribbles","dribble_attempts","dispossessed","offsides","touches","appearances"],passing:["passes_accurate","passes_total","key_passes","total_crosses","accurate_crosses","long_balls","long_balls_won","through_balls_won","passes_in_final_third","assists","expected_assists","chances_created","big_chances_created"],defense:["tackles","tackles_won","interceptions","clearances","blocks","ball_recovery","duels_won","total_duels","aerials_won","aerials_total","dribbled_past","dispossessed","possession_lost","fouls_committed","fouls_drawn","yellow_cards","red_cards"],key_passes:["key_passes","assists","expected_assists","chances_created","big_chances_created","through_balls_won","passes_in_final_third","accurate_crosses","total_crosses","successful_dribbles","dribble_attempts"],goalkeeping:["saves","saves_inside_box","clean_sheets","goals_conceded","penalty_s
2aved","appearances","minutes_played"]},ye=new Set(I.flatMap(e=>e.stats.map(e=>e.statKey))),xe={goals:"Total goals scored",assists:"Goal assists",expected_goals:"Expected goals (xG)",expected_assists:"Expected assists (xA)",expected_goals_on_target:"Expected goals on target (xGOT)",chances_created:"Goal-scoring chances created",big_chances_created:"Big chances created",big_chances_missed:"Big chances missed",shots_on_target:"Shots on target",shots_total:"Total shots attempted",shots_off_target:"Shots off target",shots_blocked:"Shots blocked by defenders",passes_accurate:"Accurate passes completed",passes_total:"Total passes attempted",key_passes:"Passes leading to a shot",total_crosses:"Total crosses into the box",accurate_crosses:"Accurate crosses into the box",long_balls:"Long balls attempted",long_balls_won:"Accurate long balls",through_balls_won:"Accurate through balls",passes_in_final_third:"Passes into the final third",successful_dribbles:"Successful dribbles past an opponent",dribble_attempts:"Dribble attempts",dribbled_past:"Times dribbled past by an opponent",dispossessed:"Times dispossessed",possession_lost:"Times possession was lost",duels_won:"Ground duels won",total_duels:"Total ground duels",aerials_won:"Aerial duels won",aerials_total:"Total aerial duels",tackles:"Tackles attempted",tackles_won:"Tackles won",interceptions:"Passes or shots intercepted",clearances:"Ball clearances",blocks:"Shots or passes blocked",ball_recovery:"Balls recovered",saves:"Saves made",saves_inside_box:"Saves made inside the penalty box",clean_sheets:"Matches without conceding a goal",goals_conceded:"Goals conceded",penalty_saved:"Penalties saved",yellow_cards:"Yellow cards received",red_cards:"Red cards received",fouls_committed:"Fouls committed",fouls_drawn:"Fouls drawn",offsides:"Times caught offside",appearances:"Matches played",minutes_played:"Total minutes played",touches:"Times the ball was touched"},fe=new Set(["big_chances_missed","shots_off_target","yellow_cards","red_cards","fouls_committed","offsides","goals_conceded","dispossessed","possession_lost","dribbled_past"]),be=new Intl.PluralRules("en",{type:"ordinal"}),ke={one:"st",two:"nd",few:"rd",other:"th"};function ve(e,a=!1){return a&&e<10?e.toFixed(2):Number.isInteger(e)?String(e):e.toFixed(1)}const we=[25,50,75,100],je=()=>{const e=j.c(3),a=I.length;let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=(e,r)=>{const t=2*Math.PI*e/a-Math.PI/2;return{x:170+100*r*Math.cos(t),y:170+100*r*Math.sin(t)}},e[0]=r):r=e[0];const t=r;let s;e[1]===Symbol.for("react.memo_cache_sentinel")?(s=e=>Array.from({length:a},(a,r)=>{const s=t(r,e);return`${s.x},${s.y}`}).join(" "),e[1]=s):s=e[1];const n=s;let l;return e[2]===Symbol.for("react.memo_cache_sentinel")?(l=N.jsxs("svg",{viewBox:"0 0 340 340",className:"w-full",style:{maxWidth:260,overflow:"visible"},children:[we.map(e=>N.jsx("polygon",{points:n(e/100),fill:"none",stroke:"currentColor",className:"text-gray-400 dark:text-gray-500",strokeWidth:100===e?1:.5},e)),I.map((e,a)=>{const r=t(a,1);return N.jsx("line",{x1:170,y1:170,x2:r.x,y2:r.y,stroke:"currentColor",className:"text-gray-400 dark:text-gray-500",strokeWidth:.5},a)}),I.map((e,r)=>{const{category:s}=e,n=t(r,1.26),l=180*(2*Math.PI*r/a-Math.PI/2)/Math.PI;let o="middle";l>-80&&l<80?o="start":(l>100||l<-100)&&(o="end");const i=Math.abs(l+90)<15?-4:Math.abs(l-90)<15?8:2;return N.jsx("text",{x:n.x,y:n.y,dy:i,textAnchor:o,className:"fill-gray-500 dark:fill-gray-400 text-[11px] font-semibold",children:s},r)})]}),e[2]=l):l=e[2],l},Ne=e=>{const a=j.c(30),{hasPlayers:r,categoryRadarSeries:t,cascadeKeys:s,cascadeData:n,activeCohortName:l,poolSize:o,loading:i,onShare:c}=e,d=void 0!==i&&i,{t:p}=G(),[m,g]=w.useState("overview"),u=s.length>0,h=r&&t.length>0,y=d&&!h;let x;e:{if(!u){x="";break e}const[e,r]=R[s[0]];let t;if(a[0]!==r||a[1]!==e||a[2]!==p){let s;a[4]===Symbol.for("react.memo_cache_sentinel")?(s=/ Spotlight$| Stats$/,a[4]=s):s=a[4],t=p(e,r).replace(s,""),a[0]=r,a[1]=e,a[2]=p,a[3]=t}else t=a[3];x=t}const f=x;let b;a[5]!==n||a[6]!==s[0]||a[7]!==t||a[8]!==m?(b="spotlight"===m?n.find(e=>e.key===s[0])?.radarSeries??t:t,a[5]=n,a[6]=s[0],a[7]=t,a[8]=m,a[9]=b):b=a[9];const k=b;let v,S,_,P;return a[10]!==p?(v=p("playerPage.comparison.radarSectionTitle","Percentile Radar"),a[10]=p,a[11]=v):v=a[11],a[12]!==h||a[13]!==u||a[14]!==c||a[15]!==f||a[16]!==p||a[17]!==m?(S=(u||h&&c)&&N.jsxs("div",{className:"flex items-center gap-1.5 shrink-0",children:[u&&N.jsxs("div",{className:"flex items-center bg-gray-100 dark:bg-gray-700 rounded-full p-0.5 shrink-0",children:[N.jsx("button",{onClick:()=>g("overview"),"aria-pressed":"overview"===m,className:"px-2.5 py-1 rounded-full text-xs font-semibold transition-colors "+("overview"===m?"bg-white dark:bg-gray-900 text-primary-600 dark:text-primary-400 shadow-sm":"text-gray-500 dark:text-gray-400 hover:text-gray-600 dark:hover:text-gray-300"),children:p("playerPage.comparison.overviewRadarTitle","Overview")}),N.jsx("button",{onClick:()=>g("spotlight"),"aria-pressed":"spotlight"===m,className:"px-2.5 py-1 rounded-full text-xs font-semibold transition-colors "+("spotlight"===m?"bg-white dark:bg-gray-900 text-primary-600 dark:text-primary-400 shadow-sm":"text-gray-500 dark:text-gray-400 hover:text-gray-600 dark:hover:text-gray-300"),children:f})]}),h&&c&&N.jsx("button",{onClick:c,"aria-label":p("common.share","Share"),title:p("common.share","Share"),className:"p-1.5 rounded-full text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 transition-colors shrink-0",children:N.jsx(q,{className:"w-4 h-4"})})]}),a[12]=h,a[13]=u,a[14]=c,a[15]=f,a[16]=p,a[17]=m,a[18]=S):S=a[18],a[19]!==l||a[20]!==k||a[21]!==h||a[22]!==y||a[23]!==o||a[24]!==p?(_=y?N.jsxs("div",{className:"animate-pulse flex flex-col items-center",children:[N.jsx("div",{className:"rounded-full bg-gray-200 dark:bg-gray-700",style:{width:220,height:220}}),N.jsx("div",{className:"h-2.5 w-40 bg-gray-200 dark:bg-gray-700 rounded mt-4"})]}):h?N.jsxs(N.Fragment,{children:[o>0&&N.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mb-2",children:p("compare.rail.rankedAmongCaption","vs {{total}} {{cohort}}
2",{total:o.toLocaleString(),cohort:l})}),N.jsx("div",{className:"mx-auto",style:{maxWidth:330},children:N.jsx(O,{series:k,compact:!0})})]}):N.jsxs("div",{children:[N.jsx("div",{className:"opacity-45 dark:opacity-30 pointer-events-none select-none flex justify-center",children:N.jsx(je,{})}),N.jsx("p",{className:"text-center text-xs text-gray-600 dark:text-gray-400 mt-3 px-2",children:p("compare.rail.radarEmptyMessage","Add players to see their percentile profiles overlaid here.")})]}),a[19]=l,a[20]=k,a[21]=h,a[22]=y,a[23]=o,a[24]=p,a[25]=_):_=a[25],a[26]!==v||a[27]!==S||a[28]!==_?(P=N.jsx(N.Fragment,{children:N.jsx("div",{className:"rounded-xl border border-gray-100 dark:border-gray-700/60",children:N.jsx(W,{title:v,headerRight:S,children:_})})}),a[26]=v,a[27]=S,a[28]=_,a[29]=P):P=a[29],P};function Se(e){const a=e.trim().split(/\s+/);return a[a.length-1]??e}const _e=e=>{const r=j.c(40),{players:t,maxPlayers:s,onRemove:n,onAdd:l,excludeIds:o,pendingIds:i,className:c}=e,d=void 0===c?"":c,{t:p,i18n:m}=G(),[g,u]=w.useState(!1),[h]=w.useState(Pe),y=t.length<s,x=`sticky top-14 sm:top-16 z-30 bg-white/90 dark:bg-gray-900/90 backdrop-blur-md px-2 sm:px-4 py-2.5 sm:py-3 border-b border-gray-100 dark:border-gray-700/60 ${d}`;let f;r[0]!==t.length?(f={"--cols":t.length},r[0]=t.length,r[1]=f):f=r[1];const b=f;let k,v,S,_,P,C,T,A,I;if(r[2]!==p?(k=p("playerPage.comparison.comparing","Comparing"),r[2]=p,r[3]=k):k=r[3],r[4]===Symbol.for("react.memo_cache_sentinel")?(v=N.jsx("br",{}),r[4]=v):v=r[4],r[5]!==s||r[6]!==t.length?(S=N.jsxs("span",{className:"text-gray-700 dark:text-gray-200 text-xs sm:text-sm normal-case tracking-normal",children:[t.length,"/",s]}),r[5]=s,r[6]=t.length,r[7]=S):S=r[7],r[8]!==k||r[9]!==S?(_=N.jsxs("p",{className:"text-[11px] sm:text-xs font-bold uppercase tracking-widest text-gray-500 dark:text-gray-400 leading-tight",children:[k,v,S]}),r[8]=k,r[9]=S,r[10]=_):_=r[10],r[11]!==m||r[12]!==h||r[13]!==n||r[14]!==i||r[15]!==t||r[16]!==p){let e;r[18]!==m||r[19]!==h||r[20]!==n||r[21]!==i||r[22]!==p?(e=(e,r)=>{const t=z[r]??"#9ca3af",s=[];if(e.position){const a=se[e.position];s.push(a?ne(a,p):e.position)}e.age&&s.push(`${e.age} ${p("player.yearsShort","yrs")}`),e.height&&s.push(`${e.height} cm`),e.preferredFoot&&s.push(p(`foot.${e.preferredFoot}`,e.preferredFoot));const l=e.contractEnd?new Date(e.contractEnd):null;return l&&!Number.isNaN(l.getTime())&&l.getTime()>=h&&s.push(oe(l,"MMM yyyy",{locale:le(m.language)})),N.jsxs("div",{className:"min-w-0 flex flex-col items-center gap-1 relative pr-3 sm:pr-4",children:[n&&N.jsx("button",{onClick:()=>n(e.id),"aria-label":p("playerPage.comparison.removePlayer","Remove {{name}}",{name:e.name}),className:"absolute -top-0.5 right-0 w-4 h-4 rounded-full bg-gray-200 dark:bg-gray-700 flex items-center justify-center hover:bg-red-100 dark:hover:bg-red-900/40 hover:text-red-500 transition-colors z-10",children:N.jsx(H,{className:"w-2.5 h-2.5"})}),N.jsx("div",{className:"relative shrink-0 w-8 h-8 sm:w-10 sm:h-10",children:N.jsxs("div",{className:"w-full h-full rounded-full bg-gray-100 dark:bg-gray-700 border-2",style:{borderColor:t},children:[N.jsx(a,{imageUrl:e.photo,altText:e.name,size:"sm",borderClassName:"",badge:e.nationalityFlag?{src:e.nationalityFlag,alt:"",variant:"flag"}:null}),i.has(e.id)&&N.jsx("div",{className:"absolute inset-0 rounded-full flex items-center justify-center bg-black/25 dark:bg-black/40",children:N.jsx("div",{className:"w-3 h-3 border-2 rounded-full animate-spin",style:{borderColor:t,borderTopColor:"transparent"}})})]})}),N.jsxs("div",{className:"min-w-0 w-full text-center",children:[N.jsxs("p",{className:"text-xs sm:text-sm font-bold whitespace-nowrap overflow-hidden text-ellipsis",style:{color:t},title:e.name,children:[N.jsx("span",{className:"sm:hidden",children:Se(e.name)}),N.jsx("span",{className:"hidden sm:inline",children:e.name})]}),e.club&&N.jsxs("p",{className:"hidden min-[1151px]:flex items-center justify-center gap-1 text-xs text-gray-500 dark:text-gray-400 whitespace-nowrap overflow-hidden text-ellipsis",children:[e.clubLogo&&N.jsx("img",{src:e.clubLogo,alt:"","aria-hidden":"true",className:"w-3.5 h-3.5 object-contain shrink-0"}),N.jsx("span",{className:"truncate",children:e.club})]}),s.length>0&&N.jsx("p",{className:"hidden min-[1151px]:block text-[11px] text-gray-400 dark:text-gray-500 leading-snug",children:s.join(" · ")})]})]},e.id)},r[18]=m,r[19]=h,r[20]=n,r[21]=i,r[22]=p,r[23]=e):e=r[23],P=t.map(e),r[11]=m,r[12]=h,r[13]=n,r[14]=i,r[15]=t,r[16
2]=p,r[17]=P}else P=r[17];return r[24]!==b||r[25]!==_||r[26]!==P?(C=N.jsxs("div",{className:"grid items-center gap-1.5 sm:gap-2 flex-1 min-w-0 grid-cols-[84px_repeat(var(--cols),minmax(0,1fr))] sm:grid-cols-[132px_repeat(var(--cols),minmax(0,1fr))]",style:b,children:[_,P]}),r[24]=b,r[25]=_,r[26]=P,r[27]=C):C=r[27],r[28]!==y||r[29]!==o||r[30]!==l||r[31]!==g||r[32]!==p?(T=y&&l&&N.jsxs("div",{className:"relative shrink-0",children:[N.jsx("button",{onClick:()=>u(Ce),"aria-label":p("playerPage.comparison.addPlayer","Add player"),"aria-expanded":g,className:"w-8 h-8 min-[1151px]:w-10 min-[1151px]:h-10 rounded-full bg-primary-500 hover:bg-primary-600 flex items-center justify-center shadow-sm hover:shadow transition-colors",children:N.jsx(V,{className:"w-4 h-4 min-[1151px]:w-5 min-[1151px]:h-5 text-white"})}),g&&N.jsxs("div",{className:"absolute top-full right-0 mt-2 z-50 w-64 bg-white dark:bg-gray-900 rounded-xl shadow-lg border border-gray-200 dark:border-gray-700 p-2",children:[N.jsxs("div",{className:"flex items-center justify-between mb-1.5 px-0.5",children:[N.jsx("span",{className:"text-xs font-semibold text-gray-500 dark:text-gray-400",children:p("playerPage.comparison.addPlayer","Add player")}),N.jsx("button",{onClick:()=>u(!1),"aria-label":p("common.close","Close"),className:"w-5 h-5 rounded-full flex items-center justify-center text-gray-400 hover:bg-gray-100 dark:hover:bg-gray-800 hover:text-gray-600 dark:hover:text-gray-300 transition-colors",children:N.jsx(H,{className:"w-3 h-3"})})]}),N.jsx(te,{excludeIds:o,onSelect:(e,a,r,t,s,n,o,i)=>{l(e,a,r,t,s,n,o,i),u(!1)},placeholder:p("playerPage.comparison.searchPlaceholder","Search players…")})]})]}),r[28]=y,r[29]=o,r[30]=l,r[31]=g,r[32]=p,r[33]=T):T=r[33],r[34]!==C||r[35]!==T?(A=N.jsxs("div",{className:"flex items-center gap-3",children:[C,T]}),r[34]=C,r[35]=T,r[36]=A):A=r[36],r[37]!==A||r[38]!==x?(I=N.jsx("div",{className:x,children:A}),r[37]=A,r[38]=x,r[39]=I):I=r[39],I};function Pe(){return Date.now()}function Ce(e){return!e}const Te=e=>{const a=j.c(40),{aiCTA:t,onAIClick:s,aiHref:n,aiGenerating:l,aiUsageLabel:o,onNewAIPair:i,aiBannerPlayers:c,hasMultiplePlayers:d,totalPlayerCount:p}=e,m=void 0!==l&&l,{t:g}=G();if(!t||!d)return null;const u="upgrade"===t;let h;a[0]!==t||a[1]!==g?(h="generate"===t?g("compare.aiBannerGenerate","Get AI-powered analysis of these players"):"view"===t?g("compare.aiBannerExists","AI analysis ready for these players"):"upgrade"===t?g("compare.aiBannerUpgrade","Get FAN to unlock AI-powered analysis"):g("compare.aiBannerLimit","Daily AI limit reached"),a[0]=t,a[1]=g,a[2]=h):h=a[2];const y=h;let x;a[3]!==t||a[4]!==m||a[5]!==g?(x="generate"===t?m?"…":g("compare.generate","Generate"):"view"===t?g("compare.view","View"):"upgrade"===t?g("compare.upgrade","Get FAN"):null,a[3]=t,a[4]=m,a[5]=g,a[6]=x):x=a[6];const f=x,b=c?.[0],k=c?.[1],v=("generate"===t||"view"===t)&&b&&k,w="w-4 h-4 shrink-0 "+("limit_reached"===t?"text-gray-400 dark:text-gray-500":"text-purple-500 dark:text-purple-400");let S,_,P,C,T,A,I;a[7]!==w?(S=N.jsx(Q,{className:w}),a[7]=w,a[8]=S):S=a[8],a[9]!==y?(_=N.jsx("p",{className:"text-xs text-gray-700 dark:text-gray-300 leading-snug",children:y}),a[9]=y,a[10]=_):_=a[10],a[11]!==t||a[12]!==b||a[13]!==k||a[14]!==i||a[15]!==v||a[16]!==g||a[17]!==p?(P=v&&N.jsxs("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5 truncate",children:[b," vs ",k,"generate"===t&&p>2&&N.jsxs("span",{className:"ml-1 opacity-70",children:["· ",g("compare.aiFirstTwoOnly","first 2 players only")]}),"view"===t&&i&&N.jsxs("button",{onClick:e=>{e.stopPropagation(),e.preventDefault(),i()},className:"ml-1 text-purple-500 hover:text-purple-600 dark:text-purple-400 dark:hover:text-purple-300 underline",children:["· ",g("compare.tryAnotherPair","Try another pair")]})]}),a[11]=t,a[12]=b,a[13]=k,a[14]=i,a[15]=v,a[16]=g,a[17]=p,a[18]=P):P=a[18],a[19]!==o?(C=o&&N.jsx("p",{className:"text-xs text-purple-500 dark:text-purple-400 mt-0.5",children:o}),a[19]=o,a[20]=C):C=a[20],a[21]!==_||a[22]!==P||a[23]!==C?(T=N.jsxs("div",{className:"flex-1 min-w-0",children:[_,P,C]}),a[21]=_,a[22]=P,a[23]=C,a[24]=T):T=a[24],a[25]!==t||a[26]!==m||a[27]!==f?(A=f&&N.jsx("span",{className:`shrink-0 px-2.5 py-1 rounded-full ${r.typography.cardMeta} transition-colors ${"limit_reached"===t?"bg-gray-100 dark:bg-gray-700 text-gray-400":"bg-purple-500 text-white hover:bg-purple-600"} ${m?"opacity-60 cursor-wait":""}`,children:f}),a[25]=t,a[26]=m,a[27]=f,a[28]=A):A=a[28],a[29]!==A||a[30]!==S||a[31]!==T?(I=N.jsxs(N.Fragment,{children:[S,T,A]}),a[29]=A,a[30]=S,a[31]=T,a[32]=I):I=a[32];const E=I;let L;return a[33]!==t||a[34]!==m||a[35]!==n||a[36]!==E||a[37]!==u||a[38]!==s?(L=u?N.jsx("a",{href:n,className:"w-full flex items-center gap-3 mb-3 sm:mb-4 px-3 py-2.5 rounded-xl bg-linear-to-r from-purple-50 to-primary-50 dark:from-purple-900/20 dark:to-primary-900/20 border border-purple-200/50 dark:border-purple-800/40 transition-colors text-left hover:from-purple-100 hover:to-primary-100 dark:hover:from-purple-900/30 dark:hover:to-primary-900/30",children:E}):N.jsx("button",{onClick:s,disabled:"limit_reached"===t||m,className:"w-full flex items-center gap-3 mb-3 sm:mb-4 px-3 py-2.5 rounded-xl bg-linear-to-r from-purple-50 to-primary-50 dark:from-purple-900/20 dark:to-primary-900/20 border border-purple-200/50 dark:border-purple-800/40 transition-colors text-left "+("limit_reached"!==t?"hover:from-purple-100 hover:to-primary-100 dark:hover:from-purple-900/30 dark:hover:to-primary-900/30":"cursor-default"),children:E}),a[33]=t,a[34]=m,a[35]=n,a[36]=E,a[37]=u,a[38]=s,a[39]=L):L=a[39],L},Ae=e=>{const a=j.c(25),{aiHref:r}=e,t=void 0===r?"/pricing":r,{t:s}=G();let n,l,o,i,c,d,p,m,g,u,h,y,x;return a[0]===Symbol.for("react.memo_cache_sentinel")?(n=N.jsx("span",{className:"flex items-center justify-center w-7 h-7 rounded-lg bg-purple-500 shrink-0",children:N.jsx(Q,{className:"w-4 h-4 text-white"})}),a[0]=n):n=a[0],a[1]!==s?(l=s("compare.aiSummaryTitle","AI Comparison Summary"),a[1]=s,a[2]=l):l=a[2],a[3]!==l?(o=N.jsx("h3",{className:"text-sm sm:text-base font-semibold text-gray-900 dark:text-gray-100",children:l}),a[3]=l,a[4]=o):o=a[4],a[5]===Symbol.for("react.memo_cache_sentinel")?(i=N.jsx("span",{className:"px-2 py-0.5 rounded-full text-[10px] font-bold tracking-wide text-purple-600 dar
2k:text-purple-300 border border-purple-300 dark:border-purple-700",children:"FAN"}),a[5]=i):i=a[5],a[6]!==o?(c=N.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[n,o,i]}),a[6]=o,a[7]=c):c=a[7],a[8]===Symbol.for("react.memo_cache_sentinel")?(d=N.jsxs("div",{"aria-hidden":"true",className:"space-y-1.5 mb-4 select-none pointer-events-none blur-[5px]",children:[N.jsx("div",{className:"h-3 w-full bg-gray-300 dark:bg-gray-600 rounded"}),N.jsx("div",{className:"h-3 w-11/12 bg-gray-300 dark:bg-gray-600 rounded"}),N.jsx("div",{className:"h-3 w-4/5 bg-gray-300 dark:bg-gray-600 rounded"}),N.jsx("div",{className:"h-3 w-2/3 bg-gray-300 dark:bg-gray-600 rounded mt-2"})]}),a[8]=d):d=a[8],a[9]===Symbol.for("react.memo_cache_sentinel")?(p=N.jsx(Y,{className:"w-4 h-4 text-purple-500 shrink-0 mt-0.5"}),a[9]=p):p=a[9],a[10]!==s?(m=s("compare.aiLockedSub","A short scouting read of the whole comparison, grounded in these percentiles."),a[10]=s,a[11]=m):m=a[11],a[12]!==m?(g=N.jsxs("div",{className:"flex items-start gap-2 min-w-0",children:[p,N.jsx("p",{className:"text-xs sm:text-sm text-gray-600 dark:text-gray-400",children:m})]}),a[12]=m,a[13]=g):g=a[13],a[14]!==s?(u=s("compare.unlockWithFan","Unlock with FAN"),a[14]=s,a[15]=u):u=a[15],a[16]!==t||a[17]!==u?(h=N.jsx("a",{href:t,className:"shrink-0 px-3 py-2 rounded-lg text-sm font-semibold text-white bg-purple-500 hover:bg-purple-600 transition-colors whitespace-nowrap",children:u}),a[16]=t,a[17]=u,a[18]=h):h=a[18],a[19]!==g||a[20]!==h?(y=N.jsxs("div",{className:"flex items-center justify-between gap-3 pt-3 border-t border-purple-200/50 dark:border-purple-800/40",children:[g,h]}),a[19]=g,a[20]=h,a[21]=y):y=a[21],a[22]!==y||a[23]!==c?(x=N.jsxs(C,{className:"p-3 sm:p-4 border-purple-200/50 dark:border-purple-800/40 bg-linear-to-br from-purple-50/60 to-primary-50/60 dark:from-purple-900/10 dark:to-primary-900/10 mb-3 sm:mb-4",children:[c,d,y]}),a[22]=y,a[23]=c,a[24]=x):x=a[24],x},Ie=e=>{const a=j.c(64),{activePreset:n,onSelectPreset:l,showStatPicker:o,setShowStatPicker:i,statSearch:c,setStatSearch:d,selectedStatKeys:p,toggleStat:m,valueMode:g,onValueModeChange:u}=e,{t:h}=G();let y;a[0]!==i?(y=()=>i(Ee),a[0]=i,a[1]=y):y=a[1];const x="shrink-0 p-1.5 rounded-lg mr-2 transition-colors "+(o?"bg-primary-100 dark:bg-primary-900/40 text-primary-600 dark:text-primary-400":"text-gray-500 dark:text-gray-400 hover:text-gray-600 dark:hover:text-gray-300");let f,b,k,v,w;a[2]!==h?(f=h("playerPage.comparison.filterStats","Filter stats"),a[2]=h,a[3]=f):f=a[3],a[4]===Symbol.for("react.memo_cache_sentinel")?(b=N.jsx(X,{className:"w-3.5 h-3.5"}),a[4]=b):b=a[4],a[5]!==o||a[6]!==y||a[7]!==x||a[8]!==f?(k=N.jsx("button",{onClick:y,"aria-expanded":o,"aria-controls":"stat-picker-panel",className:x,"aria-label":f,children:b}),a[5]=o,a[6]=y,a[7]=x,a[8]=f,a[9]=k):k=a[9],a[10]===Symbol.for("react.memo_cache_sentinel")?(v=N.jsx("div",{className:"w-px h-4 bg-gray-200 dark:bg-gray-600 shrink-0 mr-2"}),a[10]=v):v=a[10],a[11]!==n||a[12]!==l||a[13]!==h?(w=ue.map(e=>{const{key:a,label:r,labelKey:t}=e;return N.jsx(ce,{size:"xs-responsive",selected:n===a,onClick:()=>l(a),children:h(t,r)},a)}),a[11]=n,a[12]=l,a[13]=h,a[14]=w):w=a[14];const S="custom"===n;let _,P,C,T,A,E;a[15]!==n||a[16]!==i?(_=()=>{"custom"!==n&&i(!0)},a[15]=n,a[16]=i,a[17]=_):_=a[17],a[18]!==h?(P=h("playerPage.comparison.presets.custom","Custom"),a[18]=h,a[19]=P):P=a[19],a[20]!==P||a[21]!==S||a[22]!==_?(C=N.jsx(ce,{size:"xs-responsive",selected:S,onClick:_,children:P}),a[20]=P,a[21]=S,a[22]=_,a[23]=C):C=a[23],a[24]!==C||a[25]!==w?(T=N.jsx(s,{className:"flex-1",orientation:"horizontal",children:N.jsxs("div",{className:"flex gap-1.5 pb-1",children:[w,C]})}),a[24]=C,a[25]=w,a[26]=T):T=a[26],a[27]!==T||a[28]!==k?(A=N.jsxs("div",{className:"flex items-center gap-0",children:[k,v,T]}),a[27]=T,a[28]=k,a[29]=A):A=a[29],a[30]!==u?(E=()=>u?.(t.PER_90),a[30]=u,a[31]=E):E=a[31];const L=g===t.PER_90,$="px-3 py-1 rounded-full text-xs font-semibold transition-colors "+(g===t.PER_90?"bg-white dark:bg-gray-900 text-primary-600 dark:text-primary-400 shadow-sm":"text-gray-500 dark:text-gray-400 hover:text-gray-600 dark:hover:text-gray-300");let M,F,z;a[32]!==h?(M=h("compare.valueMode.per90","P90"),a[32]=h,a[33]=M):M=a[33],a[34]!==E||a[35]!==L||a[36]!==$||a[37]!==M?(F=N.jsx("button",{onClick:E,"aria-pressed":L,className:$,children:M}),a[34]=E,a[35]=L,a[36]=$,a[37]=M,a[38]=F):F=a[38],a[39]!==u?(z=()=>u?.(t.TOTAL),a[39]=u,a[40]=z):z=a[40];const R=g===t.TOTAL,D="px-3 py-1 rounded-full text-xs font-semibold transition-colors "+(g===t.TOTAL?"bg-white dark:bg-gray-900 text-primary-600 dark:text-primary-400 shadow-sm":"text-gray-500 dark:text-gray-400 hover:text-gray-600 dark:hover:text-gray-300");let U,B,K,O,W,q;
2return a[41]!==h?(U=h("compare.valueMode.total","Total"),a[41]=h,a[42]=U):U=a[42],a[43]!==z||a[44]!==R||a[45]!==D||a[46]!==U?(B=N.jsx("button",{onClick:z,"aria-pressed":R,className:D,children:U}),a[43]=z,a[44]=R,a[45]=D,a[46]=U,a[47]=B):B=a[47],a[48]!==F||a[49]!==B?(K=N.jsx("div",{className:"flex items-center justify-end",children:N.jsxs("div",{className:"flex items-center bg-gray-100 dark:bg-gray-700 rounded-full p-0.5",children:[F,B]})}),a[48]=F,a[49]=B,a[50]=K):K=a[50],a[51]!==A||a[52]!==K?(O=N.jsxs("div",{className:"flex flex-col gap-2",children:[A,K]}),a[51]=A,a[52]=K,a[53]=O):O=a[53],a[54]!==p||a[55]!==d||a[56]!==o||a[57]!==c||a[58]!==h||a[59]!==m?(W=o&&N.jsxs("div",{id:"stat-picker-panel",className:"border border-gray-200 dark:border-gray-700 rounded-xl p-3 mt-2.5 bg-gray-50 dark:bg-gray-800/60",children:[N.jsx("div",{className:"mb-3",children:N.jsx(ie,{value:c,onChange:d,placeholder:h("playerPage.comparison.searchStats","Search stats…")})}),N.jsxs(s,{className:"max-h-[45vh] sm:max-h-none",orientation:"vertical",children:[N.jsx("div",{className:"space-y-3",children:I.map(e=>{const{category:a,categoryKey:t,stats:s}=e,n=c.toLowerCase(),l=s.filter(e=>{const{statKey:a,label:r}=e;return!n||a.toLowerCase().includes(n)||r.toLowerCase().includes(n)||h(`leaderboard.stats.${a}`,r).toLowerCase().includes(n)});return 0===l.length?null:N.jsxs("div",{children:[N.jsx("p",{className:"text-xs font-black uppercase tracking-widest text-primary-400 dark:text-primary-500 mb-1.5",children:a}),N.jsx("div",{className:"flex flex-wrap gap-1.5",children:l.map(e=>{const{statKey:a,label:t}=e,s=p.has(a);return N.jsxs("button",{onClick:()=>m(a),role:"checkbox","aria-checked":s,className:`inline-flex items-center gap-1 px-2 py-1 min-h-7.5 rounded-md ${r.typography.cardMeta} transition-colors border ${s?"bg-primary-50 dark:bg-primary-900/30 border-primary-400 dark:border-primary-600 text-primary-700 dark:text-primary-300":"bg-white dark:bg-gray-700 border-gray-200 dark:border-gray-600 text-gray-500 dark:text-gray-400 hover:border-gray-400 dark:hover:border-gray-400"}`,children:[N.jsx("span",{className:"w-3 h-3 rounded-sm border flex items-center justify-center shrink-0 transition-colors "+(s?"bg-primary-500 border-primary-500":"border-gray-300 dark:border-gray-500"),children:s&&N.jsx(Z,{className:"w-2 h-2 text-white",strokeWidth:3})}),h(`leaderboard.stats.${a}`,t)]},a)})})]},t)})}),N.jsxs("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-2.5",children:[p.size," / ",ye.size," ",h("playerPage.comparison.statsSelected","stats selected")]})]})]}),a[54]=p,a[55]=d,a[56]=o,a[57]=c,a[58]=h,a[59]=m,a[60]=W):W=a[60],a[61]!==O||a[62]!==W?(q=N.jsxs("div",{className:"mb-3 sm:mb-4",children:[O,W]}),a[61]=O,a[62]=W,a[63]=q):q=a[63],q};function Ee(e){return!e}const Le=e=>{const a=j.c(33),{category:r,stats:s,displayPlayers:n,seriesByPlayerId:l,pendingIds:o,loading:i,valueMode:c}=e,{t:d,i18n:p}=G();let m;a[0]!==n.length?(m={"--cols":n.length},a[0]=n.length,a[1]=m):m=a[1];const g=m;let u,h,y,x,f,b;if(a[2]!==r?(u=N.jsx("p",{className:"text-[11px] font-black uppercase tracking-widest text-primary-400 dark:text-primary-500",children:r}),a[2]=r,a[3]=u):u=a[3],a[4]!==s.length?(h=N.jsx("span",{className:"text-[10px] text-gray-500 dark:text-gray-400",children:s.length}),a[4]=s.length,a[5]=h):h=a[5],a[6]!==u||a[7]!==h?(y=N.jsxs("div",{className:"px-2 sm:px-4 py-2 bg-gray-50/70 dark:bg-gray-800/50 border-b border-gray-100 dark:border-gray-700/60 flex items-center gap-2",children:[u,h]}),a[6]=u,a[7]=h,a[8]=y):y=a[8],a[9]!==n||a[10]!==g||a[11]!==p||a[12]!==i||a[13]!==o||a[14]!==l||a[15]!==s||a[16]!==d||a[17]!==c){let e;a[19]!==n||a[20]!==g||a[21]!==p||a[22]!==i||a[23]!==o||a[24]!==l||a[25]!==d||a[26]!==c?(e=(e,a)=>{const{statKey:r,label:s}=e,m=r.toUpperCase(),u=n.map(e=>l.get(e.id)?.rankings.find(e=>e.statName===m)?.percentile??0),h=Math.max(0,...u);return N.jsxs("div",{className:"grid items-center gap-1.5 sm:gap-2 px-2 sm:px-4 grid-cols-[84px_repeat(var(--cols),minmax(0,1fr))] sm:grid-cols-[132px_repeat(var(--cols),minmax(0,1fr))]",style:{...g,paddingTop:6,paddingBottom:6,backgroundColor:a%2==1?"rgba(255,255,255,0.015)":void 0},children:[N.jsxs("div",{className:"min-w-0",children:[N.jsx("p",{className:"text-[11px] sm:text-xs font-bold uppercase tracking-wide text-gray-500 dark:text-gray-400 leading-tight cursor-default",title:xe[r],children:d(`leaderboard.stats.${r}`,s)}),fe.has(r)&&N.jsxs("p",{className:"text-[9px] sm:text-[10px] font-bold text-red-500 dark:text-red-400 mt-0.5 leading-none",children:["▼ ",d("compare.lowerIsBetter","lower is better")]})]}),n.map(e=>{const a=l.get(e.id);if(!a||o.has(e.id)||i)return N.jsxs("div",{className:"flex flex-col gap-1 px-1",children:[N.jsx("div",{className:"h-3.5 w-8 rounded bg-gray-200 dark:bg-gray-700 animate-pulse"}),N.jsx("div",{className:"w-full h-1.25 rounded-full bg-gray-200 dark:bg-gray-700 animate-pulse"})]},e.id);const n=a.rankings.find(e=>e.statName===m),g=n?.value??0,u=void 0!==n,y=c===t.PER_90,x=u?n?.percentile??0:0,f=u&&x>
20&&x===h,b=u?`${e.name}: ${ve(g,y)} ${d(`leaderboard.stats.${r}`,s)}, ${Math.round(x)}th percentile${f?` (${d("playerPage.comparison.leading","leading")})`:""}`:`${e.name}: ${d("playerPage.comparison.noData","no data")}`;return N.jsxs("div",{"aria-label":b,className:"min-w-0 flex flex-col gap-1 px-0.5 sm:px-1",children:[N.jsxs("div",{className:"flex items-baseline gap-1 min-w-0",children:[N.jsx("span",{className:"text-xs sm:text-sm font-mono font-bold tabular-nums leading-tight truncate",style:{color:f?e.color:void 0},"aria-hidden":"true",children:u?ve(g,y):N.jsx("span",{className:"text-gray-400 dark:text-gray-500",children:"—"})}),u&&N.jsx("span",{className:"text-[9px] font-mono text-gray-500 dark:text-gray-400 shrink-0","aria-hidden":"true",children:(k=Math.round(x),v=p.language?.split("-")[0]??"en","en"===v?`${k}${ke[be.select(k)]??"th"}`:`${k}%`)})]}),N.jsx("div",{role:"progressbar","aria-valuenow":Math.round(x),"aria-valuemin":0,"aria-valuemax":100,"aria-label":`${e.name} ${Math.round(x)}th percentile`,className:"w-full h-1.25 rounded-full bg-gray-100 dark:bg-gray-700/60 overflow-hidden",children:u&&N.jsx("div",{className:"h-full rounded-full transition-all duration-500",style:{width:`${Math.round(x)}%`,backgroundColor:e.color,opacity:f?1:.45}})}),f&&N.jsx("span",{className:"sr-only",children:d("playerPage.comparison.leading","leading")})]},e.id);var k,v})]},r)},a[19]=n,a[20]=g,a[21]=p,a[22]=i,a[23]=o,a[24]=l,a[25]=d,a[26]=c,a[27]=e):e=a[27],x=s.map(e),a[9]=n,a[10]=g,a[11]=p,a[12]=i,a[13]=o,a[14]=l,a[15]=s,a[16]=d,a[17]=c,a[18]=x}else x=a[18];return a[28]!==x?(f=N.jsx("div",{children:x}),a[28]=x,a[29]=f):f=a[29],a[30]!==y||a[31]!==f?(b=N.jsxs("div",{className:"rounded-xl border border-gray-100 dark:border-gray-700/60 overflow-hidden",children:[y,f]}),a[30]=y,a[31]=f,a[32]=b):b=a[32],b},$e=e=>{const a=j.c(16),{player:r,onClear:t}=e,{t:s}=G();let n,l,o,i,c,d;return a[0]!==r.nationalityFlag?(n=r.nationalityFlag?{src:r.nationalityFlag,variant:"flag"}:null,a[0]=r.nationalityFlag,a[1]=n):n=a[1],a[2]!==r.name||a[3]!==r.photo||a[4]!==n?(l=N.jsx(de,{imageUrl:r.photo,name:r.name,size:"sm",badge:n}),a[2]=r.name,a[3]=r.photo,a[4]=n,a[5]=l):l=a[5],a[6]!==r.name||a[7]!==s?(o=s("playerPage.comparison.removePlayer","Remove {{name}}",{name:r.name}),a[6]=r.name,a[7]=s,a[8]=o):o=a[8],a[9]===Symbol.for("react.memo_cache_sentinel")?(i=N.jsx(H,{className:"w-2.5 h-2.5"}),a[9]=i):i=a[9],a[10]!==t||a[11]!==o?(c=N.jsx("button",{onClick:t,"aria-label":o,className:"shrink-0 w-4 h-4 rounded-full bg-gray-200 dark:bg-gray-700 flex items-center justify-center hover:bg-red-100 dark:hover:bg-red-900/40 hover:text-red-500 transition-colors",children:i}),a[10]=t,a[11]=o,a[12]=c):c=a[12],a[13]!==l||a[14]!==c?(d=N.jsxs("div",{className:"flex items-center gap-2 pl-1.5 pr-3 py-1.5 rounded-full bg-gray-100 dark:bg-gray-800 max-w-56",children:[l,c]}),a[13]=l,a[14]=c,a[15]=d):d=a[15],d},Me=e=>{const a=j.c(22),{onAdd:r}=e,{t:t}=G(),[s,n]=w.useState(!1),[l,o]=w.useState(null);let i;a[0]===Symbol.for("react.memo_cache_sentinel")?(i=(e,a,r,t,s,n,l,i)=>{o({id:e,name:a,photo:r,slug:t,position:s,club:n,clubLogo:l,nationalityFlag:i})},a[0]=i):i=a[0];const c=i;let d;a[1]!==l||a[2]!==r?(d=(e,a,t,s,i,c,d,p)=>{l&&(r(l.id,l.name,l.photo,l.slug,l.position,l.club,l.clubLogo,l.nationalityFlag),r(e,a,t,s,i,c,d,p),o(null),n(!1))},a[1]=l,a[2]=r,a[3]=d):d=a[3];const p=d;let m,g,u,h,y,x;return a[4]!==l||a[5]!==t?(m=l?t("compare.emptyState.pickSecondTitle","Who do you want to compare them with?"):t("playerPage.comparison.emptyTitle","Compare any players head-to-head"),a[4]=l,a[5]=t,a[6]=m):m=a[6],a[7]!==m?(g=N.jsx("h2",{className:"text-lg sm:text-xl font-bold text-gray-900 dark:text-gray-100",children:m}),a[7]=m,a[8]=g):g=a[8],a[9]!==t?(u=t("compare.emptyState.sub","Add up to four players to see global percentile stats side by side."),a[9]=t,a[10]=u):u=a[10],a[11]!==u?(h=N.jsx("p",{className:"text-sm text-gray-500 dark:text-gray-400 mt-2 max-w-md mx-auto",children:u}),a[11]=u,a[12]=h):h=a[12],a[13]!==l||a[14]!==p||a[15]!==s||a[16]!==t?(y=l?N.jsxs("div",{className:"flex items-center justify-center gap-3 mt-5",children:[N.jsx($e,{player:l,onClear:()=>o(null)}),N.jsx("span",{className:"text-xs font-bold text-gray-400 dark:text-gray-500 shrink-0",children:t("compare.vs","VS")}),N.jsx("div",{className:"w-52 text-left",children:N.jsx(te,{excludeIds:[l.id],onSelect:p,placeholder:t("playerPage.comparison.searchPlaceholder","Search players…")})})]}):s?N.jsx("div",{className:"max-w-xs mx-auto mt-5 text-left",children:N.jsx(te,{excludeIds:[],onSelect:c,placeholder:t("playerPage.comparison.searchPlaceholder","Search players…")})}):N.jsxs("button",{onClick:()=>n(!0),className:"inline-flex items-center gap-1.5 mt-5 px-4 py-2 rounded-full bg-primary-500 text-white text-sm font-semibold hover:bg-primary-600 transition-colors",children:[N.jsx(V,{className:"w-4 h-4"}),t("compare.emptyState.startCompare","Add players to compare")]}),a[13]=l,a[14]=p,a[15]=s,a[16]=t,a[17]=y):y=a[17],a[18]!==g||a[19]!==h||a[20]!==y?(x=N.jsxs("div",{className:"rounded-xl border-2 border-dashed border-gray-200 dark:border-gray-700 px-6 py-10 sm:py-14 text-center",children:[g,h,y]}),a[18]=g,a[19]=h,a[20]=y,a[21]=x):x=a[21],x},Fe=e=>{const a=j.c(10),{player:r}=e;let t,s,n;return a[0]!==r.nationalityFlag?(t=r.nationalityFlag?{src:r.nationalityFlag,variant:"flag"}:null,a[0]=r.nationalityFlag,a[1]=t):t=a[1],a[2]!==r.club||a[3]!==r.clubLogo?(s=r.club&&N.jsxs("span",{className:"flex items-center gap-1 text-[11px] truncate",children:[r.clubLogo&&N.jsx("img",{src:r.clubLogo,alt:"","aria-hidden":"true",className:"w-3 h-3 object-contain shrink-0"}),N.jsx("span",{className:"truncate",children:r.club})]}),a[2]=r.club,a[3]=r.clubLogo,a[4]=s):s=a[4],a[5]!==r.name||a[6]!==r.photo||a[7]!==t||a[8]!==s?(n=N.jsx("div",{className:"min-w-0 flex-1 flex items-center gap-2",children:N.jsx(de,{imageUrl:r.photo,name:r.name,size:"sm",badge:t,secondary:s})}),a[5]=r.name,a[6]=r.photo,a[7]=t,a[8]=s,a[9]=n):n=a[9],n},ze=e=>{const a=j.c(15),{icon:r,title:t,pairs:s,onSelect:n}=e;let l,o,i,c,d;if(a[0]!==r?(l=r&&N.jsx(r,{className:"w-3.5 h-3.5"}),a[0]=r,a[1]=l):l=a[1],a[2]!==l||a[3]!==t?(o=N.jsxs("p",{className:"text-xs font-semibold text-gray-600 dark:text-gray-400 mb-2 flex items-center gap-1.5",children:[l,t]}),a[2]=l,a[3]=t,a[4]=o):o=a[4],a[5]!==n||a[6]!==s){let e;a[8]!==n?(e=e=>N.jsxs("button",{onClick:()=>n(e),className:"w-full flex items-center gap-2 px-2 py-2 rounded-lg text-left hover:bg-gray-100 dark:hover:bg-gray-700/40 transition-colors",children:[N.jsx(Fe,{player:e[0]}),N.jsx("span",{className:"text-[10px] font-bold text-gray-400 dark:text-gray-500 shrink-0",children:"VS"}),N.jsx(Fe,{player:e[1]})]},`${e[0].id}-${e[1].id}`),a[8]=n,a[9]=e):e=a[9],i=s.map(e),a[5]=n,a[6]=s,a[7]=i}else i=a[7];return a[10]!==i?(c=N.jsx("div",{className:"space-y-1.5",children:i}),a[10]=i,a[11]=c):c=a[11],a[12]!==o||a[13]!==c?(d=N.jsxs("div",{className:"rounded-xl border border-gray-100 dark:border-gray-700/60 p-3",children:[o,c]}),a[12]=o,a[13]=c,a[14]=d):d=a[14],d},Re=()=>{const e=j.c(2);let a,r;return e[0]===Symbol.for("react.memo_cache_sentinel")?(a=N.jsx("div",{className:"shrink-0 w-8 h-8 rounded-full bg-gray-200 dark:bg-gray-700 animate-pulse"}),e[0]=a):a=e[0],e[1]===Symbol.for("react.memo_cache_sentinel")?(r=N.jsxs("div",{className:"min-w-0 flex-1 flex items-center gap-2",children:[a,N.jsxs("div",{className:"min-w-0 flex-1 space-y-1.5",children:[N.jsx("div",{className:"h-3 w-16 rounded bg-gray-200 dark:bg-gray-700 animate-pulse"}),N.jsx("div",{className:"h-2.5 w-12 rounded bg-gray-200 dark:bg-gray-700 animate-pulse"})]})]}),e[1]=r):r=e[1],r},De=e=>{const a=j.c(10),{icon:r,title:t,rows:s}=e,n=void 0===s?3:s;let l,o,i,c;return a[0]!==r?(l=r&&N.jsx(r,{className:"w-3.5 h-3.5"}),a[0]=r,a[1]=l):l=a[1],a[2]!==l||a[3]!==t?(o=N.jsxs("p",{className:"text-xs font-semibold text-gray-600 dark:text-gray-400 mb-2 flex items-center gap-1.5",children:[l,t]}),a[2]=l,a[3]=t,a[4]=o):o=a[4],a[5]!==n?(i=N.jsx("div",{className:"space-y-1.5",children:Array.from({length:n},Ue)}),a[5]=n,a[6]=i):i=a[6],a[7]!==o||a[8]!==i?(c=N.jsxs("div",{className:"rounded-xl border border-gray-100 dark:border-gray-700/60 p-3",children:[o,i]}),a[7]=o,a[8]=i,a[9]=c):c=a[9],c};function Ue(e,a){return N.jsxs("div",{className:"w-full flex items-center gap-2 px-2 py-2",children:[N.jsx(Re,{}),N.jsx("span",{className:"text-[10px] font-bold text-gray-300 dark:text-gray-600 shrink-0",children:"VS"}),N.jsx(Re,{})]},a)}const Be=e=>{const a=j.c(6),{pairs:r,onSelect:t}=e,{t:s}=G();let n,l;return a[0]!==s?(n=s("compare.popularComparisons","Popular comparisons"),a[0]=s,a[1]=n):n=a[1],a[2]!==t||a[3]!==r||a[4]!==n?(l=N.jsx(ze,{title:n,pairs:r,onSelect:t}),a[2]=t,a[3]=r,a[4]=n,a[5]=l):l=a[5],l},Ke=()=>{const e=j.c(4),{t:a}=G();let r,t;return e[0]!==a?(r=a("compare.popularComparisons","Popular comparisons"),e[0]=a,e[1]=r):r=e[1],e[2]!==r?(t=N.jsx(De,{title:r,rows:3}),e[2]=r,e[3]=t):t=e[3],t},Oe=e=>{const a=j.c(6),{pairs:r,onSelect:t}=e,{t:s}=G();let n,l;return a[0]!==s?(n=s("compare.recentComparisons","Recent Comparisons"),a[0]=s,a[1]=n):n=a[1],a[2]!==t||a[3]!==r||a[4]!==n?(l=N.jsx(ze,{icon:J,title:n,pairs:r,onSelect:t}),a[2]=t,a[3]=r,a[4]=n,a[5]=l):l=a[5],l},We=()=>{const e=j.c(4),{t:a}=G();let r,t;return e[0]!==a?(r=a("compare.recentComparisons","Recent Comparisons"),e[0]=a,e[1]=r):r=e[1],e[2]!==r?(t=N.jsx(De,{icon:J,title:r,rows:2}),e[2]=r,e[3]=t):t=e[3],t},Ge=S.lazy(()=>P(()=>import("../chunks/chunk-JiCGQFNx.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16]))),qe={limit:5},Ve=[["lamine-yamal","lionel-messi"],["rodri-2","alexis-mac-allister"],["cristian-romero","pau-cubarsi"]];function He(e){return{id:e.id,name:e.displayName||e.fullName||`${e.firstName} ${e.lastName}`,photo:e.media?.profilePicUrl||e.media?.imageUrl||void 0,position:e.positions?.main?.[0]?.name||void 0,club:e.clubs?.current?.name||void 0,clubLogo:e.clubs?.current?.logo||void 0,nationality:e.nationality?.name||void 0,nationalityCode:e.nationality?.code||void 0,nationalityFlag:e.nationality?.flag||void 0,slug:e.slug||void 0,age:e.age??void 0,height:e.height??void 0,preferredFoot:e.preferredFoot??void 0,contractEnd:e.contract?.expiryDate??void 0}}const Qe=e=>{const a=j.c(7),{generating:r}=e,t=void 0!==r&&r,{t:s}=G();let n,l,o,i;return a[0]!==t||a[1]!==s?(n=t&&N.jsxs(C,{className:"p-4 sm:p-6 bg-gradient-to-br from-primary-50 to-purple-50 dark:from-primary-900/20 dark:to-purple-900/20",children:[N.jsxs("div",{className:"flex items-center gap-3 mb-3",children:[N.jsx(Q,{className:"w-5 h-5 text-primary-600 dark:text-primary-400 animate-pulse"}),N.jsx("span",{className:"text-sm font-medium text-gray-900 dark:text-gray-100",children:s("compare.analyzingWithAI")})]}),N.jsx("div",{className:"h-2 bg-gray-200 dark:bg-gray-700 rounded-full overflow-hidden",children:N.jsx("div",{className:"h-full bg-gradient-to-r from-primary-500 to-purple-500 rounded-full animate-pulse",style:{width:"60%"}})}),N.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-2",children:s("compare.analyzingWithAISub","This usually takes a few seconds")})]}),a[0]=t,a[1]=s,a[2]=n):n=a[2],a[3]===Symbol.for("react.memo_cache_sentinel")?(l=N.jsx("div",{className:"h-6 w-48 bg-gray-200 dark:bg-gray-700 rounded mb-4"}),a[3]=l):l=a[3],a[4]===Symbol.for("react.memo_cache_sentinel")?(o=N.jsx("div",{className:"space-y-6 animate-pulse",children:N.jsxs(C,{className:"p-4 sm:p-6",children:[l,N.jsx("div",{className:"space-y-4",children:[1,2,3].map(Je)})]})}),a[4]=o):o=a[4],a[5]!==n?(i=N.jsxs("div",{className:"space-y-6",children:[n,o]}),a[5]=n,a[6]=i):i=a[6],i},Ye=()=>{const e=j.c(4);let a,r,t,s;return e[0]===Symbol.for("react.memo_cache_sentinel")?(a=N.jsx("div",{className:"flex items-center gap-4 mb-4",children:[0,1].map(ea)}
2),r=N.jsx("div",{className:"h-20 bg-gray-200 dark:bg-gray-700 rounded-xl mb-3 sm:mb-4"}),e[0]=a,e[1]=r):(a=e[0],r=e[1]),e[2]===Symbol.for("react.memo_cache_sentinel")?(t=N.jsx("div",{className:"flex gap-1.5 mb-3",children:[0,1,2,3,4].map(aa)}),e[2]=t):t=e[2],e[3]===Symbol.for("react.memo_cache_sentinel")?(s=N.jsxs("div",{className:"animate-pulse",children:[a,r,t,N.jsx("div",{className:"space-y-3",children:[0,1,2].map(ta)})]}),e[3]=s):s=e[3],s},Ze=({ssrPlayer1:r,ssrPlayer2:s,ssrPlayer3:x,ssrPlayer4:f})=>{const{t:b,i18n:k}=G(),[v]=l(),j=!!(r||s||x||f),_=v.get("p1"),P=v.get("p2"),R=v.get("p3"),O=v.get("p4"),W=w.useRef({p1:_,p2:P,p3:R,p4:O}),q=w.useRef(!1),V=w.useRef(0),Y=w.useRef(!1),[X,J]=w.useState(()=>[r,s,x,f].filter(e=>!!e)),[te,se]=w.useState([]),[ne,le]=w.useState(!0),oe=w.useCallback((e,a,r,t,s,n,l,o)=>{J(i=>i.length>=D||i.some(a=>a.id===e)?i:[...i,{id:e,name:a,photo:r,slug:t,position:s,club:n,clubLogo:l,nationalityFlag:o}])},[]),ie=w.useCallback(e=>{J(a=>a.filter(a=>a.id!==e))},[]),[ce,de]=w.useState(!1),[ue,xe]=w.useState([]),fe=w.useCallback(e=>{xe(a=>a.includes(e)?a.filter(a=>a!==e):a.length>=2?a:[...a,e])},[]),[be,ke]=w.useState(()=>!j&&!!(_||P||R||O)),[ve,we]=w.useState(!1),[je,Se]=w.useState(!1),[Pe,Ce]=w.useState(!1),[Ee,$e]=w.useState({isTranslated:!1,isLoading:!1}),Fe=w.useRef(null),ze=w.useRef(null),Re=w.useRef(null),De=w.useRef(null),[Ue,Ze]=w.useState(null);w.useEffect(()=>{if(!Ue)return;const e=new Set(X.map(e=>e.id));e.has(Ue[0])&&e.has(Ue[1])||Ze(null)},[X,Ue]);const Xe=Ue?X.find(e=>e.id===Ue[0])??X[0]??null:X[0]??null,Je=Ue?X.find(e=>e.id===Ue[1])??X[1]??null:X[1]??null,ea=X.length>=2,aa=w.useMemo(()=>X.map(e=>({id:e.id,name:e.name,photo:e.photo,position:e.position})),[X]),ra=w.useMemo(()=>aa.map(e=>e.id),[aa]),{isModalOpen:ta,openShareModal:sa,closeShareModal:na,format:la,setFormat:oa,cardLanguage:ia,setCardLanguage:ca,imageUrl:da,handleDownload:pa,isDownloading:ma,previewBlobUrl:ga,isFetchingPreview:ua,fetchImageBlob:ha}=pe({type:"compare",playerIds:ra}),ya=ea?`${X.map(e=>e.name).join(" vs ")} - ScoutsLand`:"Player Comparison - ScoutsLand",{isSignedIn:xa}=o(),{data:fa,loading:ba,refetch:ka}=i({variables:qe,skip:!xa}),va=w.useMemo(()=>fa?.myComparisonHistory?.comparisons||[],[fa]),{canAccess:wa}=c("FAN"),{canUseAI:ja,remaining:Na,dailyLimit:Sa,isUnlimited:_a,timeUntilReset:Pa,loading:Ca,refetch:Ta}=T(),Aa=!Ca&&!_a&&Sa>0,Ia=w.useMemo(()=>{if(aa.length<2)return{type:"all",label:"All Players",filter:[]};const e=aa.map(e=>e.position).filter(Boolean);if(e.length===aa.length){const a=e.map(U);if(a.every(e=>null!==e)&&1===[...new Set(a.map(e=>e.label))].length){const e=a[0];return{type:"specific",label:e.label,filter:e.names.map(e=>e.toLowerCase())}}const r=[...new Set(e)];if(1===r.length)return{type:"specific",label:r[0],filter:[r[0].toLowerCase()]}}const a=aa.map(e=>B(e.position)),r=[...new Set(a.filter(e=>"all"!==e))];if(1===r.length){const e=r[0],a=F.find(a=>a.key===e)?.categories??[];return{type:"group",label:F.find(a=>a.key===e)?.label??e,filter:a}}return{type:"all",label:"All Players",filter:[]}},[aa]),Ea=Ia.filter.length?Ia.filter:void 0,La=w.useMemo(()=>"all"===Ia.type?"all":B(Ia.filter[0]),[Ia]),[$a,Ma]=w.useState(t.PER_90),[Fa,za]=w.useState(void 0),{series:Ra,loading:Da,loadingPlayerIds:Ua,sharedCompetitions:Ba}=K(aa,Fa,Ea,$a);w.useEffect(()=>{Fa&&!Ba.some(e=>e.competitionId===Fa)&&za(void 0)},[Ba,Fa]);const Ka=function({series:a,players:r,loading:t=!1,loadingPlayerIds:s,positionGroup:n,cohortLabel:l}){const[o,i]=w.useState("all"),[c,d]=w.useState(ye),p=w.useRef(!1),[m,g]=w.useState(!1),[u,h]=w.useState(""),y=e=>{i(e),"all"===e?d(ye):"custom"!==e&&d(new Set(he[e]))},x=w.useRef(new Set),f=w.useRef({}),[b,k]=w.useState(new Set),v=r.map(e=>e.id).join(",");w.useEffect(()=>{p.current=!1},[v]),w.useEffect(()=>{p.current||y(function(e,a){if(a){const e=a.toLowerCase();if(e.includes("goalkeeper")||"gk"===e)return"goalkeeping";if("cdm"===e||"dm"===e||"ldm"===e||"rdm"===e||e.includes("defensive mid")||e.includes("holding mid"))return"defense";if("cam"===e||"am"===e||e.includes("attacking mid")||e.includes("winger")||e.includes("striker")||e.includes("forward")||"st"===e||"cf"===e||"lw"===e||"rw"===e||"ss"===e)return"offense";if("cm"===e||e.includes("central mid")||e.includes("centre mid")||e.includes("box-to-box")||e.includes("box to box"))return"passing";if(e.includes("back")||"cb"===e||e.includes("centre back")||e.includes("center back")||e.includes("wing-back")||e.includes("wing back"))return"defense"}switch(e){case"goalkeeper":return"goalkeeping";case"defender":return"defense";case"midfielder":return"passing";case"forward":return"offense";default:return"all"}}(n,l))},[n,l]),w.useLayoutEffect(()=>{const e=new Set(r.map(e=>e.id));for(const r of[...x.current])e.has(r)||(x.current.delete(r),clearTimeout(f.current[r]),delete f.current[r]);const a=r.map(e=>e.id).filter(e=>!x.current.has(e));if(0===a.length)return void k(a=>{const r=new Set([...a].filter(a=>e.has(a)));return r.size===a.size?a:r});
2a.forEach(e=>x.current.add(e)),k(r=>{const t=new Set(r);return a.forEach(e=>t.add(e)),[...r].forEach(a=>{e.has(a)||t.delete(a)}),t}),a.forEach(e=>{clearTimeout(f.current[e]),f.current[e]=setTimeout(()=>{delete f.current[e],k(a=>{if(!a.has(e))return a;const r=new Set(a);return r.delete(e),r})},500)});const t=f.current,s=x.current;return()=>{a.forEach(e=>{clearTimeout(t[e]),delete t[e],s.delete(e)})}},[v]);const j=w.useMemo(()=>new Map(a.map(e=>[e.id,e])),[a]),N=w.useMemo(()=>t||r.some(e=>b.has(e.id)||s?.has(e.id)),[t,r,b,s]),S=w.useMemo(()=>N?I:I.filter(({stats:e})=>r.some(a=>{const r=j.get(a.id);return!!r&&e.some(({statKey:e})=>{if(E.has(e))return!1;const a=r.rankings.find(a=>a.statName===e.toUpperCase());return(a?.value??0)>0})})),[N,r,j]),_=w.useMemo(()=>S.map(e=>{const a=e.stats.filter(e=>c.has(e.statKey));return a.length>0?{...e,stats:a}:null}).filter(e=>null!==e),[S,c]),P=w.useMemo(()=>{const e=r.map(e=>function(e,a){if(a){const e=a.rankings.find(e=>"SAVES"===e.statName);if(e&&e.value>0)return"GK";if(["GOALS","ASSISTS","TACKLES","PASSES_ACCURATE"].some(e=>(a.rankings.find(a=>a.statName===e)?.value??0)>0))return"FIELD"}if(e.position){const a=e.position.toLowerCase();return a.includes("goalkeeper")||a.includes("keeper")||"gk"===a?"GK":"FIELD"}return null}(e,j.get(e.id))).filter(e=>null!==e);return e.length>=2&&new Set(e).size>1},[r,j]),C=w.useMemo(()=>a.length>0?function(a,r){return a.map(a=>({...a,rankings:r.map(r=>{const t=r.stats.map(e=>a.rankings.find(a=>a.statName===e.statKey.toUpperCase())?.percentile).filter(e=>void 0!==e),s=t.length>0?t.reduce((e,a)=>e+a,0)/t.length:0;return{statName:r.categoryKey.toUpperCase(),statLabel:r.category,percentile:s,value:Math.round(s),rank:0,totalPlayers:0,cohortLabel:"",cohortTier:e.ALL}})}))}(a,S):[],[a,S]),T=w.useMemo(()=>r.length>=2?L(l,n,r.map(e=>e.position)).filter(e=>"general"!==e).slice(0,1):[],[l,n,r]),A=w.useMemo(()=>0===a.length?[]:T.map(r=>{const t=$[r];return{key:r,radarSeries:a.map(a=>({...a,rankings:t.map(({statKey:r})=>{const t=a.rankings.find(e=>e.statName===r);return{statName:r,statLabel:M.get(r)??r,percentile:t?.percentile??0,value:t?.value??0,rank:t?.rank??0,totalPlayers:t?.totalPlayers??0,cohortLabel:"",cohortTier:e.ALL}})}))}}),[a,T]),R=a[0]?.rankings[0]?.totalPlayers??0,D=l??F.find(e=>e.key===n)?.label??"All Players",U=r.map((e,a)=>({id:e.id,name:e.name,color:j.get(e.id)?.color??z[a]??"#9ca3af",photo:e.photo}));return{activePreset:o,selectedStatKeys:c,showStatPicker:m,setShowStatPicker:g,statSearch:u,setStatSearch:h,selectPreset:e=>{p.current=!0,y(e)},toggleStat:e=>{p.current=!0,i("custom"),d(a=>{const r=new Set(a);return r.has(e)?r.delete(e):r.add(e),r})},pendingIds:b,seriesByPlayerId:j,anyStillLoading:N,visibleCategories:S,displayCategories:_,hasPositionMismatch:P,categoryRadarSeries:C,cascadeKeys:T,cascadeData:A,poolSize:R,activeCohortName:D,displayPlayers:U}}({series:Ra,players:aa,loading:Da,loadingPlayerIds:Ua,positionGroup:La,cohortLabel:"specific"===Ia.type?Ia.label:void 0}),[Oa,{data:Wa,variables:Ga}]=d(),[qa,{data:Va,loading:Ha}]=p(),[Qa,{loading:Ya}]=m(),[Za]=g(),Xa=Va?.enhancedPlayerComparison,Ja=Ga?.player1Id===Xe?.id&&Ga?.player2Id===Je?.id?Wa?.checkPlayerComparisonExists?.exists:void 0,[er]=u(),[ar]=h(),[rr]=h(),tr=A(er),sr=A(ar),nr=A(rr),[lr,or]=w.useState(new Set),ir=w.useRef(null);w.useEffect(()=>{or(e=>{if(0===e.size)return e;const a=new Set(X.map(e=>e.id));let r=!1;const t=new Set;return e.forEach(e=>{a.has(e)?t.add(e):r=!0}),r&&(ir.current=null),r?t:e})},[X]);const cr=X.filter(e=>!(e.position&&void 0!==e.age||lr.has(e.id))),dr=cr.map(e=>e.id).join(","),pr=w.useRef(cr);w.useEffect(()=>{pr.current=cr}),w.useEffect(()=>{if(!dr)return;if(ir.current===dr)return;ir.current=dr;const e=pr.current;or(a=>{const r=new Set(a);return e.forEach(e=>r.add(e.id)),r}),e.forEach(e=>{(async()=>{try{let a;if(e.slug){const{data:r}=await sr.current({variables:{slug:e.slug}});a=r?.playerBySlug??void 0}else{const{data:r}=await tr.current({variables:{id:e.id}});a=r?.player??void 0}if(!a)return;const r=He(a);J(a=>a.map(a=>a.id===e.id?{...a,position:a.position??r.position,age:a.age??r.age,height:a.height??r.height,preferredFoot:a.preferredFoot??r.preferredFoot,contractEnd:a.contractEnd??r.contractEnd}:a))}catch{}})()})},[dr,tr,sr]),w.useEffect(()=>{if(j)return;if(q.current)return;q.current=!0;const e=V.current,a=[v.get("p1"),v.get("p2"),v.get("p3"),v.get("p4")];if(a.every(e=>!e))return;const r=async e=>{if(/^[a-fA-F0-9]{24}$/.test(e)){const{data:a}=await tr.current({variables:{id:e}});return a?.player?He(a.player):null}const{data:a}=await sr.current({variables:{slug:e}});return a?.playerBySlug?He(a.playerBySlug):null},t=async e=>{try{const a=await r(e);if(a)return a}catch{}try{return await r(e)}catch{return null}};ke(!0),(async()=>{const r=[];for(const e of a){if(!e)continue;const a=await t(e);a&&r.push(a)}V.current===e&&(J(r),ke(!1))})()},[]),w.useEffect(()=>{Y.current||(Y.current=!0,(async()=>{const e=Ve.flat(),a=async e=>{const{data:a}=await nr.current({variables:{slug:e}});return a?.playerBySlug?He(a.playerBySlug):null},r=async e=>{try{const r=await a(e);if(r)return r}catch{}try{return await a(e)}catch{return null}},t=[];for(const n of e)t.push(await r(n));const s=[];for(let n=0;n<Ve.length;n++){const e=t[2*n],a=t[2*n+1];e&&a&&s.push([e,a])}se(s),le(!1)})())},[nr]),w.useEffect(()=>{if("undefined"==typeof window)return;const{p1:e,p2:a,p3:r,p4:t}=W.current;if(0===X.length&&(e||a||r||t))return;const s=new URLSearchParams;
2X.forEach((e,a)=>{s.set(`p${a+1}`,e.slug??e.id)});const n=s.toString(),l=n?`${window.location.pathname}?${n}`:window.location.pathname;l!==`${window.location.pathname}${window.location.search}`&&window.history.replaceState(window.history.state,"",l)},[X]),w.useEffect(()=>{const e=()=>{V.current+=1,W.current={p1:null,p2:null,p3:null,p4:null},J([]),de(!1),xe([]),we(!1),Se(!1),Ce(!1),$e({isTranslated:!1,isLoading:!1}),Ze(null),ke(!1)};return window.addEventListener("compare:reset",e),()=>window.removeEventListener("compare:reset",e)},[]);const mr=A(Oa);w.useEffect(()=>{Xe&&Je&&mr.current({variables:{player1Id:Xe.id,player2Id:Je.id}})},[Xe?.id,Je?.id]);const gr=ea?Xa?.success?"view":xa&&wa?ja?"generate":"limit_reached":"upgrade":void 0,ur="generate"===gr&&Aa?b("compare.aiUsageCount","{{remaining}} / {{limit}} remaining today",{remaining:Na,limit:Sa}):"limit_reached"===gr&&Pa?b("compare.resetsIn","Resets in {{time}}",{time:Pa}):void 0,hr="upgrade"===gr?"/pricing":void 0;w.useEffect(()=>{const e=Fe.current;if(!e)return void Ce(!1);const a=new IntersectionObserver(([e])=>Ce(!e.isIntersecting&&e.boundingClientRect.top<0),{threshold:0,rootMargin:"-64px 0px 0px 0px"});return a.observe(e),()=>a.disconnect()},[Va]),w.useEffect(()=>{if(!ce)return;const e=Re.current,a='button:not([disabled]), [href], input, select, textarea, [tabindex]:not([tabindex="-1"])';e?.querySelector(a)?.focus();const r=r=>{if("Escape"===r.key)return void de(!1);if("Tab"!==r.key||!e)return;const t=Array.from(e.querySelectorAll(a));if(0===t.length)return;const s=t[0],n=t[t.length-1];r.shiftKey&&document.activeElement===s?(r.preventDefault(),n.focus()):r.shiftKey||document.activeElement!==n||(r.preventDefault(),s.focus())};return document.addEventListener("keydown",r),()=>{document.removeEventListener("keydown",r),De.current?.focus()}},[ce]);const yr=async(e,a)=>{const r=e??Xe?.id,t=a??Je?.id;if(!r||!t)return;const s=X.find(e=>e.id===r)?.name??r,l=X.find(e=>e.id===t)?.name??t;Ze([r,t]),de(!1),setTimeout(()=>{ze.current?.scrollIntoView({behavior:"smooth",block:"start"})},150);try{const e=await Qa({variables:{player1Id:r,player2Id:t}});e.data?.generateEnhancedPlayerComparison?.success&&(Ja?n.regenerateComparison(s,l):n.generateComparison(s,l),Ta(),ka(),qa({variables:{player1Id:r,player2Id:t}}))}catch(o){console.error("Failed to generate comparison:",o)}},xr=w.useMemo(()=>va.slice(0,3).map(e=>[{id:e.player1.id,name:e.player1.name,photo:e.player1.photo||void 0,position:e.player1.position||void 0,club:e.player1.club||void 0},{id:e.player2.id,name:e.player2.name,photo:e.player2.photo||void 0,position:e.player2.position||void 0,club:e.player2.club||void 0}]),[va]),fr=k.language?.split("-")[0]||"en",br=w.useCallback(async()=>{const e=Va?.enhancedPlayerComparison?.id;if(!e)return;const a=Va?.enhancedPlayerComparison?.translations;if(a?.length){const e=a.find(e=>e.language===fr);if(e?.content)return void $e({isTranslated:!0,isLoading:!1,content:e.content})}$e({isTranslated:!1,isLoading:!0});try{const a=await Za({variables:{comparisonId:e,targetLanguage:fr}}),r=a.data?.translateEnhancedComparison;r?.success&&r.translatedContent?$e({isTranslated:!0,isLoading:!1,content:r.translatedContent}):$e({isTranslated:!1,isLoading:!1,error:r?.error||"Translation failed"})}catch(r){$e({isTranslated:!1,isLoading:!1,error:r instanceof Error?r.message:"Translation failed"})}},[Va,fr,Za]),kr=w.useCallback(()=>{$e(e=>({...e,isTranslated:!e.isTranslated}))},[]);w.useEffect(()=>{$e({isTranslated:!1,isLoading:!1}),we(!1)},[Va?.enhancedPlayerComparison?.id]);const vr=w.useRef(null);w.useEffect(()=>{if(!Ja||!Xe||!Je)return;const e=`${Xe.id}|${Je.id}`;vr.current!==e&&(vr.current=e,qa({variables:{player1Id:Xe.id,player2Id:Je.id}}))},[Ja,Xe?.id,Je?.id]);const wr=ea?X.map(e=>e.name).join(" vs "):"",jr=w.useMemo(()=>ea?new Intl.ListFormat(k.language,{style:"long",type:"conjunction"}).format(X.map(e=>e.name)):"",[ea,X,k.language]);return N.jsxs(N.Fragment,{children:[N.jsx(ge,{title:ea?b("compare.pageTitleWithPlayers","{{names}} | Player Comparison | ScoutsLand",{names:wr}):b("compare.pageTitle","Compare Football Players | ScoutsLand"),description:ea?b("compare.pageDescriptionWithPlayers","Compare {{names}} side-by-side with global percentile stats, radar charts, and AI-powered analysis.",{names:jr}):b("compare.pageDescription","Compare any two football players with AI-powered analysis. Explore side-by-side percentile stats, performance radar, and expert recommendations."),keywords:"football player comparison, compare soccer players, player stats comparison, AI football analysis, percentile ranking",url:"undefined"!=typeof window?window.location.href:"/compare",structuredData:Xe&&Je?{"@context":"https://schema.org","@type":"WebPage",name:`${Xe.name} vs ${Je.name} — ScoutsLand`,description:`Compare ${Xe.name} and ${Je.name} with global percentile stats and AI analysis.`,mainEntity:[{"@type":"Person",name:Xe.name,url:Xe.slug?`${"undefined"!=typeof window?window.location.origin:""}/player/${Xe.slug}`:void 0},{"@type":"Person",name:Je.name,url:Je.slug?`${"undefined"!=typeof window?window.location.origin:""}/player/${Je.slug}`:void 0}]}:{"@context":"https://schema.org","@type":"WebApplication",name:"Football Player Comparison Tool — ScoutsLand",description:"Compare any two football players side-by-side with percentile stats, radar charts, and AI-powered analysis.",applicationCategory:"SportsApplication",operatingSystem:"Web",offers:{"@type":"Offer",price:"0",priceCurrency:"USD"}}}),N.jsxs("div",{className:"max-w-[1720px] mx-auto px-1 sm:px-7 pt-1 pb-6 sm:pb-16",children:[N.jsxs("div",{className:"flex flex-wrap items-start justify-between gap-x-6 gap-y-1 mb-3 sm:mb-4",children:[N.jsxs("div",{children:[N.jsx("h1",{className:"text-xl sm:text-[26px] font-bold text-gray-900 dark:text-gray-100 leading-tight",children:X.length>=2?X.map(e=>e.name).join(" vs "):b("compare.title","Player Comparison")}),N.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-400 mt-0.5",children:b("compare.tagline","Up to four players side by side, ranked by global percentile.")})]}),Ra.length>0&&Ka.poolSize>0&&N.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 shrink-0 sm:text-right max-w-xs",children:b("compare.cohortInfo","Percentiles among {{cohort}} players with meaningful data",{cohort:`${Ka.poolSize.toLocaleStr
2ing()} ${Ka.activeCohortName.toLowerCase()}`})})]}),X.length>0&&N.jsx(_e,{className:"min-[901px]:hidden",players:X,maxPlayers:D,onRemove:ie,onAdd:oe,excludeIds:ra,pendingIds:Ka.pendingIds}),N.jsxs("div",{className:"grid gap-3 sm:gap-5 items-start grid-cols-1 min-[901px]:grid-cols-[320px_minmax(0,1fr)] min-[1221px]:grid-cols-[372px_minmax(0,1fr)]",children:[N.jsxs("aside",{className:"grid grid-cols-1 gap-3 min-[641px]:max-[901px]:grid-cols-2 min-[901px]:sticky min-[901px]:top-[80px]",children:[(X.length>0||be)&&N.jsx(Ne,{hasPlayers:X.length>0,categoryRadarSeries:Ka.categoryRadarSeries,cascadeKeys:Ka.cascadeKeys,cascadeData:Ka.cascadeData,activeCohortName:Ka.activeCohortName,poolSize:Ka.poolSize,loading:be||Da,onShare:ea?sa:void 0}),0===X.length&&!be&&(xr.length>0?N.jsx(Oe,{pairs:xr,onSelect:e=>{const[a,r]=e;n.loadComparisonFromHistory(a.name,r.name),J(e),qa({variables:{player1Id:a.id,player2Id:r.id}})}}):ba&&N.jsx(We,{})),0===X.length&&!be&&(te.length>0?N.jsx(Be,{pairs:te,onSelect:e=>J(e)}):ne&&N.jsx(Ke,{}))]}),N.jsx("div",{className:"min-w-0",children:be?N.jsx(Ye,{}):0===X.length?N.jsx(Me,{onAdd:oe}):N.jsxs(N.Fragment,{children:[N.jsx(_e,{className:"hidden min-[901px]:block",players:X,maxPlayers:D,onRemove:ie,onAdd:oe,excludeIds:ra,pendingIds:Ka.pendingIds}),N.jsxs("div",{className:"pt-3 min-[901px]:pt-0",children:["upgrade"===gr?N.jsx(Ae,{aiHref:hr}):"view"!==gr&&N.jsx(Te,{aiCTA:gr,onAIClick:()=>{"generate"===gr&&(X.length>2?(De.current=document.activeElement,xe([X[0].id,X[1].id]),de(!0)):yr())},aiHref:hr,aiGenerating:Ya||Ha,aiUsageLabel:ur,aiBannerPlayers:Xe&&Je?[Xe.name,Je.name]:void 0,hasMultiplePlayers:Ra.length>=2,totalPlayerCount:X.length}),N.jsxs("div",{ref:ze,children:[(Ha||Ya)&&N.jsx("div",{className:"mb-3 sm:mb-4",children:N.jsx(Qe,{generating:Ya})}),!Ya&&!Ha&&Xa?.success&&Xa.comparison&&Xe&&Je&&N.jsx("div",{className:"mb-3 sm:mb-4",children:N.jsx(S.Suspense,{fallback:N.jsx(Qe,{}),children:N.jsx(Ge,{comparison:Xa,player1:Xe,player2:Je,showStickyPlayers:Pe,profileCardsRef:Fe,isExpanded:ve,onToggleExpanded:()=>we(e=>!e),translationState:Ee,handleTranslate:br,handleToggleOriginal:kr,showCopyToast:je,setShowCopyToast:Se,onChangePair:X.length>2?()=>{De.current=document.activeElement,xe(Ue??[X[0]?.id??"",X[1]?.id??""]),de(!0)}:void 0})})}),!Ya&&!Ha&&Xa&&!Xa.success&&Xa.error&&"No cached comparison found"!==Xa.error&&N.jsx(C,{className:"p-6 mb-3 sm:mb-4 bg-red-50 dark:bg-red-900/20 border-red-200 dark:border-red-800",children:N.jsx("p",{className:"text-red-600 dark:text-red-400",children:Xa.error})})]}),N.jsx(Ie,{activePreset:Ka.activePreset,onSelectPreset:Ka.selectPreset,showStatPicker:Ka.showStatPicker,setShowStatPicker:Ka.setShowStatPicker,statSearch:Ka.statSearch,setStatSearch:Ka.setStatSearch,selectedStatKeys:Ka.selectedStatKeys,toggleStat:Ka.toggleStat,valueMode:$a,onValueModeChange:Ma}),1===X.length&&N.jsx("p",{className:"text-xs text-center text-gray-500 dark:text-gray-400 py-3",children:b("playerPage.comparison.addOneMore","Add one more player to start comparing")}),Ka.hasPositionMismatch&&N.jsxs("div",{className:"flex items-start gap-2 px-3 py-2.5 mb-3 bg-amber-50 dark:bg-amber-900/20 border border-amber-200 dark:border-amber-800/40 rounded-lg",children:[N.jsx(ee,{className:"w-3.5 h-3.5 text-amber-500 shrink-0 mt-0.5"}),N.jsx("p",{className:"text-xs text-amber-700 dark:text-amber-400",children:b("playerPage.comparison.positionMismatch","These players are from different positions — goalkeeping and outfield stats are not directly comparable.")})]}),N.jsxs("div",{className:"flex items-start gap-2 px-3 py-2.5 mb-3 bg-gray-50 dark:bg-gray-800/40 border border-gray-200 dark:border-gray-700/50 rounded-lg",children:[N.jsx(ae,{className:"w-3.5 h-3.5 text-gray-400 dark:text-gray-500 shrink-0 mt-0.5"}),N.jsxs("div",{className:"flex-1 min-w-0",children:[N.jsx("p",{className:"text-xs text-gray-600 dark:text-gray-400",children:Fa?b("playerPage.comparison.rollingWindowBannerCompetition",{defaultValue:"Comparing {{competitionName}} form only (last 12 months).",competitionName:Ba.find(e=>e.competitionId===Fa)?.competitionName??""}):b("playerPage.comparison.rollingWindowBanner","Comparing last 12 months of form.")}),Ba.length>0&&N.jsxs("div",{className:"flex flex-wrap items-center gap-1 mt-1.5 bg-gray-100 dark:bg-gray-700 rounded-xl p-0.5 w-fit",role:"radiogroup",children:[N.jsx("button",{type:"button",role:"radio","aria-checked":!Fa,onClick:()=>za(void 0),className:"px-2.5 py-1 rounded-full text-[11px] font-semibold whitespace-nowrap transition-colors "+(Fa?"text-gray-500 dark:text-gray-400":"bg-white dark:bg-gray-900 text-primary-600 dark:text-primary-400 shadow-sm"),children:b("playerPage.comparison.rollingWindowAllOption","All (last 12 months)")}),Ba.map(e=>N.jsxs("button",{type:"button",role:"radio","aria-checked":Fa===e.competitionId,onClick:()=>za(e.competitionId),className:"flex items-center gap-1 px-2.5 py-1 rounded-full text-[11px] font-semibold whitespace-nowrap transition-colors "+(Fa===e.competitionId?"bg-white dark:bg-gray-900 text-primary-600 dark:text-primary-400 shadow-sm":"text-gray-500 dark:text-gray-400"),children:[e.competitionLogo&&N.jsx("img",{src:e.competitionLogo,alt:"","aria-hidden":"true",className:"w-3.5 h-3.5 object-contain shrink-0"}),e.competitionName]},e.competitionId))]})]})]}),!Da&&0===Ra.length&&X.length>=2&&N.jsx("div",{className:"py-4 text-center text-sm text-gray-500 dark:text-gray-400",children:b("playerPage.rankingsTab.noData","Not enough data for this stat")}),0===Ka.displayCategories.length&&!Ka.anyStillLoading&&X.length>=2&&N.jsx("p",{className:"text-xs text-center text-gray-500 dark:text-gray-400 py-6",children:b("playerPage.comparison.noStatsVisible","No stats match the current filter.")}),N.jsx("div",{className:"space-y-3",children:Ka.displayCategories.map(e=>N.jsx(Le,{category:e.category,categoryKey:e.categoryKey,stats:e.stats,displayPlayers:Ka.displayPlayers,seriesByPlayerId:Ka.seriesByPlayerId,pendingIds:Ka.pendingIds,loading:Da,valueMode:$a},e.categoryKey))}),Ra.length>0&&N.jsx("p",{className:"text-xs text-center text-gray-500 dark:text-gray-400 mt-4 px-2",children:b("compare.globalPercentileFooter","Percentiles ranked globally among all players.")})]})]})})]}),ce&&N.jsxs(N.Fragment,{children:[N.jsx("div",{className:"fixed inset-0 z-40 bg-black/50 backdrop-blur-sm",onClick:()=>de(!1),"aria-hidden":"true"}),N.jsx("div",{className:"fixed inset-0 z-50 flex items-center justify-center p-4 pointer-events-none",children:N.jsxs("div",{ref:Re,className:"bg-white dark:bg-gray-900 rounded-2xl shadow-2xl w-full max-w-sm p-5 pointer-events-auto",role:"dialog","aria-modal":"true","aria-labelledby":"ai-pair-dialog-title",children:[N.jsxs("div",{className:"flex items-center justify-between mb-4",children:[N.jsxs("div",{children:[N.jsx("h3",{id:"ai-pair-dialog-title",className:"text-sm font-bold text-gray-900 dark:text-gray-100",children:b("compare.selectAIPairTitle","Choose 2 players for AI analysis")}),N.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0.5",children:b("compare.selectAIPairSub","Select exactly 2 players to compare")})]}),N.jsx("button",{onClick:()=>de(!1),className:"p-1.5 rounded-lg text-gray-500 dark:text-gray-400 hover:text-gray-600 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-800 transition-colors","aria-label":b("common.closeDialog","Close dialog"),children:N.jsx(H,{className:"w-4 h-4"})})]}),N.jsx("div",{className:"flex flex-col gap-2 mb-5",children:X.map(e=>{const r=ue.includes(e.id),t=!r&&ue.length>=2;return N.jsxs("button",{onClick:()=>fe(e.id),disabled:t,className:"flex items-center gap-3 px-3 py-2.5 rounded-xl border-2 transition-all text-left "+(r?"border-purple-500 bg-purple-50 dark:bg-purple-900/20":t?"border-gray-100 dark:border-gray-700 opacity-40 cursor-not-allowed":"border-gray-200 dark:border-gray-700 hover:border-purple-300 dark:hover:border-purple-600"),children:[N.jsx(a,{imageUrl:e.photo,altText:e.name,size:"sm",className:"shrink-0"}),N.jsx("span",{className:"flex-1 text-sm font-medium text-gray-900 dark:text-gray-100",children:e.name}),N.jsx("div",{className:"w-5 h-5 rounded-full border-2 shrink-0 flex items-center justify-center transition-colors "+(r?"border-purple-500 bg-purple-500":"border-gray-300 dark:border-gray-600"),children:r&&N.jsx(Z,{className:"w-3 h-3 text-white",strokeWidth:3})})]},e.id)})}),N.jsxs(y,{onClick:()=>{2===ue.length&&yr(ue[0],ue[1])},disabled:2!==ue.length,className:"w-full",children:[N.jsx(Q,{className:"w-4 h-4 mr-1.5"}),b("compare.generate","Generate")]})]})})]}
2),N.jsxs("section",{"aria-labelledby":"compare-faq-heading",className:"mt-7 sm:mt-10",children:[N.jsx("h2",{id:"compare-faq-heading",className:"text-base font-semibold text-gray-900 dark:text-gray-100 mb-3",children:b("compare.faqHeading","Frequently asked questions")}),N.jsx("div",{className:"grid grid-cols-1 min-[1101px]:grid-cols-2 gap-3",children:[["faqQ1","faqA1","What does a percentile score mean?","A percentile shows how a player ranks relative to all other players in the ScoutsLand database for a given stat. A score of 90 means the player outperforms 90% of tracked players in that metric, regardless of league or nationality."],["faqQ2","faqA2","Are the percentiles from the same league?","The global comparison tool ranks players across all tracked leagues worldwide. This lets you directly compare a Bundesliga striker with a Premier League winger, for example. Each player's individual league rankings tab uses league relative percentiles instead."],["faqQ3","faqA3","How many players can I compare at once?","You can add up to four players at the same time. The radar chart overlays all four polygons, and the stat breakdown table lists each player in their own column for easy reading."],["faqQ4","faqA4","How often is player data updated?","Match statistics are processed after every fixture and typically appear within a few hours of the final whistle. Season aggregates are recalculated nightly."],["faqQ5","faqA5","What does the AI comparison do?","The AI analysis (available to FAN subscribers) generates a written narrative comparing the two selected players across performance, playing style, and potential. It draws on the same underlying statistics visible in the comparison table and is labelled as experimental."]].map(([e,a,r,t])=>N.jsxs("details",{className:"group rounded-lg border border-gray-100 dark:border-gray-800 px-3.5",children:[N.jsxs("summary",{className:"flex items-center justify-between gap-3 py-3 cursor-pointer list-none text-sm font-semibold text-gray-800 dark:text-gray-200 hover:text-gray-900 dark:hover:text-gray-100 transition-colors",children:[b(`compare.${e}`,r),N.jsx(re,{className:"w-4 h-4 text-gray-400 shrink-0 transition-transform duration-200 group-open:rotate-180"})]}),N.jsx("p",{className:"pb-3 text-sm text-gray-600 dark:text-gray-400 leading-relaxed",children:b(`compare.${a}`,t)})]},e))})]}),N.jsx("p",{className:"text-sm text-gray-600 dark:text-gray-400 max-w-2xl mx-auto text-center leading-relaxed mt-7 sm:mt-10",children:Xe&&Je?b("compare.dynamicContext","Comparing {{p1}}{{pos1}} and {{p2}}{{pos2}}. The percentile scores above reflect each player's standing among all players tracked in the ScoutsLand database. A higher percentile in a given stat means the player outperforms a larger share of their worldwide peers for that metric.",{p1:Xe.name,pos1:Xe.position?` (${Xe.position})`:"",p2:Je.name,pos2:Je.position?` (${Je.position})`:""}):b("compare.evergreenIntro","ScoutsLand's comparison tool lets you place up to four football players side by side and instantly see how they rank globally across goals, assists, passing accuracy, defensive duels, and more. Each metric is expressed as a percentile among all tracked players, so a score of 85 means the player outperforms 85% of peers worldwide. Add players by searching below, or tap one of the popular comparisons to get started.")})]}),N.jsx(me,{isOpen:ta,onClose:na,type:"compare",imageUrl:da,format:la,onFormatChange:oa,cardLanguage:ia,onCardLanguageChange:ca,onDownload:pa,isDownloading:ma,previewBlobUrl:ga,isFetchingPreview:ua,fetchImageBlob:ha,shareUrl:"undefined"!=typeof window?window.location.href:"/compare",shareTitle:ya,hashtags:["Football","PlayerComparison","ScoutsLand"]})]})},Xe=e=>{const a=j.c(6),{ssrPlayer1:r,ssrPlayer2:t,ssrPlayer3:s,ssrPlayer4:n}=e;let l,o;return a[0]===Symbol.for("react.memo_cache_sentinel")?(l=[],a[0]=l):l=a[0],w.useEffect(sa,l),a[1]!==r||a[2]!==t||a[3]!==s||a[4]!==n?(o=N.jsx(Ze,{ssrPlayer1:r,ssrPlayer2:t,ssrPlayer3:s,ssrPlayer4:n}),a[1]=r,a[2]=t,a[3]=s,a[4]=n,a[5]=o):o=a[5],o};function Je(e){return N.jsx("div",{className:"h-24 bg-gray-200 dark:bg-gray-700 rounded"},e)}function ea(e){return N.jsxs("div",{className:"flex items-center gap-2",children:[N.jsx("div",{className:"w-10 h-10 rounded-full bg-gray-200 dark:bg-gray-700 shrink-0"}),N.jsx("div",{className:"h-3.5 w-20 bg-gray-200 dark:bg-gray-700 rounded"})]},e)}function aa(e){return N.jsx("div",{className:"h-6 w-14 bg-gray-200 dark:bg-gray-700 rounded-full"},e)}function ra(e){return N.jsxs("div",{className:"flex items-center gap-4",children:[N.jsx("div",{className:"h-2.5 w-16 bg-gray-200 dark:bg-gray-700 rounded shrink-0"}),N.jsx("div",{className:"h-1.5 flex-1 bg-gray-200 dark:bg-gray-700 rounded-full"}),N.jsx("div",{className:"h-1.5 flex-1 bg-gray-200 dark:bg-gray-700 rounded-full"})]},e)}function ta(e){return N.jsxs("div",{className:"rounded-xl border border-gray-100 dark:border-gray-700/60 overflow-hidden",children:[N.jsx("div",{className:"px-4 py-2 bg-gray-50/70 dark:bg-gray-800/50 border-b border-gray-100 dark:border-gray-700/60",children:N.jsx("div",{className:"h-2.5 w-20 bg-gray-200 dark:bg-gray-700 rounded"})}),N.jsx("div",{className:"p-4 space-y-3",children:[0,1,2].map(ra)})]},e)}function sa(){n.viewComparePage()}const na={hasServerOnlyHook:{type:"computed",definedAtData:null,valueSerialized:{type:"js-serialized",value:!0}},isClientRuntimeLoaded:{type:"computed",definedAtData:null,valueSerialized:{type:"js-serialized",value:!0}},onBeforeRenderEnv:{type:"computed",definedAtData:null,valueSerialized:{type:"js-serialized",value:null}},dataEnv:{type:"computed",definedAtData:null,valueSerialized:{type:"js-serialized",value:{server:!0}}},guardEnv:{type:"computed",definedAtData:null,valueSerialized:{type:"js-serialized",value:null}},onRenderClient:{type:"standard",definedAtData:{filePathToShowToUser:"vike-react/__internal/integration/onRenderClient",fileExportPathToShowToUser:[]},valueSerialized:{type:"pointer-import",value:v}},onPageTransitionStart:{type:"standard",definedAtData:{filePathToShowToUser:"/pages/+onPageTransitionStart.ts",fileExportPathToShowToUser:[]},valueSerialized:{type:"plus-file",exportValues:k}},onPageTransitionEnd:{type:"standard",definedAtData:{filePathToShowToUser:"/pages/+onPageTransitionEnd.ts",fileExportPathToShowToUser:[]},valueSerialized:{type:"plus-file",exportValues:b}},Page:{type:"standard",definedAtData:{filePathToShowToUser:"/pages/compare/+Page.tsx",fileExportPathToShowToUser:[]},valueSerialized:{type:"plus-file",exportValues:Object.freeze(Object.defineProperty({__proto__:null,default:function(){const e=j.c(5),a=_(),r=a?.ssrPlayer1,t=a?.ssrPlayer2,s=a?.ssrPlayer3,n=a?.ssrPlayer4;let l;return e[0]!==r||e[1]!==t||e[2]!==s||e[3]!==n?(l=N.jsx(Xe,{ssrPlayer1:r,ssrPlayer2:t,ssrPlayer3:s,ssrPlayer4:n}),e[0]=r,e[1]=t,e[2]=s,e[3]=n,e[4]=l):l=e[4],l}},Symbol.toStringTag,{value:"Module"}))}},hydrationCanBeAborted:{type:"standard",definedAtData:{filePathToShowToUser:"vike-react/config",fileExportPathToShowToUser:["default","hydrationCanBeAborted"]},valueSerialized:{type:"js-serialized",value:!0}},prefetchStaticAssets:{type:"standard",definedAtData:{filePathToShowToUser:"/pages/+config.ts",fileExportPathToShowToUser:["default","prefetchStaticAssets"]},valueSerialized:{type:"js-serialized",value:"viewport"}},Layout:{type:"cumulative",definedAtData:[{filePathToShowToUser:"/pages/+Layout.t
2sx",fileExportPathToShowToUser:[]}],valueSerialized:[{type:"plus-file",exportValues:f}]},Loading:{type:"standard",definedAtData:{filePathToShowToUser:"vike-react/__internal/integration/Loading",fileExportPathToShowToUser:[]},valueSerialized:{type:"pointer-import",value:x}}};export{na as configValuesSerialized};

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.