1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/chunks/chunk-CevWb9s-.js","assets/chunks/chunk-BdElISNf.js","assets/chunks/chunk-Bo93X7SF.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-Dv47tmcI.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 t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="6279c5ed-3f39-4e96-bff9-b47b8b8ddd69",e._sentryDebugIdIdentifier="sentry-dbid-6279c5ed-3f39-4e96-bff9-b47b8b8ddd69")}catch(a){}}();import{f as e,j as t,r as a}from"./chunk-Bo93X7SF.js";import{_ as l}from"./chunk-CEAvvLL5.js";import{aT as o,D as s,aa as i,Q as r,i as n,L as c}from"./chunk-BdElISNf.js";import{u as m}from"./chunk-BlzVP_eY.js";import{u as d}from"./chunk-boBG-PUB.js";import{a as b}from"./chunk-BI2aRVOj.js";import{C as x}from"./chunk-B-q7Er8f.js";import{R as p}from"./chunk-Dmm2O1J_.js";import{b as y}from"./chunk-4M2Zh3rp.js";import{D as h}from"./chunk-2wjexlcT.js";import{u as g}from"./chunk-Cn4GVL-M.js";import{T as u,d as f}from"./chunk-DmcL_7MB.js";function F(e){const{derivedPositions:t,days:a=7,startDate:s,endDate:i,competitionId:r,sportmonksLeagueIds:n,minMinutes:c=45,nationalityIds:d,minAge:b,maxAge:x,playerIds:p,clubIds:y,sortBy:h="bestMatch",positionGroups:g,rounds:u,stages:f,enabled:F=!0}=e,R=u&&u.length>0||f&&f.length>0,{data:k,loading:D,error:C,refetch:E}=m(o,{variables:{derivedPositions:t,days:R||s&&i?void 0:a,startDate:R?void 0:s||void 0,endDate:R?void 0:i||void 0,competitionId:r||void 0,sportmonksLeagueIds:n&&n.length>0?n:void 0,minMinutes:c,nationalityIds:d&&d.length>0?d:void 0,minAge:b,maxAge:x,playerIds:p&&p.length>0?p:void 0,clubIds:y&&y.length>0?y:void 0,sortBy:h,positionGroups:g&&g.length>0?g:void 0,rounds:u&&u.length>0?u:void 0,stages:f&&f.length>0?f:void 0},skip:!F||0===t.length,fetchPolicy:"cache-first"});return C&&l(async()=>{const{Sentry:e}=await(import("./chunk-CevWb9s-.js"));return{Sentry:e}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13])).then(({Sentry:e})=>{e.captureException(C,{tags:{hook:"useTeamOfTheWeek"},extra:{derivedPositions:t,days:a,competitionId:r}})}).catch(()=>{}),{performances:k?.teamOfTheWeek??[],loading:D,error:C,refetch:E}}function R(e){const t=e?.toUpperCase();if(t)return t.startsWith("GK")||t.startsWith("GOALKEEPER")?"GK":t.startsWith("DEF")?"DEF":t.startsWith("MID")?"MID":t.startsWith("FWD")||t.startsWith("FORWARD")||t.startsWith("ATT")?"FWD":void 0}const k={"4-2-3-1":{name:"4-2-3-1",slots:[{label:"GK",x:50,y:92,compatiblePositions:["GK"],categoryFallback:"GOALKEEPER"},{label:"LB",x:12,y:75,compatiblePositions:["LB","LWB"],categoryFallback:"DEFENDER"},{label:"CB",x:35,y:78,compatiblePositions:["CB","LCB","RCB"],categoryFallback:"DEFENDER"},{label:"CB",x:65,y:78,compatiblePositions:["CB","RCB","LCB"],categoryFallback:"DEFENDER"},{label:"RB",x:88,y:75,compatiblePositions:["RB","RWB"],categoryFallback:"DEFENDER"},{label:"CDM",x:35,y:60,compatiblePositions:["CDM","LCDM","RCDM","CM","LCM"],categoryFallback:"MIDFIELDER"},{label:"CDM",x:65,y:60,compatiblePositions:["CDM","RCDM","LCDM","CM","RCM"],categoryFallback:"MIDFIELDER"},{label:"LW",x:15,y:35,compatiblePositions:["LW","LM","LAM","LF"],categoryFallback:"FORWARD"},{label:"CAM",x:50,y:40,compatiblePositions:["CAM","LCAM","RCAM","CM"],categoryFallback:"MIDFIELDER"},{label:"RW",x:85,y:35,compatiblePositions:["RW","RM","RAM","RF"],categoryFallback:"FORWARD"},{label:"ST",x:50,y:18,compatiblePositions:["ST","CF","LST","RST"],categoryFallback:"FORWARD"}]},"4-3-3":{name:"4-3-3",slots:[{label:"GK",x:50,y:92,compatiblePositions:["GK"],categoryFallback:"GOALKEEPER"},{label:"LB",x:12,y:75,compatiblePositions:["LB","LWB"],categoryFallback:"DEFENDER"},{label:"CB",x:35,y:78,compatiblePositions:["CB","LCB","RCB"],categoryFallback:"DEFENDER"},{label:"CB",x:65,y:78,compatiblePositions:["CB","RCB","LCB"],categoryFallback:"DEFENDER"},{label:"RB",x:88,y:75,compatiblePositions:["RB","RWB"],categoryFallback:"DEFENDER"},{label:"CM",x:30,y:55,compatiblePositions:["CM","LCM","CDM","LCDM"],categoryFallback:"MIDFIELDER"},{label:"CM",x:50,y:50,compatiblePositions:["CM","CDM","CAM"],categoryFallback:"MIDFIELDER"},{label:"CM",x:70,y:55,compatiblePositions:["CM","RCM","CDM","RCDM"],categoryFallback:"MIDFIELDER"},{label:"LW",x:15,y:25,compatiblePositions:["LW","LM","LAM","LF"],categoryFallback:"FORWARD"},{label:"ST",x:50,y:18,compatiblePositions:["ST","CF","LST","RST"],categoryFallback:"FORWARD"},{label:"RW",x:85,y:25,compatiblePositions:["RW","RM","RAM","RF"],categoryFallback:"FORWARD"}]},"4-4-2":{name:"4-4-2",slots:[{label:"GK",x:50,y:92,compatiblePositions:["GK"],categoryFallback:"GOALKEEPER"},{label:"LB",x:12,y:75,compatiblePositions:["LB","LWB"],categoryFallback:"DEFENDER"},{label:"CB",x:35,y:78,compatiblePositions:["CB","LCB","RCB"],categoryFallback:"DEFENDER"},{label:"CB",x:65,y:78,compatiblePositions:["CB","RCB","LCB"],categoryFallback:"DEFENDER"},{label:"RB",x:88,y:75,compatiblePositions:["RB","RWB"],categoryFallback:"DEFENDER"},{label:"LM",x:12,y:50,compatiblePositions:["LM","LW","LAM"],categoryFallback:"MIDFIELDER"},{label:"CM",x:35,y:53,compatiblePositions:["CM","LCM","CDM","LCDM"],categoryFallback:"MIDFIELDER"},{label:"CM",x:65,y:53,compatiblePositions:["CM","RCM","CDM","RCDM"],categoryFallback:"MIDFIELDER"},{label:"RM",x:88,y:50,compatiblePositions:["RM","RW","RAM"],categoryFallback:"MIDFIELDER"}
2,{label:"ST",x:35,y:20,compatiblePositions:["ST","CF","LST","LF"],categoryFallback:"FORWARD"},{label:"ST",x:65,y:20,compatiblePositions:["ST","CF","RST","RF"],categoryFallback:"FORWARD"}]},"3-5-2":{name:"3-5-2",slots:[{label:"GK",x:50,y:92,compatiblePositions:["GK"],categoryFallback:"GOALKEEPER"},{label:"CB",x:25,y:78,compatiblePositions:["CB","LCB"],categoryFallback:"DEFENDER"},{label:"CB",x:50,y:80,compatiblePositions:["CB","RCB","LCB"],categoryFallback:"DEFENDER"},{label:"CB",x:75,y:78,compatiblePositions:["CB","RCB"],categoryFallback:"DEFENDER"},{label:"LWB",x:10,y:55,compatiblePositions:["LWB","LB","LM"],categoryFallback:"DEFENDER"},{label:"CM",x:30,y:55,compatiblePositions:["CM","LCM","CDM"],categoryFallback:"MIDFIELDER"},{label:"CM",x:50,y:50,compatiblePositions:["CM","CDM","CAM"],categoryFallback:"MIDFIELDER"},{label:"CM",x:70,y:55,compatiblePositions:["CM","RCM","CDM"],categoryFallback:"MIDFIELDER"},{label:"RWB",x:90,y:55,compatiblePositions:["RWB","RB","RM"],categoryFallback:"DEFENDER"},{label:"ST",x:35,y:20,compatiblePositions:["ST","CF","LST","LF"],categoryFallback:"FORWARD"},{label:"ST",x:65,y:20,compatiblePositions:["ST","CF","RST","RF"],categoryFallback:"FORWARD"}]},"3-4-3":{name:"3-4-3",slots:[{label:"GK",x:50,y:92,compatiblePositions:["GK"],categoryFallback:"GOALKEEPER"},{label:"CB",x:25,y:78,compatiblePositions:["CB","LCB"],categoryFallback:"DEFENDER"},{label:"CB",x:50,y:80,compatiblePositions:["CB","RCB","LCB"],categoryFallback:"DEFENDER"},{label:"CB",x:75,y:78,compatiblePositions:["CB","RCB"],categoryFallback:"DEFENDER"},{label:"LM",x:12,y:50,compatiblePositions:["LM","LWB","LW"],categoryFallback:"MIDFIELDER"},{label:"CM",x:35,y:53,compatiblePositions:["CM","LCM","CDM"],categoryFallback:"MIDFIELDER"},{label:"CM",x:65,y:53,compatiblePositions:["CM","RCM","CDM"],categoryFallback:"MIDFIELDER"},{label:"RM",x:88,y:50,compatiblePositions:["RM","RWB","RW"],categoryFallback:"MIDFIELDER"},{label:"LW",x:20,y:25,compatiblePositions:["LW","LF","LAM"],categoryFallback:"FORWARD"},{label:"ST",x:50,y:18,compatiblePositions:["ST","CF","LST","RST"],categoryFallback:"FORWARD"},{label:"RW",x:80,y:25,compatiblePositions:["RW","RF","RAM"],categoryFallback:"FORWARD"}]},"4-1-4-1":{name:"4-1-4-1",slots:[{label:"GK",x:50,y:92,compatiblePositions:["GK"],categoryFallback:"GOALKEEPER"},{label:"LB",x:12,y:75,compatiblePositions:["LB","LWB"],categoryFallback:"DEFENDER"},{label:"CB",x:35,y:78,compatiblePositions:["CB","LCB","RCB"],categoryFallback:"DEFENDER"},{label:"CB",x:65,y:78,compatiblePositions:["CB","RCB","LCB"],categoryFallback:"DEFENDER"},{label:"RB",x:88,y:75,compatiblePositions:["RB","RWB"],categoryFallback:"DEFENDER"},{label:"CDM",x:50,y:62,compatiblePositions:["CDM","LCDM","RCDM","CM"],categoryFallback:"MIDFIELDER"},{label:"LM",x:12,y:42,compatiblePositions:["LM","LW","LAM"],categoryFallback:"MIDFIELDER"},{label:"CM",x:35,y:45,compatiblePositions:["CM","LCM","CAM","LCAM"],categoryFallback:"MIDFIELDER"},{label:"CM",x:65,y:45,compatiblePositions:["CM","RCM","CAM","RCAM"],categoryFallback:"MIDFIELDER"},{label:"RM",x:88,y:42,compatiblePositions:["RM","RW","RAM"],categoryFallback:"MIDFIELDER"},{label:"ST",x:50,y:18,compatiblePositions:["ST","CF","LST","RST"],categoryFallback:"FORWARD"}]}},D=Object.keys(k),C=()=>{const a=e.c(1);let l;return a[0]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsxs("svg",{className:"absolute inset-0 w-full h-full",viewBox:"0 0 100 133",preserveAspectRatio:"none","aria-hidden":"true",children:[t.jsx("rect",{x:"2",y:"2",width:"96",height:"129",fill:"none",stroke:"white",strokeWidth:"0.4",opacity:"0.5"}),t.jsx("line",{x1:"2",y1:"66.5",x2:"98",y2:"66.5",stroke:"white",strokeWidth:"0.3",opacity:"0.6"}),t.jsx("circle",{cx:"50",cy:"66.5",r:"12",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.6"}),t.jsx("circle",{cx:"50",cy:"66.5",r:"0.8",fill:"white",opacity:"0.6"}),t.jsx("rect",{x:"20",y:"2",width:"60",height:"22",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.6"}),t.jsx("rect",{x:"32",y:"2",width:"36",height:"8",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.6"}),t.jsx("circle",{cx:"50",cy:"16",r:"0.6",fill:"white",opacity:"0.6"}),t.jsx("path",{d:"M 32 24 A 12 12 0 0 0 68 24",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.6"}),t.jsx("rect",{x:"20",y:"109",width:"60",height:"22",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.6"}),t.jsx("rect",{x:"32",y:"123",width:"36",height:"8",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.6"}),t.jsx("circle",{cx:"50",cy:"117",r:"0.6",fill:"white",opacity:"0.6"}),t.jsx("path",{d:"M 32 109 A 12 12 0 0 1 68 109",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.6"}),t.jsx("path",{d:"M 2 5 A 3 3 0 0 0 5 2",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.5"}),t.jsx("path",{d:"M 95 2 A 3 3 0 0 0 98 5",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.5"}),t.jsx("path",{d:"M 2 128 A 3 3 0 0 1 5 131",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.5"}),t.jsx("path",{d:"M 95 131 A 3 3 0 0 1 98 128",fill:"none",stroke:"white",strokeWidth:"0.3",opacity:"0.5"})]}),a[0]=l):l=a[0],l},E=()=>{const a=e.c(1);let l;return a[0]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsx("div",{className:"absolute inset-0 opacity-10","aria-hidden":"true",children:Array.from({length:8}).map(I)}),a[0]=l):l=a[0],l},M={ml:"w-10 h-10 @[480px]/pitch:w-14 @[480px]/pitch:h-14",lg:"w-14 h-14 @[480px]/pitch:w-18 @[480px]/pitch:h-18"};function j(e,t){const a=[],l=(e,l,o)=>{"boolean"==typeof o?o&&a.push({key:e,text:`${t(e,l)}
2 â`}):null!=o&&o>0&&a.push({key:e,text:t(e,l,{count:o})})};switch(R(e.positionCategory)){case"GK":l("stats.savesShort","{{count}}SV",e.saves),l("stats.cleanSheetShort","CS",e.cleanSheet);break;case"DEF":l("stats.tacklesShort","{{count}}T",e.tackles),l("stats.interceptionsShort","{{count}}I",e.interceptions);break;case"MID":l("stats.keyPassesShort","{{count}}KP",e.keyPasses),l("stats.tacklesShort","{{count}}T",e.tackles);break;default:l("stats.goalsShort","{{count}}G",e.goals),l("stats.assistsShort","{{count}}A",e.assists)}return a.slice(0,2)}const L=a=>{const l=e.c(96),{slot:o,performance:s,t:m,isAverage:d,selected:b,onSelect:x,avatarSize:h}=a,g=void 0!==d&&d,u=void 0!==b&&b,f=void 0===h?"ml":h;if(!s){const e=`${o.x}%`,a=o.y-5+"%";let s,i;l[0]!==e||l[1]!==a?(s={left:e,top:a},l[0]=e,l[1]=a,l[2]=s):s=l[2],l[3]!==o.label||l[4]!==m?(i=y(o.label,m),l[3]=o.label,l[4]=m,l[5]=i):i=l[5];const r=`Empty ${i} slot`;let n;l[6]!==m||l[7]!==r?(n=m("teamOfTheWeek.emptySlot",r),l[6]=m,l[7]=r,l[8]=n):n=l[8];const c=`${M[f]} rounded-full bg-white/20 border border-white/30 flex items-center justify-center`;let d,b,x,p;return l[9]!==o.label||l[10]!==m?(d=y(o.label,m),l[9]=o.label,l[10]=m,l[11]=d):d=l[11],l[12]!==d?(b=t.jsx("span",{className:"text-white/60 text-[9px] sm:text-xs font-bold",children:d}),l[12]=d,l[13]=b):b=l[13],l[14]!==c||l[15]!==b?(x=t.jsx("div",{className:c,children:b}),l[14]=c,l[15]=b,l[16]=x):x=l[16],l[17]!==x||l[18]!==s||l[19]!==n?(p=t.jsx("div",{className:"absolute transform -translate-x-1/2 -translate-y-1/2",style:s,"aria-label":n,children:x}),l[17]=x,l[18]=s,l[19]=n,l[20]=p):p=l[20],p}let F;l[21]!==s.playerId||l[22]!==s.playerSlug?(F=i({id:s.playerId,slug:s.playerSlug}),l[21]=s.playerId,l[22]=s.playerSlug,l[23]=F):F=l[23];const R=`/player/${F}`;let k;l[24]!==o?(k=function(e){const t=e.y>65,a=e.x<25,l=e.x>75,o=t?"bottom-full mb-3":"top-full mt-3";return a?`absolute ${o} left-0`:l?`absolute ${o} right-0`:`absolute ${o} left-1/2 -translate-x-1/2`}(o),l[24]=o,l[25]=k):k=l[25];const D=k;let C;l[26]!==x?(C=e=>{x&&(e.preventDefault(),x())},l[26]=x,l[27]=C):C=l[27];const E="absolute transform -translate-x-1/2 -translate-y-1/2 group z-10 hover:z-20 transition-transform hover:scale-110 no-underline "+(u?"z-30":""),L=`${o.x}%`,N=o.y-5+"%";let v;l[28]!==L||l[29]!==N?(v={left:L,top:N},l[28]=L,l[29]=N,l[30]=v):v=l[30];const P=s.playerName;let B;l[31]!==o.label||l[32]!==m?(B=y(o.label,m),l[31]=o.label,l[32]=m,l[33]=B):B=l[33];const I=s.clubName;let S;l[34]!==s.rating?(S=s.rating.toFixed(1),l[34]=s.rating,l[35]=S):S=l[35];const A=`${P} - ${B} - ${I} - ${S}`,T="relative "+(u?"ring-2 ring-yellow-400 rounded-full":"");let O,_,G,K,$,z,X;l[36]!==s.nationalityFlag?(O=s.nationalityFlag?{src:s.nationalityFlag,alt:"",variant:"flag",position:"top-left"}:null,l[36]=s.nationalityFlag,l[37]=O):O=l[37],l[38]!==s.clubLogo||l[39]!==s.clubName||l[40]!==m?(_=s.clubLogo?{src:s.clubLogo,alt:s.clubName||m("teamOfTheWeek.clubLogo","Club logo"),variant:"logo",position:"top-right"}:null,l[38]=s.clubLogo,l[39]=s.clubName,l[40]=m,l[41]=_):_=l[41],l[42]!==f||l[43]!==s.playerImage||l[44]!==s.playerName||l[45]!==O||l[46]!==_?(G=t.jsx(r,{imageUrl:s.playerImage,altText:s.playerName,size:f,containerName:"pitch",borderClassName:"border-2 border-white/80 shadow-lg",loading:"lazy",secondaryBadge:O,badge:_}),l[42]=f,l[43]=s.playerImage,l[44]=s.playerName,l[45]=O,l[46]=_,l[47]=G):G=l[47],l[48]!==s.rating?(K=t.jsx(p,{score:s.rating,variant:"solid",size:"sm",className:"absolute -bottom-2 left-1/2 -translate-x-1/2 shadow-sm"}),l[48]=s.rating,l[49]=K):K=l[49],l[50]!==s.playerName?($=s.playerName.split(" ").pop(),l[50]=s.playerName,l[51]=$):$=l[51],l[52]!==$?(z=t.jsx("div",{className:"absolute top-full left-1/2 -translate-x-1/2 mt-3 pointer-events-none text-center w-max max-w-14 @[480px]/pitch:max-w-20",children:t.jsx("div",{className:"text-white text-[9px] sm:text-[11px] font-semibold leading-tight drop-shadow-md truncate",children:$})}),l[52]=$,l[53]=z):z=l[53],l[54]!==T||l[55]!==G||l[56]!==K||l[57]!==z?(X=t.jsxs("div",{className:T,children:[G,K,z]}),l[54]=T,l[55]=G,l[56]=K,l[57]=z,l[58]=X):X=l[58];const V=`${D} opacity-0 group-hover:opacity-100 transition-opacity pointer-events-none z-30`;let U,Y,H,Q,Z,q,J,ee,te,ae,le;return l[59]!==s.playerName?(U=t.jsx("span",{className:"font-bold text-sm truncate",children:s.playerName}),l[59]=s.playerName,l[60]=U):U=l[60],l[61]!==s.playerAge?(Y=s.playerAge&&t.jsxs("span",{className:"text-gray-400 text-[11px] shrink-0",children:["(",s.playerAge,")"]}),l[61]=s.playerAge,l[62]=Y):Y=l[62],l[63]!==U||l[64]!==Y?(H=t.jsxs("div",{className:"flex items-center gap-1.5",children:[U,Y]}),l[63]=U,l[64]=Y,l[65]=H):H=l[65],l[66]!==s.clubLogo?(Q=s.clubLogo&&t.jsx("img",{src:n(s.clubLogo,{width:32}),alt:"",className:"w-3.5 h-3.5 object-contain shrink-0"}),l[66]=s.clubLogo,l[67]=Q):Q=l[67],l[68]!==s.clubName?(Z=t.jsx("span",{className:"truncate",children:s.clubName}),l[68]=s.clubName,l[69]=Z):Z=l[69],l[70]!==s.derivedPosition||l[71]!==m?(q=s.derivedPosition&&t.jsxs(t.Fragment,{children:[t.jsx("span",{className:"text-gray-500 shrink-0",children:"·"}),t.jsx("span",{className:"text-amber-400 font-medium shrink-0",children:y(s.derivedPosition,m)})]}),l[70]=s.derivedPosition,l[71]=m,l[72]=q):q=l[72],l[73]!==Q||l[74]!==Z||l[75]!==q?(J=t.jsxs("div",{className:"flex items-center gap-1.5 mt-1 text-gray-300 min-w-0",children:[Q,Z,q]}
2),l[73]=Q,l[74]=Z,l[75]=q,l[76]=J):J=l[76],l[77]!==g||l[78]!==s||l[79]!==m?(ee=g?t.jsxs(t.Fragment,{children:[t.jsx("div",{className:"flex items-center gap-1.5 mt-1.5 text-gray-300 text-[11px]",children:t.jsx("span",{className:"text-amber-400 font-medium",children:m("bestXI.matchesPlayed","{{count}} matches",{count:s.matchCount??1})})}),t.jsxs("div",{className:"flex items-center gap-2.5 mt-1.5 pt-1.5 border-t border-white/10 text-[11px]",children:[t.jsxs("div",{className:"flex items-center gap-1",children:[t.jsx("span",{className:"text-gray-500",children:m("bestXI.avgRating","AVG")}),t.jsx("span",{className:"font-bold "+(s.rating>=8?"text-green-400":s.rating>=7?"text-lime-400":"text-yellow-400"),children:s.rating.toFixed(2)})]}),j(s,m).map(w),t.jsxs("div",{className:"flex items-center gap-1",children:[t.jsx("span",{className:"text-gray-500",children:m("teamOfTheWeek.minutesShort","MIN")}),t.jsxs("span",{className:"font-bold",children:[s.minutesPlayed,"'"]})]})]})]}):t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"flex items-center gap-1.5 mt-1.5 text-gray-300 min-w-0",children:[t.jsx("span",{className:"text-gray-500 shrink-0",children:m("teamOfTheWeek.vs","vs")}),s.opponentClubLogo&&t.jsx("img",{src:n(s.opponentClubLogo,{width:32}),alt:"",className:"w-3.5 h-3.5 object-contain shrink-0"}),t.jsx("span",{className:"truncate",children:s.opponentClubName}),null!=s.teamScore&&null!=s.opponentScore&&t.jsx("span",{className:"font-bold shrink-0 "+("win"===s.matchResult?"text-green-400":"loss"===s.matchResult?"text-red-400":"text-gray-400"),children:s.isHome?`${s.teamScore}-${s.opponentScore}`:`${s.opponentScore}-${s.teamScore}`})]}),t.jsxs("div",{className:"flex items-center gap-2.5 mt-1.5 pt-1.5 border-t border-white/10 text-[11px]",children:[t.jsxs("div",{className:"flex items-center gap-1",children:[t.jsx("span",{className:"text-gray-500",children:m("teamOfTheWeek.ratingShort","RAT")}),t.jsx("span",{className:"font-bold "+(s.rating>=8?"text-green-400":s.rating>=7?"text-lime-400":"text-yellow-400"),children:s.rating.toFixed(1)})]}),j(s,m).map(W),t.jsxs("div",{className:"flex items-center gap-1",children:[t.jsx("span",{className:"text-gray-500",children:m("teamOfTheWeek.minutesShort","MIN")}),t.jsxs("span",{className:"font-bold",children:[s.minutesPlayed,"'"]})]})]}),s.competitionName&&t.jsxs("div",{className:"flex items-center gap-1.5 mt-1.5 text-[11px] text-gray-400",children:[s.competitionLogo&&t.jsx("img",{src:n(s.competitionLogo,{width:16}),alt:"",className:"w-3 h-3 object-contain"}),t.jsx("span",{children:s.competitionName})]})]}),l[77]=g,l[78]=s,l[79]=m,l[80]=ee):ee=l[80],l[81]!==H||l[82]!==J||l[83]!==ee?(te=t.jsxs("div",{className:"bg-gray-900/95 text-white text-xs px-3 py-2.5 rounded-lg shadow-xl w-48 sm:w-52",children:[H,J,ee]}),l[81]=H,l[82]=J,l[83]=ee,l[84]=te):te=l[84],l[85]!==V||l[86]!==te?(ae=t.jsx("div",{className:V,children:te}),l[85]=V,l[86]=te,l[87]=ae):ae=l[87],l[88]!==R||l[89]!==v||l[90]!==A||l[91]!==X||l[92]!==ae||l[93]!==C||l[94]!==E?(le=t.jsxs(c,{to:R,onClick:C,className:E,style:v,"aria-label":A,children:[X,ae]}),l[88]=R,l[89]=v,l[90]=A,l[91]=X,l[92]=ae,l[93]=C,l[94]=E,l[95]=le):le=l[95],le},N=a=>{const l=e.c(9),{value:o,onChange:s,compact:i}=a,r=void 0!==i&&i,{t:n}=g();let c;l[0]===Symbol.for("react.memo_cache_sentinel")?(c=D.map(S),l[0]=c):c=l[0];const m=r?void 0:"w-full",d=r?void 0:"w-full justify-between min-h-11";let b,x;return l[1]!==n?(b=n("teamOfTheWeek.selectFormation","Select formation"),l[1]=n,l[2]=b):b=l[2],l[3]!==s||l[4]!==m||l[5]!==d||l[6]!==b||l[7]!==o?(x=t.jsx(h,{value:o,options:c,onChange:s,width:m,variant:"outline",triggerClassName:d,ariaLabel:b}),l[3]=s,l[4]=m,l[5]=d,l[6]=b,l[7]=o,l[8]=x):x=l[8],x};function v(a){const l=e.c(10),{formation:o,avatarSize:s}=a,i=void 0===s?"ml":s,{t:r}=g(),n=k[o];let c,m,d,b,x;return l[0]!==r?(c=r("bestXI.loading","Loading best XI"),l[0]=r,l[1]=c):c=l[1],l[2]===Symbol.for("react.memo_cache_sentinel")?(m=t.jsx(E,{}),d=t.jsx(C,{}),l[2]=m,l[3]=d):(m=l[2],d=l[3]),l[4]!==i||l[5]!==n?.slots?(b=n?.slots.map((e,a)=>t.jsxs("div",{className:"absolute transform -translate-x-1/2 -translate-y-1/2 animate-pulse",style:{left:`${e.x}%`,top:e.y-5+"%"},children:[t.jsx("div",{className:`${M[i]} rounded-full bg-white/15 border border-white/20`}),t.jsx("div",{className:"text-center mt-3.5",children:t.jsx("div",{className:"h-3 w-12 mx-auto rounded bg-white/15"})})]},a)),l[4]=i,l[5]=n?.slots,l[6]=b):b=l[6],l[7]!==c||l[8]!==b?(x=t.jsxs("div",{className:"@container/pitch relative aspect-3/4 bg-linear-to-b from-emerald-600 to-emerald-700 dark:from-emerald-800 dark:to-emerald-900 rounded-xl overflow-hidden",role:"status","aria-label":c,children:[m,d,b]}),l[7]=c,l[8]=b,l[9]=x):x=l[9],x}function P(a){const l=e.c(39),{performances:o,formation:i,loading:r,error:n,isAverage:c,selectedIdx:m,onSelectIdx:d,avatarSize:b}=a,x=void 0!==c&&c,p=void 0===b?"ml":b,{t:y}=g(),h=k[i];let f;l[0]!==i||l[1]!==o?(f=function(e,t){const a=k[t];if(!a)return Array(11).fill(null);const{slots:l}=a,o=new Array(l.length).fill(null),s=new Set,i=[...l.map((t,a)=>({idx:a,count:e.filter(e=>e.derivedPosition&&t.compatiblePositions.includes(e.derivedPosition)).length}))].sort((e,t)=>
2e.count-t.count);for(const{idx:r}of i){const t=l[r];let a=null;for(const l of e)s.has(l.playerId)||l.derivedPosition&&t.compatiblePositions.includes(l.derivedPosition)&&(!a||l.rating>a.rating)&&(a=l);a&&(s.add(a.playerId),o[r]=a)}for(const{idx:r}of i){if(o[r])continue;const t=l[r];let a=null;for(const l of e)s.has(l.playerId)||l.positionCategory===t.categoryFallback&&(!a||l.rating>a.rating)&&(a=l);a&&(s.add(a.playerId),o[r]=a)}return o}(o,i),l[0]=i,l[1]=o,l[2]=f):f=l[2];const F=f,R=o.length>0;let D;l[3]!==F?(D=F.filter(Boolean),l[3]=F,l[4]=D):D=l[4];const M=D.length,j="@container/pitch relative aspect-3/4 bg-linear-to-b from-emerald-600 to-emerald-700 dark:from-emerald-800 dark:to-emerald-900 rounded-xl overflow-hidden "+(r&&!R?"opacity-50":"");let N,v,P,B,I,w,W,S,A;return l[5]!==y?(N=y("teamOfTheWeek.pitchLabel","Football pitch showing best XI"),l[5]=y,l[6]=N):N=l[6],l[7]===Symbol.for("react.memo_cache_sentinel")?(v=t.jsx(E,{}),P=t.jsx(C,{}),l[7]=v,l[8]=P):(v=l[7],P=l[8]),l[9]!==R||l[10]!==r||l[11]!==y?(B=r&&!R&&t.jsx("div",{className:"absolute inset-0 flex items-center justify-center z-20",role:"status","aria-label":y("bestXI.loading","Loading best XI"),children:t.jsx("div",{className:"w-6 h-6 border-2 border-white border-t-transparent rounded-full animate-spin"})}),l[9]=R,l[10]=r,l[11]=y,l[12]=B):B=l[12],l[13]!==p||l[14]!==F||l[15]!==i||l[16]!==h||l[17]!==x||l[18]!==d||l[19]!==m||l[20]!==y?(I=h&&F.map((e,a)=>t.jsx(L,{slot:h.slots[a],performance:e,t:y,isAverage:x,selected:m===a,onSelect:d?()=>d(a):void 0,avatarSize:p},`${i}-${a}`)),l[13]=p,l[14]=F,l[15]=i,l[16]=h,l[17]=x,l[18]=d,l[19]=m,l[20]=y,l[21]=I):I=l[21],l[22]!==M||l[23]!==r||l[24]!==y?(w=!r&&0===M&&t.jsx("div",{className:"absolute inset-0 flex items-center justify-center z-20",children:t.jsxs("div",{className:"text-center text-white/80 px-4",children:[t.jsx(u,{className:"w-8 h-8 mx-auto mb-2 opacity-50"}),t.jsx("p",{className:"text-sm font-medium",children:y("teamOfTheWeek.noData","No performances available for this period")})]})}),l[22]=M,l[23]=r,l[24]=y,l[25]=w):w=l[25],l[26]!==I||l[27]!==w||l[28]!==j||l[29]!==N||l[30]!==B?(W=t.jsxs("div",{className:j,role:"img","aria-label":N,children:[v,P,B,I,w]}),l[26]=I,l[27]=w,l[28]=j,l[29]=N,l[30]=B,l[31]=W):W=l[31],l[32]!==n||l[33]!==r||l[34]!==y?(S=n&&!r&&t.jsx("div",{className:`mt-2 text-center text-sm ${s.colors.error.text}`,children:y("teamOfTheWeek.error","Failed to load best XI")}),l[32]=n,l[33]=r,l[34]=y,l[35]=S):S=l[35],l[36]!==W||l[37]!==S?(A=t.jsxs(t.Fragment,{children:[W,S]}),l[36]=W,l[37]=S,l[38]=A):A=l[38],A}function B(e){const t=k[e];if(!t)return[];const a=new Set;for(const l of t.slots)for(const e of l.compatiblePositions)a.add(e);return Array.from(a)}function I(e,a){return t.jsx("div",{className:"h-1/8 "+(a%2==0?"bg-white":"bg-transparent")},a)}function w(e){return t.jsx("div",{className:"flex items-center gap-1",children:t.jsx("span",{className:"font-bold",children:e.text})},e.key)}function W(e){return t.jsx("div",{className:"flex items-center gap-1",children:t.jsx("span",{className:"font-bold",children:e.text})},e.key)}function S(e){return{value:e,label:e}}const A=Object.freeze(Object.defineProperty({__proto__:null,BestXIPitch:P,BestXIPitchSkeleton:v,FormationSelector:N,PlayerMarker:L,default:function(){const l=e.c(33),{t:o}=g(),s=b(),[i,r]=a.useState("4-2-3-1"),[n,m]=a.useState(null);let p;l[0]===Symbol.for("react.memo_cache_sentinel")?(p=e=>{m(e)},l[0]=p):p=l[0];const y=p;let h;l[1]!==n?(h={selected:n,onChange:y},l[1]=n,l[2]=h):h=l[2];const R=h;let k;d(),l[3]!==i?(k=B(i),l[3]=i,l[4]=k):k=l[4];const D=k,C=n??void 0;let E;l[5]!==D||l[6]!==C?(E={derivedPositions:D,days:7,competitionId:C,minMinutes:45},l[5]=D,l[6]=C,l[7]=E):E=l[7];const{performances:M,loading:j,error:L}=F(E);let v,I,w,W,S,A,T,O,_;return l[8]!==s||l[9]!==o?(v=!s&&t.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[t.jsx("div",{className:"p-1.5 rounded-lg bg-amber-100 dark:bg-amber-900/30",children:t.jsx(u,{className:"w-5 h-5 text-amber-600 dark:text-amber-400"})}),t.jsx("h3",{className:"text-lg font-bold text-gray-900 dark:text-white",children:o("teamOfTheWeek.title","Best XI")})]}),l[8]=s,l[9]=o,l[10]=v):v=l[10],l[11]!==R?(I=t.jsx("div",{className:"flex-1 min-w-0 overflow-x-auto scrollbar-hide",children:t.jsx(x,{competitionFilter:R})}),l[11]=R,l[12]=I):I=l[12],l[13]!==i?(w=t.jsx(N,{value:i,onChange:r}),l[13]=i,l[14]=w):w=l[14],l[15]!==I||l[16]!==w?(W=t.jsxs("div",{className:"flex items-center justify-between gap-2 mb-3",children:[I,w]}),l[15]=I,l[16]=w,l[17]=W):W=l[17],l[18]!==L||l[19]!==i||l[20]!==j||l[21]!==M?(S=t.jsx(P,{performances:M,formation:i,loading:j,error:L}),l[18]=L,l[19]=i,l[20]=j,l[21]=M,l[22]=S):S=l[22],l[23]!==o?(A=o("teamOfTheWeek.viewAll","View All"),l[23]=o,l[24]=A):A=l[24],l[25]===Symbol.for("react.memo_cache_sentinel")?(T=t.jsx(f,{className:"w-3.5 h-3.5 -rotate-90"}
2),l[25]=T):T=l[25],l[26]!==A?(O=t.jsx("div",{className:"mt-3 text-center",children:t.jsxs(c,{to:"/best-xi",className:"inline-flex items-center gap-1.5 text-xs font-medium text-primary-600 dark:text-primary-400 hover:text-primary-700 dark:hover:text-primary-300 no-underline",children:[A,T]})}),l[26]=A,l[27]=O):O=l[27],l[28]!==O||l[29]!==v||l[30]!==W||l[31]!==S?(_=t.jsxs("div",{className:"p-3 sm:p-4",children:[v,W,S,O]}),l[28]=O,l[29]=v,l[30]=W,l[31]=S,l[32]=_):_=l[32],_},getFormationPositions:B},Symbol.toStringTag,{value:"Module"}));export{v as B,N as F,A as T,k as a,P as b,B as g,R as n,F as u};
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.