PageSourceSearch

https://www.sportsido.com/_next/static/chunks/26507-3967c9dcc28f3813.js

js sportsido.com collected 2026-09-24 14:56:03 UTC 51,502 bytes, 1 lines download raw bytes

1!function(){try{var l="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new l.Error).stack;n&&(l._sentryDebugIds=l._sentryDebugIds||{},l._sentryDebugIds[n]="ee521e19-cd7c-4c0f-9410-f499af648fc2",l._sentryDebugIdIdentifier="sentry-dbid-ee521e19-cd7c-4c0f-9410-f499af648fc2")}catch(l){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[26507],{580:(l,n,e)=>{e.d(n,{p:()=>i});var t=e(25398),u=e(5998),r=e(35956);let i=()=>{let l=(0,u.k)(),{toggleConfirmModal:n}=(0,r.f)(),e=(0,t.useCallback)((e,t)=>{n(e,void 0,{title:t.title,subtitle:t.subtitle,confirmButtonText:t.confirmButtonText,cancelButtonText:l("common.cancel")})},[n,l]),i=(0,t.useCallback)(n=>e(n,{title:l("matches.confirmation.confirmDialogTitle"),subtitle:l("matches.confirmation.confirmDialogSubtitle"),confirmButtonText:l("matches.confirmation.confirm")}),[e,l]);return{promptConfirmScore:i,promptDeclineScore:(0,t.useCallback)(n=>e(n,{title:l("matches.confirmation.declineDialogTitle"),subtitle:l("matches.confirmation.declineDialogSubtitle"),confirmButtonText:l("matches.confirmation.decline")}),[e,l]),promptWithdrawScore:(0,t.useCallback)(n=>e(n,{title:l("matches.confirmation.withdrawDialogTitle"),subtitle:l("matches.confirmation.withdrawDialogSubtitle"),confirmButtonText:l("matches.confirmation.withdraw")}),[e,l])}}},5263:(l,n,e)=>{e.d(n,{Br:()=>r,f0:()=>u,oJ:()=>t});let t=l=>{if(null!=l)return Array.isArray(l)?l[0]:l},u=l=>{var n;return null==l?[]:Array.isArray(l)?l:null!=(n=l.users)?n:[]},r=l=>u(l).length>0},15992:(l,n,e)=>{e.d(n,{LC:()=>f,ru:()=>y,L3:()=>g,ZN:()=>w,vC:()=>v,oD:()=>d});var t=e(87350);let u=l=>(null==l?void 0:l.type)==="double-elimination-advanced"||(null==l?void 0:l.type)==="play-each-place"||(null==l?void 0:l.type)==="double-elimination",r=(l,n)=>{var e;let t=null!=(e=null==l?void 0:l.findIndex(l=>(null==l?void 0:l.id)===n))?e:-1,u=Math.trunc(t/2);return{byeTeam:Math.floor(t/2)===t/2?"team1":"team2",byeSeedIndex:u}},i=l=>{var n;return null!=(n=null==l?void 0:l.id)?n:null==l?void 0:l.registrationRequestId},a=(l,n,e,a,d,o,s,m)=>{var c,v,p,y,f,g,w,h,I,b,C,S,R,k,T,A,x,D,E,U,M,L,P,N,O,j,q,W,F,z,_,Q,Z,B,G,H,J,$,K,V,Y,X,ll,ln,le,lt,lu,lr,li,la,ld,lo,ls,lm,lc,lv,lp,ly,lf,lg,lw,lh,lI,lb,lC,lS,lR,lk,lT,lA,lx,lD,lE,lU,lM,lL,lP,lN,lO,lj,lq,lW,lF,lz,l_,lQ,lZ,lB,lG,lH,lJ,l$,lK,lV,lY,lX,l0,l1,l2,l3,l4,l5,l9,l6,l7,l8,nl,nn,ne,nt,nu,nr,ni,na,nd,no,ns,nm,nc,nv,np,ny,nf,ng,nw,nh,nI,nb,nC,nS,nR,nk,nT,nA,nx,nD,nE,nU,nM,nL,nP,nN,nO,nj,nq,nW,nF,nz,n_,nQ,nZ,nB,nG,nH,nJ,n$,nK,nV,nY,nX,n0,n1,n2,n3,n4,n5,n9,n6,n7,n8,el,en,ee,et,eu,er,ei,ea,ed,eo,es,em,ec,ev,ep,ey,ef,eg,ew,eh,eI,eb,eC,eS,eR,ek,eT,eA,ex,eD,eE,eU,eM,eL,eP,eN,eO,ej,eq,eW,eF,ez,e_,eQ,eZ,eB,eG,eH,eJ,e$,eK,eV,eY,eX,e0,e1,e2,e3,e4,e5,e9,e6,e7,e8,tl,tn,te,tt,tu,tr,ti,ta,td,to,ts,tm,tc,tv,tp,ty,tf,tg,tw,th,tI,tb,tC,tS,tR,tk,tT,tA,tx,tD,tE,tU,tM,tL,tP,tN,tO,tj,tq,tW,tF,tz,t_,tQ,tZ,tB,tG,tH,tJ,t$,tK,tV,tY,tX,t0,t1,t2,t3,t4,t5,t9,t6,t7,t8,ul,un,ue,ut,uu,ur,ui,ua,ud,uo,us,um;let uc=Math.trunc(l/2),uv=null!=(I=null==(v=d[n])||null==(c=v.seeds)?void 0:c.length)?I:0,up=n===(null==d?void 0:d.length)-1,uy=Number(null==(f=d[n+1])||null==(y=f.seeds)||null==(p=y[uc])?void 0:p.id),uf=Math.floor(l/2)===l/2?"team1":"team2",ug=null,uw=null,uh=null,uI=null,ub=null,uC=null,uS=null,uR=null,uk=null,uT=null,uA=!1,ux=!1,uD=null,uE=u(e)&&0===n&&o&&(null==(g=d[n])?void 0:g.seeds)&&(()=>{var e,t,u,r,i,a;let s=l%2==0?l+1:l-1,m=null==(t=d[n])||null==(e=t.seeds)?void 0:e[s],c=!(null==o||null==(u=o.entry1)?void 0:u.id)||!(null==o||null==(r=o.entry2)?void 0:r.id),v=!(null==m||null==(i=m.entry1)?void 0:i.id)||!(null==m||null==(a=m.entry2)?void 0:a.id);return c||v})();if((null==e?void 0:e.type)==="double-elimination"&&(null==o?void 0:o.bracketType)==="main"){let l=null==e||null==(b=e.brackets)?void 0:b.find(l=>{var n,e,t;return(null==l||null==(t=l.rounds)||null==(e=t[0])||null==(n=e.seeds)?void 0:n.length)===uv/2});uw=null!=(M=null==l||null==(k=l.rounds)||null==(R=k[0])||null==(S=R.seeds)||null==(C=S[uc])?void 0:C.id)?M:null;let{byeTeam:n,byeSeedIndex:t}=r(null!=(L=null==l||null==(A=l.rounds)||null==(T=A[0])?void 0:T.seeds)?L:[],uw);uC=null!=(P=null==l||null==(U=l.rounds)||null==(E=U[1])||null==(D=E.seeds)||null==(x=D[t])?void 0:x.id)?P:null,ug=n}else if((null==e?void 0:e.type)==="double-elimination-advanced"&&(null==o?void 0:o.bracketType)==="upper"&&0===n)uw=null!=(H=null==e||null==(F=e.brackets)||null==(W=F[1])||null==(q=W.rounds)||null==(j=q[0])||null==(O=j.seeds)||null==(N=O[uc])?void 0:N.id)?H:null,ug=uf,uC=null!=(J=null==e||null==(G=e.brackets)||null==(B=G[1])||null==(Z=B.rounds)||null==(Q=Z[1])||null==(_=Q.seeds)||null==(z=_[uc])?void 0:z.id)?J:null;else if((null==e?void 0:e.type)==="double-elimination-advanced"&&(null==o?void 0:o.bracketType)==="upper"&&0!==n&&((null==e?void 0:e.size)===32&&1!==n||(null==e?void 0:e.size)!==32)){let u=1+(n-1)*2;ug="team1";let r=null==e||null==(Y=e.brackets)||null==(V=Y[1])||null==(K=V.rounds)||null==($=K[u])?void 0:$.seeds,i=r?(0,t.cloneDeep)(r).reverse():[];uw=n%2!=1||up?null!=(lv=null==e||null==(lr=e.brackets)||null==(lu=lr[1])||null==(lt=lu.rounds)||null==(le=lt[u])||null==(ln=le.seeds)||null==(ll=ln[l])?void 0:ll.id)?lv:null:null!=(lc=null==i||null==(X=i[l])?void 0:X.id)?lc:null,uI=up&&null!=(lp=null==e||null==(lm=e.brackets)||null==(ls=lm[2])||null==(lo=ls.rounds)||null==(ld=lo[0])||null==(la=ld.seeds)||null==(li=la[0])?void 0:li.id)?lp:null,ub=up?"team1":null}else if((null==e?void 0:e.type)==="double-elimination-advanced"&&(null==o?void 0:o.bracketType)==="upper"&&(null==e?void 0:e.size)===32&&1===n){ug="team1";let t=null!=(lI=null==e||null==(lw=e.brackets)||null==(lg=lw[1])||null==(lf=lg.rounds)||null==(ly=lf[1+(n-1)*2])?void 0:ly.seeds)?lI:[],u=[...t.slice(4),...t.slice(0,4)];uw=null!=(lb=null==u||null==(lh=u[l])?void 0:lh.id)?lb:null}else if((null==e?void 0:e.type)==="double-elimination-advanced"&&(null==o?void 0:o.bracketType)==="lower")uv===(null==e||null==(lT=e.brackets)||null==(lk=lT[1])||null==(lR=lk.roun
1ds)||null==(lS=lR[n+1])||null==(lC=lS.seeds)?void 0:lC.length)&&(uf="team2",uy=null!=(lW=null==e||null==(lq=e.brackets)||null==(lj=lq[1])||null==(lO=lj.rounds)||null==(lN=lO[n+1])||null==(lP=lN.seeds)||null==(lL=lP[l])?void 0:lL.id)?lW:0),uI=up&&null!=(lF=null==e||null==(lM=e.brackets)||null==(lU=lM[2])||null==(lE=lU.rounds)||null==(lD=lE[0])||null==(lx=lD.seeds)||null==(lA=lx[0])?void 0:lA.id)?lF:null,ub=up?"team2":null;else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="main"&&(null==e?void 0:e.size)===8&&0===n){uh=null!=(l3=null==e||null==(lG=e.brackets)||null==(lB=lG[1])||null==(lZ=lB.rounds)||null==(lQ=lZ[0])||null==(l_=lQ.seeds)||null==(lz=l_[uc])?void 0:lz.id)?l3:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(l4=null==e||null==(lK=e.brackets)||null==(l$=lK[1])||null==(lJ=l$.rounds)||null==(lH=lJ[0])?void 0:lH.seeds)?l4:[],uh);ug=l,uC=null!=(l5=null==e||null==(l2=e.brackets)||null==(l1=l2[1])||null==(l0=l1.rounds)||null==(lX=l0[1])||null==(lY=lX.seeds)||null==(lV=lY[n])?void 0:lV.id)?l5:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="main"&&(null==e?void 0:e.size)===16&&0===n){uh=null!=(nc=null==e||null==(nn=e.brackets)||null==(nl=nn[2])||null==(l8=nl.rounds)||null==(l7=l8[0])||null==(l6=l7.seeds)||null==(l9=l6[uc])?void 0:l9.id)?nc:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(nv=null==e||null==(nr=e.brackets)||null==(nu=nr[2])||null==(nt=nu.rounds)||null==(ne=nt[0])?void 0:ne.seeds)?nv:[],uh);ug=l,uC=null!=(np=null==e||null==(nm=e.brackets)||null==(ns=nm[2])||null==(no=ns.rounds)||null==(nd=no[1])||null==(na=nd.seeds)||null==(ni=na[n])?void 0:ni.id)?np:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="main"&&(null==e?void 0:e.size)===16&&1===n){uh=null!=(nU=null==e||null==(nI=e.brackets)||null==(nh=nI[1])||null==(nw=nh.rounds)||null==(ng=nw[0])||null==(nf=ng.seeds)||null==(ny=nf[uc])?void 0:ny.id)?nU:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(nM=null==e||null==(nR=e.brackets)||null==(nS=nR[1])||null==(nC=nS.rounds)||null==(nb=nC[0])?void 0:nb.seeds)?nM:[],uh);ug=l,uC=null!=(nL=null==e||null==(nE=e.brackets)||null==(nD=nE[1])||null==(nx=nD.rounds)||null==(nA=nx[1])||null==(nT=nA.seeds)||null==(nk=nT[n])?void 0:nk.id)?nL:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="9-16"&&(null==e?void 0:e.size)===16&&0===n){uh=null!=(nK=null==e||null==(nW=e.brackets)||null==(nq=nW[3])||null==(nj=nq.rounds)||null==(nO=nj[0])||null==(nN=nO.seeds)||null==(nP=nN[uc])?void 0:nP.id)?nK:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(nV=null==e||null==(nQ=e.brackets)||null==(n_=nQ[3])||null==(nz=n_.rounds)||null==(nF=nz[0])?void 0:nF.seeds)?nV:[],uh);ug=l,uC=null!=(nY=null==e||null==(n$=e.brackets)||null==(nJ=n$[2])||null==(nH=nJ.rounds)||null==(nG=nH[1])||null==(nB=nG.seeds)||null==(nZ=nB[n])?void 0:nZ.id)?nY:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="main"&&(null==e?void 0:e.size)===32&&0===n){uh=null!=(er=null==e||null==(n4=e.brackets)||null==(n3=n4[4])||null==(n2=n3.rounds)||null==(n1=n2[0])||null==(n0=n1.seeds)||null==(nX=n0[uc])?void 0:nX.id)?er:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(ei=null==e||null==(n7=e.brackets)||null==(n6=n7[4])||null==(n9=n6.rounds)||null==(n5=n9[0])?void 0:n5.seeds)?ei:[],uh);ug=l,uC=null!=(ea=null==e||null==(eu=e.brackets)||null==(et=eu[4])||null==(ee=et.rounds)||null==(en=ee[1])||null==(el=en.seeds)||null==(n8=el[n])?void 0:n8.id)?ea:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="main"&&(null==e?void 0:e.size)===32&&1===n){uh=null!=(eR=null==e||null==(ev=e.brackets)||null==(ec=ev[2])||null==(em=ec.rounds)||null==(es=em[0])||null==(eo=es.seeds)||null==(ed=eo[uc])?void 0:ed.id)?eR:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(ek=null==e||null==(eg=e.brackets)||null==(ef=eg[2])||null==(ey=ef.rounds)||null==(ep=ey[0])?void 0:ep.seeds)?ek:[],uh);ug=l,uC=null!=(eT=null==e||null==(eS=e.brackets)||null==(eC=eS[2])||null==(eb=eC.rounds)||null==(eI=eb[1])||null==(eh=eI.seeds)||null==(ew=eh[n])?void 0:e
1w.id)?eT:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="main"&&(null==e?void 0:e.size)===32&&2===n){uh=null!=(eQ=null==e||null==(eM=e.brackets)||null==(eU=eM[1])||null==(eE=eU.rounds)||null==(eD=eE[0])||null==(ex=eD.seeds)||null==(eA=ex[uc])?void 0:eA.id)?eQ:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(eZ=null==e||null==(eO=e.brackets)||null==(eN=eO[1])||null==(eP=eN.rounds)||null==(eL=eP[0])?void 0:eL.seeds)?eZ:[],uh);ug=l,uC=null!=(eB=null==e||null==(e_=e.brackets)||null==(ez=e_[1])||null==(eF=ez.rounds)||null==(eW=eF[1])||null==(eq=eW.seeds)||null==(ej=eq[n])?void 0:ej.id)?eB:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="9-16"&&(null==e?void 0:e.size)===32&&0===n){uh=null!=(e7=null==e||null==(eV=e.brackets)||null==(eK=eV[3])||null==(e$=eK.rounds)||null==(eJ=e$[0])||null==(eH=eJ.seeds)||null==(eG=eH[uc])?void 0:eG.id)?e7:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(e8=null==e||null==(e1=e.brackets)||null==(e0=e1[3])||null==(eX=e0.rounds)||null==(eY=eX[0])?void 0:eY.seeds)?e8:[],uh);ug=l,uC=null!=(tl=null==e||null==(e6=e.brackets)||null==(e9=e6[3])||null==(e5=e9.rounds)||null==(e4=e5[1])||null==(e3=e4.seeds)||null==(e2=e3[n])?void 0:e2.id)?tl:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="17-32"&&(null==e?void 0:e.size)===32&&0===n){uh=null!=(tg=null==e||null==(ti=e.brackets)||null==(tr=ti[6])||null==(tu=tr.rounds)||null==(tt=tu[0])||null==(te=tt.seeds)||null==(tn=te[uc])?void 0:tn.id)?tg:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(tw=null==e||null==(ts=e.brackets)||null==(to=ts[6])||null==(td=to.rounds)||null==(ta=td[0])?void 0:ta.seeds)?tw:[],uh);ug=l,uC=null!=(th=null==e||null==(tf=e.brackets)||null==(ty=tf[6])||null==(tp=ty.rounds)||null==(tv=tp[1])||null==(tc=tv.seeds)||null==(tm=tc[n])?void 0:tm.id)?th:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="17-32"&&(null==e?void 0:e.size)===32&&1===n){uh=null!=(tO=null==e||null==(tk=e.brackets)||null==(tR=tk[5])||null==(tS=tR.rounds)||null==(tC=tS[0])||null==(tb=tC.seeds)||null==(tI=tb[uc])?void 0:tI.id)?tO:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(tj=null==e||null==(tD=e.brackets)||null==(tx=tD[5])||null==(tA=tx.rounds)||null==(tT=tA[0])?void 0:tT.seeds)?tj:[],uh);ug=l,uC=null!=(tq=null==e||null==(tN=e.brackets)||null==(tP=tN[5])||null==(tL=tP.rounds)||null==(tM=tL[1])||null==(tU=tM.seeds)||null==(tE=tU[n])?void 0:tE.id)?tq:null}else if((null==e?void 0:e.type)==="play-each-place"&&(null==o?void 0:o.bracketType)==="25-32"&&(null==e?void 0:e.size)===32&&0===n){uh=null!=(t1=null==e||null==(tZ=e.brackets)||null==(tQ=tZ[7])||null==(t_=tQ.rounds)||null==(tz=t_[0])||null==(tF=tz.seeds)||null==(tW=tF[uc])?void 0:tW.id)?t1:null;let{byeTeam:l,byeSeedIndex:n}=r(null!=(t2=null==e||null==(tJ=e.brackets)||null==(tH=tJ[7])||null==(tG=tH.rounds)||null==(tB=tG[0])?void 0:tB.seeds)?t2:[],uh);ug=l,uC=null!=(t3=null==e||null==(t0=e.brackets)||null==(tX=t0[7])||null==(tY=tX.rounds)||null==(tV=tY[1])||null==(tK=tV.seeds)||null==(t$=tK[n])?void 0:t$.id)?t3:null}if((null==e?void 0:e.isFirstMatchLosersToConsolationDraw)&&m){let e=null!=(t8=null==(t5=m.rounds)||null==(t4=t5[0])?void 0:t4.seeds)?t8:[],t=null!=(ul=null==(t6=m.rounds)||null==(t9=t6[1])?void 0:t9.seeds)?ul:[],u=null!=(un=null==d||null==(t7=d[0])?void 0:t7.seeds)?un:[],r=i(null==o?void 0:o.entry1),a=i(null==o?void 0:o.entry2),s=!!r&&!!a,c=l=>l&&0!==n?u.findIndex(n=>(i(null==n?void 0:n.entry1)===l||i(null==n?void 0:n.entry2)===l)&&(!i(null==n?void 0:n.entry1)||!i(null==n?void 0:n.entry2))):-1,v=l=>{var n;return{seedId:null==(n=e[Math.floor(l/2)])?void 0:n.id,seedIndex:Math.floor(l/2),team:l%2==0?"team1":"team2"}},p=l=>{var n;return{seedId:null==(n=t[Math.floor(l/2)])?void 0:n.id,team:l%2==0?"team1":"team2"}},y=c(r),f=c(a);uA=y>=0,ux=f>=0;let g=0===n&&!uE||uA,w=0===n&&!uE||ux;if(e.length&&s&&(g||w)){if(0===n){let n=v(l);uS=null!=(ue=n.seedId)?ue:null,uR=null!=(ut=n.team)?ut:null}else if(1===n&&uA&&ux){let l=v(y),n=v(f);if(uS=null!=(uu=l.seedId)?uu:null,uk=null!=(ur=l.team)?ur:null,uT=null!=(ui=n.team)?ui:null,uR=uk,t.length&&l.seedId){let n=p(l.seedIndex);uD={fmlcSeedId:l.seedId,singleEntryId:null,nextSeedId:null!=(ua=n.seedId)?ua:0,nextTeam:n.team}}}else if(1===n&&(uA||ux)){let l=v(uA?y:f);if(t.length&&null!=l.seedId&&(l=>{var n,t;let u=e[l];return!!u&&(!(null==u||null==(n=u.entry2)?void 0:n.id)||!(null==u||null==(t=u.entry1)?void 0:t.id))})(l.seedIndex)){let n=p(l.seedIndex);uS=null!=(ud=n.seedId)?ud:null,uR=null!=(uo=n.team)?uo:null;let t=(l=>{var n,t;let u=e[l];if(!u)return null;let r=!(null==u||null==(n=u.entry1)?void 0:n.id)&&(null==u||null==(t=u.entry2)?void 0:t.id)?null==u?void 0:u.entry2:null==u?void 0:u.entry1;return(null==r?void 0:r.id)?{entryId:r.id,fmlcSeedId:u.id}:null})(l.seedIndex);(null==t?void 0:t.fmlcSeedId)!=null&&(uD={fmlcSeedId:t.fmlcSeedId,singleEntryId:t.entryId,nextSeedId:null!=(us=n.seedId)?us:0,nextTeam:n.team})}else null!=l.seedId&&(uS=l.seedId,uR=l.team)}}}let uU=up&&[2,4,8,16,24,32,64].includes(null!=(um=null==(h=d[n])||null==(w=h.seeds)?void 0:w.length)?um:0)&&(null==e?void 0:e.type)!=="double-elimination-advanced";return{nextSeedID:uy,doubleEliminationNextSeedID:uw,grandFinalSeedID:uI,team:uf,doubleEliminationTeam:ug,grandFinalTeam:ub,isLastRound:up,nextSeedIndex:uc,isQualRound:uU,playEachPlaceNextSeedID:uh,isBye:uE,byeNextSeedID:uC,fmlcNextSeedID:uS,fmlcTeam:uR,entry1FmlcTeam:uk,entry2FmlcTeam:uT,entry1HadBye:uA,entry2HadBye:ux,fmlcAdvanceSingleEntry:uD}},d=l=>{var n;return(null==l||null==(n=l.lowerPlaceMatch)?void 0:n.id)?l.lowerPlaceMatch:null},o=(l,n)=>{for(let u=0;u<l.length;u+=1){var e,t;let r=(null!=(t=null==(e=l[u])?void 0:e.seeds)?t:[]).findIndex(l=>(null==l?void 0:l.id)===n);if(-1!==r)return{roundIndex:u,seedIndex:r}}return null},s=l=>{if(!l)return null;let n=l.toLowerCase();return/(?:^|\s|m[-_]?)(2)(?:\s|$)/.test(n)||n.includes("m2")?"team2":/(?
1:^|\s|m[-_]?)(1)(?:\s|$)/.test(n)||n.includes("m1")?"team1":null},m=(l,n,e)=>{let t=null==l?void 0:l.matchProgression;if(!(null==t?void 0:t.length))return null;for(let l of t){var u,r;if((null==(u=l.type)?void 0:u.toLowerCase())!=="loser"&&(null==(r=l.type)?void 0:r.toLowerCase())!=="l")continue;let t=l.previousMatch,i=null==t?void 0:t.id,a=null==t?void 0:t.matchIndex,d=null!=a&&(a===e+1||a===e);if(i===n||d)return"entry2"===l.entryType?"team2":"team1"}return null},c=(l,n)=>{var e,t,u,r,i,a;if(!l.lowerPlaceMatch)return null;let d=null!=(r=null==l?void 0:l.rounds)?r:[],c=o(d,n);if(!c&&(null==l||null==(e=l.brackets)?void 0:e.length))for(let e of l.brackets){let l=null!=(i=null==e?void 0:e.rounds)?i:[];if(c=o(l,n)){d=l;break}}if(!c||0===d.length)return null;let{roundIndex:v,seedIndex:p}=c,y=d[v],f=null==(u=d[v])||null==(t=u.seeds)?void 0:t[p];if((null==y?void 0:y.title)!=="Semi-Final"&&(null==y?void 0:y.title)!=="semiFinal")return null;let g=l.lowerPlaceMatch.id,w=m(l.lowerPlaceMatch,n,p),h=s(null==f?void 0:f.name),I=p%2==0?"team1":"team2";return{nextSeedId:g,nextTeam:null!=(a=null!=w?w:h)?a:I}},v=(l,n,e)=>{let t="number"==typeof(null==e?void 0:e.lowerPlaceNextSeedId)?e.lowerPlaceNextSeedId:null,u=null==e?void 0:e.lowerPlaceNextTeam;return null!=t&&null!=u?{nextSeedId:t,nextTeam:"team1"===u||"team2"===u?u:"team1"}:c(l,n)},p=l=>{if(!l)return"";switch(l){case"MDWC":case"QWC":return"WC";case"QW":return"Q";default:return l}},y=(l,n,e)=>"MD"===e&&l?p(l)||"":"Q"===e&&"QW"===n?"":!["MD","Q"].includes(n||"")&&p(n||"")||"",f=l=>{var n,e,t,u;return!!l&&((null==(e=l.tournamentCategory)||null==(n=e.category)?void 0:n.type)==="doubles"||null!=(u=null==(t=l.rounds)?void 0:t.some(l=>{var n;return null==(n=l.seeds)?void 0:n.some(l=>{var n,e,t,u;return(null==(e=l.entry1)||null==(n=e.users)?void 0:n.length)===2||(null==(u=l.entry2)||null==(t=u.users)?void 0:t.length)===2})}))&&u)},g=(l,n,e)=>{var t,u,r,i,d,s,m,c,v,p,y;let f=null!=(m=null==l?void 0:l.rounds)?m:[],g=o(f,n),w=null;if(!g&&(null==l||null==(t=l.brackets)?void 0:t.length))for(let e of l.brackets){let l=null!=(c=null==e?void 0:e.rounds)?c:[];if(g=o(l,n)){f=l,w=e;break}}if(!g||0===f.length)return null;let{roundIndex:h,seedIndex:I}=g,b=null==(r=f[h])||null==(u=r.seeds)?void 0:u[I];if(!b)return null;let C=a(I,h,l,l.id,f,b,[],e),S=null!=(p=null!=(v=null==w||null==(i=w.lowerPlaceMatch)?void 0:i.id)?v:null==l||null==(d=l.lowerPlaceMatch)?void 0:d.id)?p:null,R=h===f.length-2,k=null!=(y=null==(s=f[h])?void 0:s.title)?y:null;return{...C,lowerPlace:S,isSemiFinal:R,roundIndex:h,currentRound:k}},w=(l,n,e)=>{let t=g(l,n,e);if(t&&!t.isLastRound&&Number.isFinite(t.nextSeedID)&&!(t.nextSeedID<=0))return{nextSeedId:t.nextSeedID,nextTeam:t.team}}},17434:(l,n,e)=>{e.d(n,{G:()=>r});var t=e(31617),u=e(13441);let r=(l,n)=>{var e,r;let i=(null==n?void 0:n.date)?u.c9.fromISO(n.date,{zone:"utc"}):null,a=(null==n?void 0:n.status)==="completed"||!(0,t.isEmpty)(null==n?void 0:n.score);return(!!(null==l?void 0:l.showOOP)||null==l||!l.overRideShowOOP)&&!a&&(null==l||!l.showOOP||!!((null==l||null==(e=l.datesToHide)?void 0:e.length)&&i&&(null==l||null==(r=l.datesToHide)?void 0:r.some(l=>{try{let n=u.c9.fromISO(l,{zone:"utc"});return(null==n?void 0:n.toISODate())===(null==i?void 0:i.toISODate())}catch(l){return!1}}))))}},29586:(l,n,e)=>{e.d(n,{A:()=>I});var t=e(21398),u=e(25398),r=e(71937),i=e(30184),a=e(72557),d=e(43647),o=e(78319),s=e(5998),m=e(75240),c=e(48996),v=e(33356),p=e(580),y=e(50567),f=e(84852),g=e(5263),w=e(50636),h=e(16055);let I=l=>{var n,e;let{match:I,showReviewText:b=!0,variant:C="card",tournamentCategoryId:S,parentIsGroupMatch:R,parentDrawId:k,onActionComplete:T}=l,A=(0,s.k)(),x=(0,r.m)(),D=null==(n=(0,u.useContext)(m.TF))?void 0:n.id,{promptConfirmScore:E,promptDeclineScore:U}=(0,p.p)(),{session:{userData:M}}=(0,d.As)(),[L,{loading:P}]=(0,o.K$S)({refetchQueries:["getMatches","getUserTournamentMatches","matchDetails","groupMatches","drawEntries"]}),[N,{loading:O}]=(0,o.PjG)({refetchQueries:["getMatches","getUserTournamentMatches","matchDetails","groupMatches","drawEntries","drawsDetail"]}),[j]=(0,o.egD)(),q=(null==M?void 0:M.id)!=null,W=(0,f.T)(I);if(!(0,y.xm)(W,null!=(e=null==M?void 0:M.id)?e:void 0,q).isOpponentReviewing)return null;let F=(0,c.xO)(I,{parentIsGroupMatch:R,parentDrawId:k}),z=P||O,_=async l=>{try{if(null!=F){let e=(0,g.oJ)(I.draw);if(l===o.c4O.Confirmed){var n;await (0,v.Q)({match:I,drawId:F,tournamentCategoryId:S,tournamentId:D,segment:null!=(n=null==e?void 0:e.segment)?n:null,fetchDrawsDetail:j,updateDrawMatchAction:N,client:x})}else await N({variables:{...(0,c.q3)({match:I,drawId:F,tournamentCategoryId:S}),actionType:l,token:null}})}
1else await L({variables:{matchId:I.id,actionType:l,token:null}});null==T||T(),w.o.success(l===o.c4O.Confirmed?A("matches.confirmation.confirmed"):A("matches.confirmation.declined"))}catch(l){w.o.error(l instanceof Error?l.message:A("general.error.unexpectedError"))}},Q=(0,t.jsxs)("div",{className:(0,h.cn)("flex gap-2 w-full","inline"===C?"flex-row px-3 pb-3":"flex-wrap justify-center"),children:[(0,t.jsx)(i.default,{size:"inline"===C?"md":"sm",color:"danger",variant:"bordered",onPress:()=>U(()=>_(o.c4O.Rejected)),isDisabled:z,isLoading:z,className:"inline"===C?"flex-1":"min-w-[120px]",children:A("matches.confirmation.decline")}),(0,t.jsx)(i.default,{size:"inline"===C?"md":"sm",color:"primary",variant:"solid",onPress:()=>E(()=>_(o.c4O.Confirmed)),isDisabled:z,isLoading:z,className:"inline"===C?"flex-1":"min-w-[120px]",children:A("matches.confirmation.confirm")})]});return"inline"===C?Q:(0,t.jsxs)(a.A,{className:"w-full p-3 flex flex-col gap-3 rounded-2xl border border-default-200 mx-2 mb-2",children:[b&&(0,t.jsx)("p",{className:"text-center text-sm text-foreground opacity-90",children:A("matches.confirmation.reviewOpponentEnteredResult")}),Q]})}},31617:(l,n,e)=>{var t=e(87350);e.o(t,"isEmpty")&&e.d(n,{isEmpty:function(){return t.isEmpty}})},33356:(l,n,e)=>{e.d(n,{Q:()=>v});var t=e(15992),u=e(78319),r=e(48996);let i=l=>{if("number"==typeof l&&Number.isFinite(l))return l},a=l=>{var n;let e=i(null==(n=l.winner)?void 0:n.id);if(null!=e)return e;if(Array.isArray(l.teamWinner)&&l.teamWinner.length>0){let n=l.teamWinner[0];if(null!=n&&"object"==typeof n&&"id"in n)return i(n.id)}},d=(l,n)=>{var e,t;let u=i(null==(e=l.entry1)?void 0:e.id),r=i(null==(t=l.entry2)?void 0:t.id);if(null!=u&&null!=r)return u===n?r:u},o=(l,n)=>{if(!l.isFirstMatchLosersToConsolationDraw)return null;let e=n.find(n=>{let e=n.mainDraw;return null!=e&&("object"==typeof e&&"id"in e?e.id:e)===l.id});return null!=e?e:null},s=async(l,n,e)=>{var t,u,r;let{data:i}=await l({variables:{filter:{tournament:n,mainDraw:e}}});return null!=(r=null==i||null==(u=i.drawsDetail)||null==(t=u.draws)?void 0:t[0])?r:null},m=async l=>{var n,e,t,u,r,i;let a=null!=(e=l.rootDraw)?e:l.draw;if(null!=a)return a;if(null==l.tournamentId||!l.fetchDrawsDetail)return null;let{data:d}=await l.fetchDrawsDetail({variables:{filter:{tournament:l.tournamentId,tournamentCategory:null!=(t=l.tournamentCategoryId)?t:void 0,segment:null!=(u=l.segment)?u:void 0}}});return null!=(i=(null!=(r=null==d||null==(n=d.drawsDetail)?void 0:n.draws)?r:[]).find(n=>n.id===l.drawId))?i:null},c=async l=>{if(!l.draw.isFirstMatchLosersToConsolationDraw)return null;let n=l.allDraws?o(l.draw,l.allDraws):null;return n||(null!=l.tournamentId&&l.fetchDrawsDetail?s(l.fetchDrawsDetail,l.tournamentId,l.draw.id):null)},v=async l=>{var n,e,i;let o=a(l.match),s=null!=o?d(l.match,o):void 0,v=await m({drawId:l.drawId,tournamentId:l.tournamentId,tournamentCategoryId:l.tournamentCategoryId,segment:l.segment,draw:l.draw,rootDraw:l.rootDraw,fetchDrawsDetail:l.fetchDrawsDetail}),p=null,y=null;null!=v&&(y=await c({draw:v,tournamentId:l.tournamentId,allDraws:l.allDraws,fetchDrawsDetail:l.fetchDrawsDetail}),p=(0,t.L3)(v,l.match.id,y));let f=null!=v?(0,t.ZN)(v,l.match.id,y):void 0,g=null!=v?(0,t.vC)(v,l.match.id,l.match):null,w=null!=f?{...f,...(null==p?void 0:p.isQualRound)&&null!=s?{qualWinner:!0,looserId:s}:{}}:void 0,h=null!=o?{...l.match,winner:{id:o}}:l.match;if(await l.updateDrawMatchAction({variables:{...(0,r.q3)({match:h,drawId:l.drawId,tournamentCategoryId:l.tournamentCategoryId,advancement:w}),actionType:u.c4O.Confirmed,token:null},awaitRefetchQueries:!1,refetchQueries:[]}),null!=g&&null!=s){let n=null!=(i=null==p?void 0:p.team)?i:g.nextTeam;await l.updateDrawMatchAction({variables:{...(0,r.q3)({match:{...l.match,winner:{id:s}},drawId:l.drawId,tournamentCategoryId:l.tournamentCategoryId,advancement:{nextSeedId:g.nextSeedId,nextTeam:n}}),actionType:u.c4O.Confirmed,token:null},awaitRefetchQueries:!1,refetchQueries:[]}),await l.updateDrawMatchAction({variables:{...(0,r.q3)({match:h,drawId:l.drawId,tournamentCategoryId:l.tournamentCategoryId}),actionType:u.c4O.Confirmed,token:null},refetchQueries:["drawsDetail"]})}null==(n=l.client)||n.cache.evict({id:"ROOT_QUERY",fieldName:"drawsDetailPublic"}),null==(e=l.client)||e.cache.gc()}},48996:(l,n,e)=>{e.d(n,{q3:()=>y,uM:()=>u,xO:()=>r});let t=l=>{if(null!=l){if(Array.isArray(l)){let n=l[0];if(null==n||"object"!=typeof n||!("id"in n))return;return a(n.id)}if("object"==typeof l&&"id"in l)return a(l.id)}},u=l=>{if(null!=l&&"object"==typeof l&&"draw"in l)return t(l.draw)},r=(l,n)=>{if(null==n?void 0:n.parentIsGroupMatch)return;let e=u(l);return null!=e?e:a(null==n?void 0:n.parentDrawId)},i=l=>{if("string"!=typeof l)return;let n=l.trim();return""===n?void 0:n},a=l=>{if("number"==typeof l&&Number.isFinite(l))return l},d=l=>{if(!l||"object"!=typeof l)return;let n=a(l.id),e=l.user&&"object"==typeof l.user?a(l.user.id):void 0;return null!=n?n:e},o=l=>{if(!Array.isArray(l)||0===l.length)return;let n=[];for(let e of l){let l=d(e);void 0!==l&&n.push(l)}return n.length>0?n:void 0},s=l=>{if(!Array.isArray(l)||0===l.length)return;let n=[];for(let e of l){let l=d(e);void 0!==l&&n.push(l)}return n.length>0?n:void 0},m=l=>{if("string"==typeof l){let n=l.trim();if(""!==n)return n}if(Array.isArray(l)&&l.length>0)return JSON.stringify(l)},c=l=>{if("number"==typeof l&&Number.isFinite(l))return l;if(!Array.isArray(l)||0===l.length)return;let n=l[0];return a(null==n?void 0:n.id)},v=l=>{let n=l.tournamentCategory;if(n&&"object"==typeof n&&"id"in n){let l=a(n.id);if(void 0!==l)return l}let e=l.draw,t=Array.isArray(e)?e[0]:e;if(!t||"object"!=typeof t)return;let u=t.tournamentCategory;return a(null==u?void 0:u.id)},p=l=>{if("team"===l.matchType)return!0;let n=null!=c(l.mainMatch),e=Array.isArray(l.team1Entry)&&l.team1Entry.length>0||Array.isArray(l.team2Entry)&&l.team2Entry.length>0,t=Array.isArray(l.teamWinner)&&l.teamWinner.length>0;return n&&(e||t||!!l.teamMatchType)},y=l=>{var n,e,t,u,r,d,y,f,g,w,h,I;let{match:b,drawId:C,tournamentCategoryId:S,advancement:R}=l,k=null!=(t=a(S))?t:v(b),T=null!=(r=null!=(u=i(b.matchStatus))?u:i(b.status))?r:"completed",A=p(b),x=m(b.score),D=m(b.teamScore);return{id:b.id,draw:C,nextTeam:i(null!=(d=null==R?void 0:R.nextTeam)?d:b.nextTeam),nextSeedId:a(null!=(y=null==R?void 0:R.nextSeedId)?y:b.nextSeedId),winner:A?void 0:a(null==(n=b.
1winner)?void 0:n.id),mainMatch:c(b.mainMatch),score:A?void 0:x,teamScore:A?D:void 0,date:null!=b.date?"string"==typeof b.date?b.date:String(b.date):void 0,time:i(b.time),court:a(null==(e=b.court)?void 0:e.id),qualWinner:null!=(g=null!=(f=null==R?void 0:R.qualWinner)?f:b.qualWinner)?g:void 0,looserId:a(null!=(w=null==R?void 0:R.looserId)?w:b.looserId),scoreType:i(b.scoreType),matchStatus:T,hideInOOP:null!=(h=b.hideInOOP)?h:void 0,isMatchInProgress:null!=(I=b.isMatchInProgress)&&I,duration:a(b.duration),teamWinner:A?s(b.teamWinner):void 0,teamMatchType:A?i(b.teamMatchType):void 0,tournamentCategory:k,team1Entry:A?o(b.team1Entry):void 0,team2Entry:A?o(b.team2Entry):void 0,name:i(b.name)}}},50567:(l,n,e)=>{e.d(n,{Np:()=>P,Pk:()=>E,RG:()=>m,je:()=>p,lA:()=>N,pr:()=>M,xm:()=>x});var t=e(78319),u=e(5263);let r=l=>null==l?"":String(l).toLowerCase(),i=l=>null!=l&&(l===t.c4O.Submitted||r(l)===t.c4O.Submitted.toLowerCase()),a=l=>null!=l&&(l===t.c4O.Rejected||r(l)===t.c4O.Rejected.toLowerCase()),d=l=>null!=l&&(l===t.c4O.Confirmed||r(l)===t.c4O.Confirmed.toLowerCase()),o=l=>null!=l&&(l===t.c4O.Withdrawn||r(l)===t.c4O.Withdrawn.toLowerCase()),s=l=>null!=l&&("string"==typeof l?""!==l.trim():!!Array.isArray(l)&&l.length>0),m=l=>s(null==l?void 0:l.score)||s(null==l?void 0:l.teamScore),c=new Set(["w/o","ret","disq"]),v=l=>{let n="string"==typeof(null==l?void 0:l.scoreType)?l.scoreType.trim().toLowerCase():"";return""!==n&&c.has(n)},p=l=>!!(null==l?void 0:l.winner)||Array.isArray(null==l?void 0:l.teamWinner)&&l.teamWinner.length>0,y=l=>(null==l?void 0:l.team1Entry)==null&&(null==l?void 0:l.team2Entry)==null||(0,u.Br)(null==l?void 0:l.team1Entry)&&(0,u.Br)(null==l?void 0:l.team2Entry),f=l=>(0,u.f0)(l).map(l=>{var n,e;return null!=(e=null==l||null==(n=l.user)?void 0:n.id)?e:null==l?void 0:l.id}).filter(l=>null!=l).map(Number),g=l=>{var n,e,t;return[...f(null!=(e=null==l?void 0:l.users)?e:null),...f(null!=(t=null==l||null==(n=l.registrationRequest)?void 0:n.users)?t:null)]},w=l=>{var n,e,t,u,r,i,a,d;let o=(null!=(r=null==l||null==(n=l.participant1)?void 0:n.users)?r:[]).map(l=>null==l?void 0:l.id).filter(l=>null!=l).map(Number),s=(null!=(i=null==l||null==(e=l.participant2)?void 0:e.users)?i:[]).map(l=>null==l?void 0:l.id).filter(l=>null!=l).map(Number);if(o.length>0||s.length>0)return{side1UserIds:o,side2UserIds:s};let m=f(null==l?void 0:l.team1Entry),c=f(null==l?void 0:l.team2Entry);if(m.length>0||c.length>0)return{side1UserIds:m,side2UserIds:c};let v=(()=>{var n;return(null==l?void 0:l.mainMatch)==null?null:Array.isArray(l.mainMatch)?null!=(n=l.mainMatch[0])?n:null:"object"==typeof l.mainMatch?l.mainMatch:null})(),p=null!=v&&"object"==typeof v&&"entry1"in v?v.entry1:null,y=null!=v&&"object"==typeof v&&"entry2"in v?v.entry2:null,w=g(p),h=g(y);return w.length>0||h.length>0?{side1UserIds:w,side2UserIds:h}:{side1UserIds:[...g(null==l?void 0:l.entry1),...f(null!=(a=null==l||null==(t=l.entry1Registration)?void 0:t.users)?a:null)],side2UserIds:[...g(null==l?void 0:l.entry2),...f(null!=(d=null==l||null==(u=l.entry2Registration)?void 0:u.users)?d:null)]}},h=(l,n)=>{let{side1UserIds:e,side2UserIds:t}=w(l),u=String(n),r=e.some(l=>String(l)===u),i=t.some(l=>String(l)===u);return r&&!i?1:i&&!r?2:null},I=l=>{if(null==l)return null;if(Array.isArray(l)){let n=l[0];return null!=n&&"object"==typeof n?n:null}return"object"==typeof l?l:null},b=l=>{let n=I(l);if(!n)return null;let e=n.entry1,t=n.entry2,u=Array.isArray(e)?e[0]:e,r=Array.isArray(t)?t[0]:t,i=g(null!=u&&"object"==typeof u?u:null),a=g(null!=r&&"object"==typeof r?r:null);return 0===i.length&&0===a.length?null:{side1UserIds:i,side2UserIds:a}},C=l=>{let n=f(null==l?void 0:l.team1Entry),e=f(null==l?void 0:l.team2Entry);if(0===n.length&&0===e.length)return null;let t=new Set(f(Array.isArray(null==l?void 0:l.teamWinner)?l.teamWinner:null));if(0===t.size)return null;let u=n.some(l=>t.has(l)),r=e.some(l=>t.has(l));return u&&!r?1:r&&!u?2:null},S=l=>!!y(l)&&((0,u.Br)(null==l?void 0:l.team1Entry)||(0,u.Br)(null==l?void 0:l.team2Entry)),R=l=>S(l)?C(l):null,k=(l,n)=>{if(null==n)return null;let e=h(l,n);if(null!=e)return e;let t=b(null==l?void 0:l.mainMatch);if(t){let l=String(n),e=t.side1UserIds.some(n=>String(n)===l),u=t.side2UserIds.some(n=>String(n)===l);if(e&&!u)return 1;if(u&&!e)return 2}return C(l)},T=(l,n,e)=>{if(null==n)return!1;let t=h(l,n);if(null==t)return!1;if(null!=e){let n=k(l,e);return null!=n&&n!==t}let u=R(l);return null!=u&&u!==t},A=(l,n,e)=>(null==l?void 0:l.isScoreConfirmed)!==!0&&!e&&((null==l?void 0:l.isScoreConfirmed)===!1||null!=l&&!!l.confirmationToken||null!=n&&i(n.type)),x=(l,n,e)=>{var t,u,r,s,c,p;let f=[...null!=(r=null==l?void 0:l.scoreActions)?r:[]].sort((l,n
1)=>{var e,t;return new Date(String(null!=(e=null==n?void 0:n.performedAt)?e:0)).getTime()-new Date(String(null!=(t=null==l?void 0:l.performedAt)?t:0)).getTime()})[0],g=null!=f&&a(f.type),w=null!=f&&d(f.type),h=null!=f&&o(f.type),I=[...null!=(s=null==l||null==(t=l.scoreActions)?void 0:t.filter(l=>i(null==l?void 0:l.type)))?s:[]].sort((l,n)=>{var e,t;return new Date(String(null!=(e=null==n?void 0:n.performedAt)?e:0)).getTime()-new Date(String(null!=(t=null==l?void 0:l.performedAt)?t:0)).getTime()})[0],b=null!=(p=null!=(c=null==I||null==(u=I.performedBy)?void 0:u.id)?c:null==I?void 0:I.performedById)?p:null,C=null!=b?Number(b):null,S=null!=C&&null!=n&&String(C)===String(n),R=m(l),k=v(l),x=y(l),D=A(l,f,w),E=x&&!g&&!h&&D&&R,U=e&&E&&T(l,n,C);return{latestActionIsRejected:g,submittedByUserId:C,isCurrentUserSubmitter:S,isPendingConfirmation:E,isOpponentReviewing:U,shouldShowScore:x&&(R||k)&&!g&&(!E||U),showSubmitterPendingCard:e&&E&&S,showLoggedOutPendingHint:!e&&E&&R}},D=(l,n,e)=>x(l,n,e).isOpponentReviewing,E=(l,n,e)=>{let t=x(l,n,e),u=t.shouldShowScore,r=u||p(l);return{status:t.isOpponentReviewing&&u?"completed":t.isPendingConfirmation?"pending":r?"completed":"scheduled",confirmationUi:t}},U=l=>{var n,e;let t=[...new Set(null!=(n=l.entry1UserIds)?n:[])],u=new Set(t);return{entry1UserIds:t,entry2UserIds:[...new Set(null!=(e=l.entry2UserIds)?e:[])].filter(l=>!u.has(l))}},M=(l,n)=>{var e,t;return L(l,{entry1UserIds:[...null!=(e=null==n?void 0:n.parentEntry1UserIds)?e:[],...(null==n?void 0:n.teamCaptain1UserId)!=null?[n.teamCaptain1UserId]:[]],entry2UserIds:[...null!=(t=null==n?void 0:n.parentEntry2UserIds)?t:[],...(null==n?void 0:n.teamCaptain2UserId)!=null?[n.teamCaptain2UserId]:[]]})},L=(l,n)=>{var e,t,u,r,i,a;let d=n?U(n):null;if(!d||(null!=(u=null==(e=d.entry1UserIds)?void 0:e.length)?u:0)===0&&(null!=(r=null==(t=d.entry2UserIds)?void 0:t.length)?r:0)===0)return l;let o=l=>{if(l&&0!==l.length)return{users:l.map(l=>({user:{id:l}}))}},s=(l,n)=>{let e=Array.isArray(l)?l[0]:l,t=[...new Set([...null!=e&&"object"==typeof e?g(e):[],...null!=n?n:[]])];if(0!==t.length)return null!=e&&"object"==typeof e?{...e,users:t.map(l=>({user:{id:l}}))}:o(t)},m=I(l.mainMatch);return{...l,mainMatch:[{...null!=m?m:{},entry1:null!=(i=s(null==m?void 0:m.entry1,d.entry1UserIds))?i:o(d.entry1UserIds),entry2:null!=(a=s(null==m?void 0:m.entry2,d.entry2UserIds))?a:o(d.entry2UserIds)}]}},P=l=>M(l,{parentEntry1UserIds:f(null==l?void 0:l.team1Entry),parentEntry2UserIds:f(null==l?void 0:l.team2Entry)}),N=(l,n,e)=>{let t=[],u=[];return l.forEach(l=>{D(P(l),n,e)?t.push(l):u.push(l)}),{pendingConfirmation:t,otherMatches:u}}},52746:(l,n,e)=>{e.d(n,{A:()=>o});var t=e(21398),u=e(70828),r=e(30184),i=e(5998),a=e(91057),d=e(93342);let o=l=>{let{onClick:n,size:e="md",className:o,placeholderText:s,isDisabled:m,teamMatchType:c}=l,v=(0,i.k)(),p=null!=s?s:v("doubles"===c?"matches.selectPair":"matches.selectPlayer");return(0,t.jsxs)(r.default,{variant:"flat",size:e,onPress:n,isDisabled:m,className:(0,u.cn)("w-full justify-between bg-[#fafafa] dark:bg-offGrey",o),children:[(0,t.jsxs)("div",{className:"flex gap-2 items-center text-xs opacity-60",children:[(0,t.jsx)(a.K,{className:"w-3 h-3"}),(0,t.jsx)("span",{children:p})]}),(0,t.jsx)(d.r,{className:"w-3 h-3 text-gray-500"})]})}},67689:(l,n,e)=>{e.d(n,{At:()=>m,Em:()=>d,KZ:()=>s,RG:()=>i,Sr:()=>g,b:()=>a,bn:()=>o,iO:()=>w,qx:()=>r,tJ:()=>f});var t=e(94504),u=e(60739);let r=l=>"string"==typeof l?l.trim().length>0:!!l,i=(l,n)=>{var e,t,u,r,i;if(l){if(l.winnerEntryId)return l.winnerEntryId;if(null==(e=l.winner)?void 0:e.id)return l.winner.id;if(0==n&&(null==(t=l.entry1)?void 0:t.id)&&!(null==(u=l.entry2)?void 0:u.id))return l.entry1.id;if(0==n&&(null==(r=l.entry2)?void 0:r.id)&&!(null==(i=l.entry1)?void 0:i.id))return l.entry2.id}},a=(l,n,e)=>!!l&&void 0!==n&&!!e&&n===e-1&&"empty"===o(l.entry1).type!=("empty"===o(l.entry2).type)&&!r(l.score),d=()=>(0,t.Ay)((0,u.A)()).set("hsl.h","+40").hex(),o=(l,n)=>{var e,t,u,r,i;return((null==l||null==(e=l.users)?void 0:e.length)||(null==l||null==(t=l.team)?void 0:t.id))&&l.id?(null==l?void 0:l.team)?{type:"team",entryId:l.id,team:{title:null!=(u=l.team.title)?u:"",photo:l.team.image,members:(null!=(r=l.users)?r:[]).reduce((l,e)=>{var t,u,r,i,a,d,o,s,m,c,v,p,y,f,g,w,h,I;if(!(null==(t=e.user)?void 0:t.id))return l;let b=null==e||null==(u=e.user)?void 0:u.user_sports,C=null!=(v=null==b?void 0:b.find(l=>{var e,t,u,r;return(null==(e=l.sport)?void 0:e.id)===(null==n||null==(r=n.league)||null==(u=r.league)||null==(t=u.sports)?void 0:t.id)}))?v:null;return[...l,{name:null==(r=e.user)?void 0:r.name,surname:null==(i=e.user)?void 0:i.surname,fullName:"".concat(null==(a=e.user)?void 0:a.name," ").concat(null==(d=e.user)?void 0:d.surname).trim()||"Unknown",country:null==(o=e.user)?void 0:o.nation,duprRating:e.duprRating,wtnRating:null!=(p=e.wtnRating)?p:null,duprId:null==(s=e.user)?void 0:s.duprId,club:null==C?void 0:C.club,ph
1oto:null!=(y=e.user.avatar)?y:void 0,id:e.user.id,rank:e.rank,wprUserId:null==(m=e.user)?void 0:m.wprUserId,wprPlayerId:null!=(f=null==(c=e.user)?void 0:c.wprPlayerId)?f:null,wprCompetitionRating:null!=(g=e.wprCompetitionRating)?g:null,wprSocialRating:null!=(w=e.wprSocialRating)?w:null,wprCompetitionRatingConfidenceLevel:null!=(h=e.wprCompetitionRatingConfidenceLevel)?h:null,wprSocialRatingConfidenceLevel:null!=(I=e.wprSocialRatingConfidenceLevel)?I:null}]},[]),id:l.team.id,country:l.team.country}}:{type:"players",entryId:l.id,members:(null!=(i=l.users)?i:[]).reduce((l,e)=>{var t,u,r,i,a,d,o,s,m,c,v,p,y;if(!(null==(t=e.user)?void 0:t.id))return l;let f=null==e||null==(u=e.user)?void 0:u.sports,g=null!=(d=null==f?void 0:f.find(l=>{var e,t,u,r;return(null==(e=l.sport)?void 0:e.id)===(null==n||null==(r=n.league)||null==(u=r.league)||null==(t=u.sports)?void 0:t.id)}))?d:null;return[...l,{name:e.user.name,surname:e.user.surname,fullName:"".concat(e.user.name," ").concat(e.user.surname).trim()||"Unknown",country:e.user.nation,duprRating:e.duprRating,wtnRating:null!=(o=e.wtnRating)?o:null,duprId:null==(r=e.user)?void 0:r.duprId,club:null==g?void 0:g.club,photo:null!=(s=e.user.avatar)?s:void 0,id:e.user.id,rank:e.rank,wprUserId:null==(i=e.user)?void 0:i.wprUserId,wprPlayerId:null!=(m=null==(a=e.user)?void 0:a.wprPlayerId)?m:null,wprCompetitionRating:null!=(c=e.wprCompetitionRating)?c:null,wprSocialRating:null!=(v=e.wprSocialRating)?v:null,wprCompetitionRatingConfidenceLevel:null!=(p=e.wprCompetitionRatingConfidenceLevel)?p:null,wprSocialRatingConfidenceLevel:null!=(y=e.wprSocialRatingConfidenceLevel)?y:null}]},[])}:{type:"empty"}},s=(l,n)=>{var e,t,u,r,i,a;return(null==l?void 0:l.registrationRequest)&&l.id?l.registrationRequest.team?{type:"team",entryId:l.id,team:{title:null!=(u=l.registrationRequest.team.title)?u:"N/A",photo:l.registrationRequest.team.image,members:null!=(r=null==(t=l.registrationRequest.users)?void 0:t.reduce((l,n)=>{var e,t,u,r,i,a,d,o,s;let m=n.user;if(!m||!m.id)return l;let c="".concat(m.name," ").concat(m.surname).trim()||"Unknown";return[...l,{name:null!=(e=null==m?void 0:m.name)?e:"",surname:null!=(t=null==m?void 0:m.surname)?t:"",fullName:c,country:null!=(u=m.nation)?u:void 0,id:m.id,photo:null!=(r=m.avatar)?r:"",wprUserId:null==m?void 0:m.wprUserId,wprPlayerId:null!=(i=null==m?void 0:m.wprPlayerId)?i:null,wprCompetitionRating:null!=(a=n.wprCompetitionRating)?a:null,wprSocialRating:null!=(d=n.wprSocialRating)?d:null,wprCompetitionRatingConfidenceLevel:null!=(o=n.wprCompetitionRatingConfidenceLevel)?o:null,wprSocialRatingConfidenceLevel:null!=(s=n.wprSocialRatingConfidenceLevel)?s:null}]},[]))?r:[],id:null!=(i=l.registrationRequest.team.id)?i:0,country:""}}:{type:"players",entryId:l.id,isWinner:l.id===n,members:null!=(a=null==(e=l.registrationRequest.users)?void 0:e.reduce((l,n)=>{var e,t,u,r,i,a,d,o;let s=n.user;if(!s||!s.id)return l;let m="".concat(s.name," ").concat(s.surname).trim()||"Unknown";return[...l,{name:null!=(e=null==s?void 0:s.name)?e:"",surname:null!=(t=null==s?void 0:s.surname)?t:"",fullName:m,country:null!=(u=s.nation)?u:void 0,id:s.id,wprUserId:null==s?void 0:s.wprUserId,wprPlayerId:null!=(r=null==s?void 0:s.wprPlayerId)?r:null,wprCompetitionRating:null!=(i=n.wprCompetitionRating)?i:null,wprSocialRating:null!=(a=n.wprSocialRating)?a:null,wprCompetitionRatingConfidenceLevel:null!=(d=n.wprCompetitionRatingConfidenceLevel)?d:null,wprSocialRatingConfidenceLevel:null!=(o=n.wprSocialRatingConfidenceLevel)?o:null}]},[]))?a:[]}:{type:"empty"}},m=(l,n)=>{var e,t,u,r,i,a,d,o,s;if(!(null==l?void 0:l.users)&&!(null==l?void 0:l.team)||!l)return{type:"empty"};if(null==l?void 0:l.team)return{type:"team",entryId:null!=(r=l.id)?r:void 0,team:{title:null!=(i=null==l?void 0:l.team.title)?i:"N/A",photo:null==l?void 0:l.team.image,members:[],id:null!=(a=null==l?void 0:l.team.id)?a:0,country:""}};let m=null!=(d=null==l||null==(e=l.users)?void 0:e.reduce((l,n)=>{var e,t,u,r,i,a,d,o,s;let m=n.user;if(!m||!m.id)return l;let c="".concat(m.name," ").concat(m.surname).trim()||"Unknown";return[...l,{name:null!=(e=null==m?void 0:m.name)?e:"",surname:null!=(t=null==m?void 0:m.surname)?t:"",fullName:c,country:null!=(u=m.nation)?u:void 0,id:m.id,photo:null!=(r=m.avatar)?r:void 0,wprUserId:m.wprUserId,wprPlayerId:null!=(i=null==m?void 0:m.wprPlayerId)?i:null,wprCompetitionRating:null!=(a=null==n?void 0:n.wprCompetitionRating)?a:null,wprSocialRating:null!=(d=null==n?void 0:n.wprSocialRating)?d:null,wprCompetitionRatingConfidenceLevel:null!=(o=null==n?void 0:n.wprCompetitionRatingConfidenceLevel)?o:null,wprSocialRating
1ConfidenceLevel:null!=(s=null==n?void 0:n.wprSocialRatingConfidenceLevel)?s:null}]},[]))?d:[],c=(null==n?void 0:n.registrationRequest)&&null!=(o=null==n||null==(u=n.registrationRequest)||null==(t=u.users)?void 0:t.reduce((l,n)=>{var e,t,u,r,i,a,d,o;let s=n.user;if(!s||!s.id)return l;let m="".concat(s.name," ").concat(s.surname).trim()||"Unknown";return[...l,{name:null!=(e=null==s?void 0:s.name)?e:"",surname:null!=(t=null==s?void 0:s.surname)?t:"",fullName:m,country:null!=(u=s.nation)?u:void 0,id:s.id,wprUserId:s.wprUserId,wprPlayerId:null!=(r=null==s?void 0:s.wprPlayerId)?r:null,wprCompetitionRating:null!=(i=n.wprCompetitionRating)?i:null,wprSocialRating:null!=(a=n.wprSocialRating)?a:null,wprCompetitionRatingConfidenceLevel:null!=(d=n.wprCompetitionRatingConfidenceLevel)?d:null,wprSocialRatingConfidenceLevel:null!=(o=n.wprSocialRatingConfidenceLevel)?o:null}]},[]))?o:[];return{type:"players",entryId:null!=(s=l.id)?s:void 0,members:[...m,...c]}},c=(l,n)=>{var e,t;return(null==l?void 0:l.id)?l.teamName?{type:"team",entryId:l.id,team:{title:l.teamName,members:(null!=(e=l.users)?e:[]).reduce((l,n)=>{var e,t,u,r,i,a;return n.id?[...l,{id:n.id,name:null!=(e=n.name)?e:"",surname:null!=(t=n.surname)?t:"",fullName:"".concat(null!=(u=n.name)?u:""," ").concat(null!=(r=n.surname)?r:"").trim()||"Unknown",country:null!=(i=n.nation)?i:void 0,photo:null!=(a=n.avatar)?a:void 0}]:l},[]),id:l.id,country:""}}:{type:"players",entryId:l.id,isWinner:l.id===n,members:(null!=(t=l.users)?t:[]).reduce((l,n)=>{var e,t,u,r,i,a;return n.id?[...l,{id:n.id,name:null!=(e=n.name)?e:"",surname:null!=(t=n.surname)?t:"",fullName:"".concat(null!=(u=n.name)?u:""," ").concat(null!=(r=n.surname)?r:"").trim()||"Unknown",country:null!=(i=n.nation)?i:void 0,photo:null!=(a=n.avatar)?a:void 0}]:l},[])}:{type:"empty"}},v=l=>(null!=l?l:[]).reduce((l,n)=>{var e,t,u,r,i,a,d,o,s,m,c,v;let p=null==n?void 0:n.user;return(null==p?void 0:p.id)?[...l,{id:p.id,name:null!=(e=p.name)?e:"",surname:null!=(t=p.surname)?t:"",fullName:"".concat(null!=(u=p.name)?u:""," ").concat(null!=(r=p.surname)?r:"").trim()||"Unknown",country:null!=(i=p.nation)?i:void 0,photo:null!=(a=p.avatar)?a:void 0,wprUserId:null!=(d=p.wprUserId)?d:null,wprPlayerId:null!=(o=p.wprPlayerId)?o:null,wprCompetitionRating:null!=(s=n.wprCompetitionRating)?s:null,wprSocialRating:null!=(m=n.wprSocialRating)?m:null,wprCompetitionRatingConfidenceLevel:null!=(c=n.wprCompetitionRatingConfidenceLevel)?c:null,wprSocialRatingConfidenceLevel:null!=(v=n.wprSocialRatingConfidenceLevel)?v:null}]:l},[]),p=(l,n,e)=>{var t,u,r,i,a,d,o;if(!(null==l?void 0:l.id))return{type:"empty"};if(null==(t=l.registrationRequest)?void 0:t.team)return{type:"team",entryId:l.id,team:{title:null!=(i=l.registrationRequest.team.title)?i:"N/A",photo:null!=(a=l.registrationRequest.team.image)?a:void 0,members:v(l.registrationRequest.users),id:null!=(d=l.registrationRequest.team.id)?d:0,country:null!=(o=l.registrationRequest.team.country)?o:""}};let s=v(null==(u=l.registrationRequest)?void 0:u.users),m=v(null==n||null==(r=n.registrationRequest)?void 0:r.users);return{type:"players",entryId:l.id,isWinner:l.id===e,members:[...s,...m]}},y=(l,n)=>{var e,t;if(!(null==l?void 0:l.length))return{type:"empty"};let u=null!=(t=null==n?void 0:n.some(n=>l.some(l=>l.id===n.id)))&&t;return{type:"players",entryId:null==(e=l[0])?void 0:e.id,isWinner:u,members:v(l)}},f=l=>{let n=l=>l&&"empty"!==l.type?"team"===l.type?l.team.members.map(l=>l.id):"players"===l.type?l.members.map(l=>l.id):[]:[];return{entry1UserIds:n(l.entry1),entry2UserIds:n(l.entry2)}},g=(l,n)=>{var e,t,u,r;let i=null!=(r=null!=(u=n.tournamentCategory)?u:null==(e=n.draw)?void 0:e.tournamentCategory)?r:null==(t=n.group)?void 0:t.tournamentCategory;return i?l.map(l=>{var e,t,u,r,a;let d=null!=(r=null!=(u=null==(e=l.draw)?void 0:e.tournamentCategory)?u:null==(t=n.draw)?void 0:t.tournamentCategory)?r:i;return{...l,tournamentCategory:null!=(a=l.tournamentCategory)?a:i,draw:l.draw?{...l.draw,tournamentCategory:d}:l.draw}}):l},w=l=>{var n,e,t,u,r,i,a,d,o,s,m,v,f,g,w,h,I,b,C,S,R,k,T,A,x,D,E,U,M,L,P,N,O,j,q,W;let F="group"===l.matchFor||!!l.group,z=null!=(k=null!=(R=null!=(S=null==(e=l.tournamentCategory)||null==(n=e.category)?void 0:n.isAdvancedTeamEnabled)?S:null==(r=l.draw)||null==(u=r.tournamentCategory)||null==(t=u.category)?void 0:t.isAdvancedTeamEnabled)?R:null==(d=l.group)||null==(a=d.tournamentCategory)||null==(i=a.category)?void 0:i.isAdvancedTeamEnabled)&&k,_="team"===l.matchType,Q=_?y(l.team1Entry,l.teamWinner):p(l.entry1,l.entry1partner,null==(o=l.winner)?void 0:o.id),Z=_?y(l.team2Entry,l.teamWinner):p(l.entry2,l.entry2partner,null==(s=l.winner)?void 0:s.id),B=p(l.groupEntry1,void 0,null==(m
1=l.winner)?void 0:m.id),G=p(l.groupEntry2,void 0,null==(v=l.winner)?void 0:v.id),H=p(l.entry1,l.entry1partner,null==(f=l.winner)?void 0:f.id),J=p(l.entry2,l.entry2partner,null==(g=l.winner)?void 0:g.id),$="empty"!==Q.type?Q:_&&"empty"!==H.type?H:"empty"!==B.type?B:c(l.participant1,null==(w=l.winner)?void 0:w.id),K="empty"!==Z.type?Z:_&&"empty"!==J.type?J:"empty"!==G.type?G:c(l.participant2,null==(h=l.winner)?void 0:h.id);return{id:l.id,tournamentId:null!=(T=null==(I=l.tournament)?void 0:I.id)?T:void 0,isGroupMatch:F,isAdvancedTeamEnabled:null!=z&&z,entry1:$,entry2:K,score:{score:null!=(x=null!=(A=l.teamScore)?A:l.score)?x:null,scoreType:null!=(D=l.scoreType)?D:void 0},date:l.date,time:l.time,oopType:null!=(E=l.oopType)?E:null,dateRangeMatchStatus:null!=(U=l.dateRangeMatchStatus)?U:null,periodStart:null!=(M=l.periodStart)?M:null,periodEnd:null!=(L=l.periodEnd)?L:null,court:null==(b=l.court)?void 0:b.name,courtLiveStreamingLink:null==(C=l.court)?void 0:C.liveStreamingLink,liveStreamings:null!=(P=l.liveStreamings)?P:null,winner:null!=(N=l.winner)?N:null,matchType:l.matchType,tournament:null!=(O=l.tournament)?O:null,tournamentCategory:null!=(j=l.tournamentCategory)?j:null,group:null!=(q=l.group)?q:null,draw:null!=(W=l.draw)?W:null}}},67738:(l,n,e)=>{e.d(n,{A:()=>u});var t=e(78319);let u=(l,n)=>{let{data:e}=(0,t.Ith)({skip:!l,variables:{id:l}}),{data:u}=(0,t.Ith)({skip:!n,variables:{id:n}});return{team1CaptainData:e,team2CaptainData:u}}},72687:(l,n,e)=>{e.d(n,{At:()=>i,QA:()=>r,dT:()=>v,ip:()=>a,yF:()=>y});var t=e(13441);let u=l=>{if(!l)return null;let n=l.trim().toUpperCase().replace(/-/g,"_");return"SPECIFIC_TIME"===n?"SPECIFIC_TIME":"DATE_RANGE"===n?"DATE_RANGE":null},r=l=>"SPECIFIC_TIME"===u(l),i=l=>"DATE_RANGE"===u(l),a=l=>i(l.oopType)&&(!!l.periodStart||!!l.periodEnd),d=(l,n,e)=>{let t=o(l);return t?((null==n?void 0:n.timeZone)?t.setZone(n.timeZone):t).toFormat(e):""},o=l=>{if("string"!=typeof l||!l)return null;let n=t.c9.fromISO(l,{zone:"utc"});return n.isValid?n:null},s=l=>{var n,e,t;return i(null==l?void 0:l.oopType)?{isDateRange:!0,start:null!=(n=null==l?void 0:l.periodStart)?n:null,end:null!=(e=null==l?void 0:l.periodEnd)?e:null}:{isDateRange:!1,start:null!=(t=null==l?void 0:l.date)?t:null,end:null}},m=l=>{if(!l)return!1;try{let n=new Intl.DateTimeFormat(l,{day:"2-digit",month:"2-digit"}).formatToParts(new Date(Date.UTC(2e3,0,2)));return n.findIndex(l=>"month"===l.type)<n.findIndex(l=>"day"===l.type)}catch(l){return!1}},c=(l,n)=>n?l.replace(/\b(d+)([./\-\s])(M+)\b/g,"$3$2$1"):l,v=function(l,n,e){let t=arguments.length>3&&void 0!==arguments[3]&&arguments[3],u=t?"yyyy":"yy",r=m(null==n?void 0:n.locale),{isDateRange:i,start:a,end:d}=s(l);if(!i){if(!a)return"";let l=o(a);return l?((null==n?void 0:n.timeZone)?l.setZone(n.timeZone):l).toFormat(c(e,r)):""}let v=o(a),p=o(d);if(!v||!p)return"";let y=(null==n?void 0:n.timeZone)?v.setZone(n.timeZone):v,f=(null==n?void 0:n.timeZone)?p.setZone(n.timeZone):p,g=y.year===f.year&&y.month===f.month&&y.day===f.day,w=c("d.MM.".concat(u),r);return g?f.toFormat(w):y.year!==f.year||y.month!==f.month||r?"".concat(y.toFormat(w),"-").concat(f.toFormat(w)):"".concat(y.toFormat("d"),"-").concat(f.toFormat("d"),".").concat(f.toFormat("MM.".concat(u)))},p=l=>"00:00"===l?"":l,y=(l,n)=>{if(!i(null==l?void 0:l.oopType))return"";let e=p(d(l.periodStart,n,"HH:mm")),t=p(d(l.periodEnd,n,"HH:mm"));return e&&t?"".concat(e," - ").concat(t):e||t||""}},84357:(l,n,e)=>{e.d(n,{Lx:()=>r,NN:()=>i,fS:()=>a,hQ:()=>u,iA:()=>d,o_:()=>o});var t=e(5263);let u=l=>!!(null==l?void 0:l.isAllowScoreSubmission),r=l=>!!(null==l?void 0:l.isAllowPlayerScoreSubmission),i=function(){for(var l=arguments.length,n=Array(l),e=0;e<l;e++)n[e]=arguments[e];for(let l of n)if(null!=l)return l},a=l=>{var n,e,u,r,i;return null!=(i=null!=(r=null!=(u=null==l?void 0:l.tournamentCategory)?u:null==(n=(0,t.oJ)(null==l?void 0:l.group))?void 0:n.tournamentCategory)?r:null==(e=(0,t.oJ)(null==l?void 0:l.draw))?void 0:e.tournamentCategory)?i:void 0},d=(l,n,e)=>null!=e&&[...(0,t.f0)(l),...(0,t.f0)(n)].some(l=>{var n;return(null==l||null==(n=l.user)?void 0:n.id)!=null&&String(l.user.id)===String(e)}),o=l=>
1{if(null==l.userId||!l.bothTeamsHaveLineup)return!1;let n=u(l.categoryFlags)&&(l.isCaptainTeam1||l.isCaptainTeam2),e=r(l.categoryFlags)&&d(l.team1Entry,l.team2Entry,l.userId);return n||e}},84852:(l,n,e)=>{e.d(n,{T:()=>a});var t=e(25398),u=e(67738),r=e(50567);let i=l=>{let n=null==l?void 0:l.mainMatch,e=Array.isArray(n)?n[0]:null;if(null==e||"object"!=typeof e)return{team1Id:void 0,team2Id:void 0};let t="entry1"in e?e.entry1:null,u="entry2"in e?e.entry2:null,r=Array.isArray(t)?t[0]:t,i=Array.isArray(u)?u[0]:u;return{team1Id:null!=r&&"object"==typeof r&&"team"in r&&null!=r.team&&"object"==typeof r.team&&"id"in r.team?r.team.id:void 0,team2Id:null!=i&&"object"==typeof i&&"team"in i&&null!=i.team&&"object"==typeof i.team&&"id"in i.team?i.team.id:void 0}},a=l=>{var n,e;let{team1Id:a,team2Id:d}=i(l),{team1CaptainData:o,team2CaptainData:s}=(0,u.A)(l?a:void 0,l?d:void 0);return(0,t.useMemo)(()=>{var n,e,t,u;return l?(0,r.pr)((0,r.Np)(l),{teamCaptain1UserId:null!=(t=null==o||null==(n=o.findCaptainTeam)?void 0:n.id)?t:null,teamCaptain2UserId:null!=(u=null==s||null==(e=s.findCaptainTeam)?void 0:e.id)?u:null}):l},[l,null==o||null==(n=o.findCaptainTeam)?void 0:n.id,null==s||null==(e=s.findCaptainTeam)?void 0:e.id])}}}]);

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.