!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="4081d808-1a2e-4327-84ee-a71c91c52b41",e._sentryDebugIdIdentifier="sentry-dbid-4081d808-1a2e-4327-84ee-a71c91c52b41")}catch(e){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4985],{5276:(e,t,s)=>{s.d(t,{Ck:()=>y,PM:()=>_,RV:()=>f,Sb:()=>b});var i=s(6029),l=s(10292),a=s(21377),n=s(41249),r=s(55729),o=s(90248),d=s(65789),c=s(62859),u=s(54409),p=s(76868),h=s(70591),x=s(24159);let g={[a.evQ.Missing]:"error.default",[a.evQ.Doubtful]:"sofaSingles.value"},m=e=>{let t=g[e.type];switch(e.reason){case a.s2G.Injured:case a.s2G.Ill:return(0,i.jsx)(u.NcS,{icon:"cross",fill:t});case a.s2G.Suspended:return(0,i.jsx)(u.NcS,{icon:"suspended",fill:t});case a.s2G.YellowCard:return(0,i.jsx)(u.NcS,{icon:"card",fill:"scoreRating.s65"});case a.s2G.YellowRedCard:return(0,i.jsx)(u.NcS,{icon:"card-double-yellow"});case a.s2G.RedCard:return(0,i.jsx)(u.NcS,{icon:"card",fill:"error.default"});case a.s2G.OnLoan:return(0,i.jsx)(u.NcS,{icon:"on-loan",fill:t});case a.s2G.Other:default:return(0,i.jsx)(u.NcS,{icon:"player",fill:t})}},f=(e,t)=>t===a.s2G.OnLoan?"missingplayer.onloan":e===a.evQ.Missing?-1!==[a.s2G.Suspended,a.s2G.YellowCard,a.s2G.YellowRedCard,a.s2G.RedCard].indexOf(t)?"player_status_suspended":"injury_status_out":"injury_status_doubtful";function y(e){let{missingPlayer:t}=e,s=g[t.type];return(0,i.jsxs)(n.so,{align:"center",w:"fit-content",mt:"xs",children:[m(t),(0,i.jsx)(n.EY,{ml:2,lineHeight:"100%",font:"assistive.default",color:s,as:"div",children:(0,i.jsx)(o.A,{id:f(t.type,t.reason)})})]})}function j(e){let{missingPlayer:t,isLast:s}=e,a=(0,r.useContext)(c.Ws);return(0,i.jsx)(h.uc,{player:t.player,sportSlug:a,children:(0,i.jsxs)(n.so,{hoverBg:"surface.s2",cursor:"pointer",children:[(0,i.jsx)(n.az,{px:"lg",py:"sm",children:(0,i.jsx)(l.t,{size:40,id:t.player.id,name:t.player.name})}),(0,i.jsx)(n.so,{borderBottom:s?void 0:"onSurface.nLv4",align:"center",flex:"1 1 auto",mr:"lg",children:(0,i.jsxs)(n.az,{flex:"1 1 auto",children:[(0,i.jsx)(n.EY,{block:!0,font:"body.medium",color:"onSurface.nLv1",mr:"xs",children:(0,i.jsx)(x.c,{entity:t.player})}),(0,i.jsx)(y,{missingPlayer:t})]})})]})})}function v(e){let{missingPlayers:t}=e;return(null==t?void 0:t.length)?(0,i.jsx)(i.Fragment,{children:t.map((e,s)=>(0,i.jsx)(j,{missingPlayer:e,isLast:s===t.length-1},e.player.id))}):(0,i.jsx)(p.p,{graphic:"no-data",descriptionMessageId:"no_missing_players"})}function b(e){let{missingPlayers:t}=e;return(null==t?void 0:t.length)?(0,i.jsxs)(d.Zp,{isInverseDesktop:!0,children:[(0,i.jsx)(d.Zp.Header,{titleId:"injuries_and_suspensions",as:"h4"}),(0,i.jsx)(v,{missingPlayers:t}),(0,i.jsx)(d.Zp.Footer,{defaultHeight:"sm"})]}):null}function _(e){let{left:t,right:s}=e,l=t&&t.length>0,a=s&&s.length>0;return l||a?(0,i.jsxs)(d.Zp,{isInverseDesktop:!0,children:[(0,i.jsx)(d.Zp.Header,{titleId:"injuries_and_suspensions"}),(0,i.jsxs)(n.so,{pt:"sm",pb:"md",children:[(0,i.jsx)(n.az,{flex:"1 1 50%",children:(0,i.jsx)(v,{missingPlayers:t})}),(0,i.jsx)(n.cG,{mt:"sm",mb:"md",vertical:!0,mx:"sm"}),(0,i.jsx)(n.az,{flex:"1 1 50%",children:(0,i.jsx)(v,{missingPlayers:s})})]})]}):null}},5326:(e,t,s)=>{s.d(t,{EN:()=>o,Oi:()=>r,aS:()=>l,sI:()=>n,v1:()=>a});var i=s(21377);let l="goalkeeperGroup",a="goalkeepersGroup",n="G",r={[i.QCR.Football]:{summaryGroup:"rating",attackGroup:"rating",defenceGroup:"rating",passingGroup:"rating",duelsGroup:"rating",goalkeeperGroup:"rating"},[i.QCR.Basketball]:{summaryGroup:"points",pointsGroup:"points",reboundsGroup:"rebounds",otherGroup:"assists"},[i.QCR.Handball]:{playersGroup:"goals",goalkeepersGroup:"goalkeeperEfficiencyPercentage"},[i.QCR.IceHockey]:{summaryGroup:"goals",attackingGroup:"goals",defensiveGroup:"blocked",goalkeeperGroup:"goalkeeperEfficiencyPercentage",otherGroup:"plusMinus"},[i.QCR.AmericanFootball]:{passingGroup:"passingYards",rushingGroup:"rushingAttempts",receivingGroup:"receivingReceptions",defensiveGroup:"defensiveCombineTackles",interceptionsGroup:"defensiveInterceptions",fumblesGroup:"fumbleFumbles",kickingGroup:"kickingTotalPoints",puntingGroup:"puntingTotal",kickReturnsGroup:"kickReturnsTotal",puntReturnsGroup:"puntReturnsTotal"}},o={[i.QCR.Football]:["G","D","M","F"],[i.QCR.Basketball]:["G","GF","FG","F","FC","CF","C"],[i.QCR.IceHockey]:["F","C","L","R","M","D","G"],[i.QCR.AmericanFootball]:["QB","RB","WR","TE","FB","OT","OG","G","C","T","OL","SS","FS","DB","CB","NT","DT","DE","OLB","LB","ILB","DL","SAF","MLB","P","LS","K","PR"],[i.QCR.Baseball]:["P","SP","RP","CP","RHP","LHP","RHS","LHS","LHR","RHR","C","DH","PH","B","PR","BR","1B","2B","3B","SS","IF","UT","UI","LF","CF","RF","OF","UO"]}},5998:(e,t,s)=>{s.d(t,{A:()=>C});var i=s(6029),l=s(33144),a=s(21377),n=s(41249),r=s(55729),o=s(16620),d=s(48886),c=s(70591),u=s(94604),p=s(61234),h=s(91407),x=s(12605),g=s(19991),m=s(90248),f=s(62859),y=s(54409),j=s(54917),v=s(84942),b=s(73488),_=s(99326);let w=e=>{let{summary:t,type:s}=e;return(0,i.jsxs)(n.so,{align:"center",mt:"xs","data-testid":"lineups_sub_info",children:[(0,i.jsx)(b.FU,{isInjury:t.isInjury}),(0,i.jsx)(n.EY,{font:"assistive.default",color:"onSurface.nLv3",mx:"xxs",ml:"xs",children:t.time&&"".concat(t.time,"'")}),(0,i.jsxs)(n.EY,{font:"assistive.default",color:"onSurface.nLv3",mx:"xxs",children:[(0,i.jsx)(m.A,{id:"out"===s?"substitution.in":"substitution_out"}),": \xa0",t.forPlayer]})]})};function k(e){var t,s,l,o,d,u,p;let{player:k,onClick:C,incidents:S,hasRating:A,isLast:P,isNotStarted:H,highlightStarter:I=!0,isPlayerOfTheMatch:z}=e,M=(null==k||null==(t=k.statistics)?void 0:t.rating)?Number(k.statistics.rating):void 0,{name:T,id:R}=k.player,V=(0,r.useMemo)(()=>S?(0,_.h$)({id:k.player.id,incidents:S,useShortName:k.substitute}):{},[k,S]),L=(0,v.z)(k.player),O=(0,_.sP)(L,k.captain,!0),E=(0,r.useContext)(f.Ws),G=E===a.QCR.Cricket,N="rtl"===document.dir,F=!k.substitute&&I;return!M&&H&&k.avgRating&&(M=k.avgRating),(0,i.jsx)(c.uc,{player:k.player,onClick:C,"data-testid":"lineups_player",sportSlug:E,children:(0,i.jsxs)(n.so,{hoverBg:"surface.s2",cursor:"pointer",children:[(0,i.jsx)(n.az,{py:"xxs",children:(0,i.jsx)(n.az,{w:4,h:"100%",bg:F?"sofaSingles.value":"transparent"})}),(0,i.jsxs)(n.az,{position:"relative",pl:"md",pr:"lg",py:"sm",children:[(0,i.jsx)(h.t,{size:40,id:R,name:T}),z&&(0,i.jsx)(y.ue7,{position:"absolute",fill:(0,g.Et)(null==(s=k.statistics)?void 0:s.rating),bottom:8,left:16,w:16,h:16}),F&&(0,i.jsx)(n.az,{position:"absolute",bottom:4,left:"50%",style:{transform:N?"translateX(50%)":"translateX(-50%)"},bg:"sofaSingles.value",br:6,children:(0,i.jsx)(n.EY,{px:"6px",font:"assistive.micro",color:"surface.s1",as:"div",children:(0,i.jsx)(m.A,{id:"starter"})})})]}),(0,i.jsxs)(n.so,{borderBottom:P?void 0:"onSurface.nLv4",align:"center",flex:"1 1 auto",mr:"lg",children:[(0,i.jsxs)(n.az,{flex:"1 1 auto",children:[(0,i.jsxs)(n.so,{title:O,align:"center",children:[(0,i.jsxs)(n.EY,{font:"body.medium",color:"onSurface.nLv1",mr:"xs",children:[k.jerseyNumber&&(0,i.jsx)(n.az,{as:"bdi",mr:"xs","data-testid":"lineups_number",children:k.jerseyNumber}),(0,i.jsx)(n.az,{as:"span","data-testid":"lineups_name",children:O})]}),(0,i.jsx)(b.AG,{...V}),(0,i.jsx)(b.X0,{...V})]}),(null==(l=V.substitutionIn)?void 0:l.time)&&(null==(o=V.substitutionIn)?void 0:o.forPlayer)&&(0,i.jsx)(w,{summary:V.substitutionIn,type:"in"}),(null==(d=V.substitutionOut)?void 0:d.time)&&(null==(u=V.substitutionOut)?void 0:u.forPlayer)&&(0,i.jsx)(w,{summary:V.substitutionOut,type:"out"}),G&&k.position&&(0,i.jsx)(n.EY,{font:"assistive.default",color:"onSurface.nLv3",mx:"xxs",ml:"xs",children:(0,i.jsx)(j.F,{id:k.position})})]}),A||k.avgRating?(0,i.jsx)(n.az,{"data-testid":"lineups_rating",children:M||(null==(p=V.substitutionIn)?void 0:p.time)?(0,i.jsx)(x.A,{rating:M,format:A?"box":"sideBox"}):null}):null]})]})})}function C(e){let{players:t,team:s,event:h,manager:x,incidents:g,showLastMatches:m,hasTopBorder:f,hideTeamHeader:y,highlightStarters:j=!0,hasRating:v,playerOfTheMatchId:b}=e,_=h.tournament.category.sport.slug,{openEventPlayerStatistics:w}=(0,o.d)(),C=(0,r.useCallback)(e=>t=>{(m||h.hasEventPlayerStatistics)&&(t.preventDefault(),w({event:h,player:e},d._.Lineups))},[h,t,w]),S=t.length>0,A=!!x,P=_===a.QCR.Football;return S||A?(0,i.jsxs)(n.az,{pt:"sm",pb:["sm","md"],flex:"1 1 50%",borderTop:f?"onSurface.nLv4":void 0,children:[!y&&!P&&(0,i.jsx)(c.gT,{team:s,sport:_,children:(0,i.jsxs)(n.so,{align:"center",hoverBg:"surface.s2",cursor:"pointer",children:[(0,i.jsx)(n.az,{px:"lg",py:"sm",children:(0,i.jsx)(l.p,{id:s.id,name:s.name,size:40})}),(0,i.jsx)(n.az,{children:(0,i.jsx)(n.EY,{font:"display.large",children:(0,i.jsx)(u.Rm,{team:s})})})]})}),A&&!P&&(0,i.jsx)(p.A,{manager:x,isBorderHidden:!S,incidents:null==g?void 0:g.filter(e=>e.manager)}),t.map((e,s)=>(0,i.jsx)(k,{player:e,incidents:g,hasRating:v,onClick:C(e.player),isNotStarted:h.status.type===a.XUj.NotStarted,isLast:s===t.length-1,highlightStarter:j,isPlayerOfTheMatch:b===e.player.id},e.player.id))]}):null}},12174:(e,t,s)=>{s.d(t,{f:()=>b,Y:()=>n});var i=s(21377),l=s(45860),a=s(71046);function n(e){let t=e.tournament.category.sport.slug!==i.QCR.Football||e.status.type!==i.XUj.Finished,{data:s,isLoading:n}=(0,l.Ay)(t?null:i.bnp.bestPlayersSummary(e.id),(0,a.rf)(e)),r=null==s?void 0:s.playerOfTheMatch,o=null==s?void 0:s.bestHomeTeamPlayers.find(e=>e.player.id===(null==r?void 0:r.player.id));return{isLoading:!t&&n,bestPlayer:(null==r?void 0:r.label)==="rating"?r:void 0,team:r?o?e.homeTeam:e.awayTeam:void 0}}var r=s(6029),o=s(32190),d=s(21501),c=s(41249),u=s(90248),p=s(65789),h=s(54409),x=s(61703),g=s(59754),m=s(16620),f=s(48886);function y(){return(0,r.jsx)("svg",{width:"133",height:"120",viewBox:"0 0 133 120",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)("g",{id:"Symbols",children:(0,r.jsx)("g",{id:"Cards/Player-Of-The-Season-Card-",children:(0,r.jsxs)("g",{id:"Pattern-Left",children:[(0,r.jsx)("path",{id:"Path",d:"M56.9883 114H75.9883V133H56.9883V114Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsxs)("g",{id:"Group",opacity:"0.8",children:[(0,r.jsx)("path",{id:"Path_2",d:"M38 114H57V133H38V114Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_3",d:"M76 95.0001H95V114H76V95.0001Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_4",d:"M95 95.0001H114V114H95V95.0001Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_5",d:"M57 56.9998H76V76H57V56.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_6",d:"M95 56.9998H114V76H95V56.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_7",d:"M114 56.9998H133V76H114V56.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_8",d:"M0 0H19V19H0V0Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_9",d:"M57 0H76V19H57V0Z",fill:"var(--primary-default)",fillOpacity:"0.15"})]}),(0,r.jsxs)("g",{id:"Group_2",opacity:"0.5",children:[(0,r.jsx)("path",{id:"Path_10",d:"M76 114H95V133H76V114Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_11",d:"M0 95H19V114H0V95Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_12",d:"M57 95H76V114H57V95Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_13",d:"M76 75.9999H95V94.9996H76V75.9999Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_14",d:"M95 75.9999H114V94.9996H95V75.9999Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_15",d:"M38 56.9998H57V75.9999H38V56.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_16",d:"M76 56.9998H95V75.9999H76V56.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_17",d:"M38 37.9998H57V56.9998H38V37.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_18",d:"M76 37.9998H95V56.9998H76V37.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_19",d:"M0 18.9999H19V37.9999H0V18.9999Z",fill:"var(--primary-default)",fillOpacity:"0.15"})]})]})})})})}function j(){return(0,r.jsx)("svg",{width:"133",height:"120",viewBox:"0 0 133 120",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)("g",{id:"Symbols",children:(0,r.jsx)("g",{id:"Cards/Player-Of-The-Season-Card-",children:(0,r.jsx)("g",{id:"Group-9",children:(0,r.jsxs)("g",{id:"Pattern-Right",children:[(0,r.jsx)("path",{id:"Path",d:"M76.0117 114H57.0117V133H76.0117V114Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsxs)("g",{id:"Group",opacity:"0.5",children:[(0,r.jsx)("path",{id:"Path_2",d:"M57 114H38V133H57V114Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_3",d:"M133 94.9998H114V114H133V94.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_4",d:"M76 94.9998H57V114H76V94.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_5",d:"M57 76.0002H38V94.9998H57V76.0002Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_6",d:"M38 76.0002H19V94.9998H38V76.0002Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_7",d:"M95 57.0001H76V75.9997H95V57.0001Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_8",d:"M57 57.0001H38V75.9997H57V57.0001Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_9",d:"M95 38H76V57.0001H95V38Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_10",d:"M57 38H38V57.0001H57V38Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_11",d:"M133 19H114V37.9999H133V19Z",fill:"var(--primary-default)",fillOpacity:"0.15"})]}),(0,r.jsxs)("g",{id:"Group_2",opacity:"0.8",children:[(0,r.jsx)("path",{id:"Path_12",d:"M95 114H76V133H95V114Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_13",d:"M57 94.9998H38V114H57V94.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_14",d:"M38 94.9998H19V114H38V94.9998Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_15",d:"M76 57.0001H57V75.9997H76V57.0001Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_16",d:"M38 57.0001H19V75.9997H38V57.0001Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_17",d:"M18.9999 57.0001H0V75.9997H18.9999V57.0001Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_18",d:"M133 0H114V18.9999H133V0Z",fill:"var(--primary-default)",fillOpacity:"0.15"}),(0,r.jsx)("path",{id:"Path_19",d:"M76 0H57V18.9999H76V0Z",fill:"var(--primary-default)",fillOpacity:"0.15"})]})]})})})})})}let v=e=>{let{bestPlayer:t,team:s}=e;return(0,r.jsxs)(c.so,{p:"lg",align:"center",justify:"space-between",children:[(0,r.jsxs)(c.so,{align:"center",children:[(0,r.jsx)(o.tg,{id:t.player.id,name:t.player.name,h:48,w:48}),(0,r.jsxs)(c.az,{ml:"sm",children:[(0,r.jsx)(c.EY,{font:"display.medium",mb:"xs",block:!0,children:t.player.name}),(0,r.jsxs)(c.so,{align:"center",children:[(0,r.jsx)(o.pY,{id:s.id,name:s.name,h:16,w:16,mr:"xs"}),(0,r.jsx)(c.EY,{font:"assistive.default",color:"onSurface.nLv3",children:(0,r.jsx)(u.A,{id:s.slug,defaultMessage:s.name})})]})]})]}),(0,r.jsx)(o.GW,{rating:t.value})]})};function b(e){let{event:t}=e,{isLoading:s,bestPlayer:l,team:a}=n(t),{openEventPlayerStatistics:b}=(0,m.d)(),_=(0,g.Z)(t,"playerOfTheMatch"),w=(0,d.hX)();return t.tournament.category.sport.slug===i.QCR.Football&&t.status.type===i.XUj.Finished&&(w||s)?(0,r.jsx)(p.Zp,{isInverseDesktop:!0,children:(0,r.jsx)(c.az,{h:120})}):s||l?(0,r.jsx)(x.b,{entityId:t.id,isInverseDesktop:!0,branding:_,location:"event_potm",children:(0,r.jsxs)(c.so,{position:"relative",h:120,justify:"space-between",bg:"surface.s2",elevation:[2,void 0],br:_?"0 0 lg lg":"lg",overflow:"hidden",cursor:"pointer",onClick:()=>l&&b({event:t,player:l.player},f._.PlayerOfTheMatch),children:[(0,r.jsx)(y,{}),(0,r.jsx)(j,{}),(0,r.jsxs)(c.az,{position:"absolute",top:0,left:0,w:"100%",children:[(0,r.jsxs)(c.so,{pt:"md",px:"lg",pb:"xs",align:"center",children:[(0,r.jsx)(h.ue7,{mr:"sm",w:24,h:24,fill:(0,o.Et)(null==l?void 0:l.value)}),(0,r.jsx)(c.EY,{font:"display.medium",lineHeight:"24px",children:(0,r.jsx)(u.A,{id:"details.manOfMatch"})})]}),(0,r.jsx)(c.az,{minH:80,children:l&&a&&(0,r.jsx)(v,{bestPlayer:l,team:a})})]})]})}):null}},12785:(e,t,s)=>{s.d(t,{Ko:()=>Q,g9:()=>D});var i=s(6029),l=s(4967),a=s(41249),n=s(90248),r=s(12047),o=s(55529);function d(e){let{isNational:t,eventTimestamp:s,isHorizontalLayout:d,onTabChange:c,order:u}=e,p=(0,r.Ay)({isSportMenuVisible:!0,isInMobileTabs:!0}),h=1>(0,l.CF)(s),x=Object.values(o.kA).filter(e=>(e!==o.kA.MarketValue||!!h)&&(t?e!==o.kA.Nationality:e!==o.kA.Club));return(0,i.jsxs)(a.PI,{top:p,w:"100%",order:u,zIndex:a.Py.Sticky-1,bg:"surface.s1",children:[(0,i.jsx)(a.tU,{variant:"quaternary",initialValue:o.kA.Performance,onChange:c,children:(0,i.jsx)(a.tU.List,{px:d?void 0:"xs",py:"sm",children:x.map(e=>(0,i.jsx)(a.tU.Tab,{tabKey:e,children:(0,i.jsx)(n.A,{id:o.fP[e]})},"tab-".concat(e)))})}),!d&&(0,i.jsx)(a.cG,{})]})}var c=s(40237),u=s(21377),p=s(55729),h=s(41735),x=s(7322),g=s(34851),m=s(50154),f=s(3518),y=s(85685),j=s(94604);let v=function(){let[e,t]=(0,p.useState)(320);return(0,p.useEffect)(()=>{t(window.innerWidth);let e=()=>t(window.innerWidth);return window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)},[]),e};function b(e){let{team:t,avgRating:s,teamSide:l,formation:r,jersey:d,isNotStarted:b,avgMessageId:_,avgData:w,chipType:k,order:C,isHorizontalLayout:S}=e,A=[o.kA.Age,o.kA.MarketValue,o.kA.Height].includes(k)&&w,P=v(),H=(0,p.useContext)(h.ThemeContext),{isAdsTestTreatment:I}=(0,m.Q)(),z="rtl"===H.settings.textDirection;return(0,i.jsx)(a.az,{w:"100%",h:"72px",maxH:"82px",br:[void 0,"lg"],flex:S?"1 1 45%":"1 1 100%",backgroundColor:S?"surface.s2":void 0,m:I?"left"===l?z?"0 sm sm xs":"0 xs sm sm":z?"0 xs sm sm":"0 sm sm xs":S?"left"===l?z?"0 0 sm xs":"0 xs sm 0":z?"0 xs sm 0":"0 0 sm xs":void 0,p:S?"0 sm":"sm sm",order:C,children:(0,i.jsxs)(a.so,{w:"100%",h:"100%",justify:"space-between",align:"center",direction:"left"!==l&&S?"row-reverse":"row",children:[(0,i.jsxs)(a.so,{h:"100%",align:"center",direction:"left"!==l&&S?"row-reverse":"row",children:[P>360&&!I&&(0,i.jsx)(c.p,{id:t.id,size:32,m:"left"===l?"0 sm 0 0":"0 0 0 sm"}),(0,i.jsxs)(a.so,{direction:"column",gap:"xs",align:"left"!==l&&S?"flex-end":"flex-start",ml:"sm",children:[(0,i.jsxs)(a.so,{gap:"sm",align:"center",h:"100%",grow:1,children:[(0,i.jsx)(a.EY,{font:"display.medium",lineHeight:"20px",lineClamp:2,children:(0,i.jsx)(j.Rm,{team:t,short:!0})}),s&&(0,i.jsxs)(a.so,{align:"center",h:"100%",children:[(0,i.jsx)(c.G,{rating:s,format:"sideBox"}),(0,i.jsx)(x.D,{type:b?g.J.AverageRatingTeam:g.J.AverageRating,rating:s,renderImage:e=>(0,i.jsx)(c.p,{id:t.id,...e})})]})]}),A&&(0,i.jsxs)(a.so,{direction:"row",justify:"left"!==l&&S?"flex-end":"flex-start",align:"center",wrap:"wrap",children:[(0,i.jsxs)(a.EY,{font:"body.small",lineHeight:"16px",color:"onSurface.nLv3",children:[(0,i.jsx)(n.A,{id:_})," • "]}),"\xa0",(0,i.jsx)(a.EY,{font:"display.micro",fontWeight:700,lineHeight:"14px",children:k===o.kA.Age?(0,i.jsxs)(i.Fragment,{children:[w," ",(0,i.jsx)(n.A,{id:"years_short"})]}):k===o.kA.MarketValue?(0,i.jsx)(y.o,{parsedMoney:(0,u.oaz)(w)}):k===o.kA.Height?(0,i.jsx)(f.Z,{value:w,fromUnit:"cm"}):void 0})]})]})]}),(0,i.jsxs)(a.so,{minW:"56px",w:"56px",direction:"column",justify:"center",align:"center",m:"xs",children:[(0,i.jsx)(a.EY,{font:"display.small",color:"onSurface.nLv1",children:r}),(0,i.jsx)(a.so,{w:"36px",h:"36px",br:"sm",backgroundColor:"neutral.highlight",justify:"center",align:"center",children:(0,i.jsx)(a._V,{w:"28px",h:"32px",src:d,alt:"Team jersey"})})]})]})})}function _(e){let{eventStatus:t,isConfirmed:s,shareButton:l,order:r,isHorizontalLayout:o}=e;return[u.XUj.Finished,u.XUj.InProgress].includes(t)?null:(0,i.jsxs)(a.so,{order:r,pt:"md",pb:"xs",px:["sm",o?"xs":"sm"],w:"100%",justify:[l?"space-between":"center","space-between"],align:"center",children:[(0,i.jsx)(a.EY,{font:"display.medium",lineHeight:"24px",children:(0,i.jsx)(n.A,{id:s?"football_confirmed_lineups":"football_possible_lineups"})}),l]})}var w=s(44194),k=s(16620),C=s(48886),S=s(95522);let A="rgba(255, 255, 255,0.3)",P=(0,h.default)(a.so).withConfig({componentId:"sc-f78c658b-0"})(["position:relative;width:",";flex:",";max-height:","px;background-color:",";",";"],e=>e.isHorizontalLayout?"50%":"calc(100% - 16px)",e=>e.isHorizontalLayout?"1 1 50%":"1 1 ".concat(430,"px"),430,e=>e.theme.colors.graphicsTerrain.footballLineups,e=>{let t="border: 2px solid ".concat(A,";");return e.isHorizontalLayout?"rtl"===e.theme.settings.textDirection?"right"===e.side&&(t+="border-right: none;"):"left"===e.side&&(t+="border-right: none;"):"left"===e.side&&(t+="border-bottom: none;"),t}),H=(0,h.default)(a.so).withConfig({componentId:"sc-f78c658b-1"})(["z-index:",";flex:",";"," flex-direction:",";",";"],a.Py.Button,e=>e.isHorizontalLayout?"1 1 50%":"1 1 ".concat(430,"px"),e=>e.isHorizontalLayout?"height: ".concat(430,"px;"):"max-height: ".concat(430,"px;"),e=>{let t=e.isHorizontalLayout?"row":"column";return"right"===e.side&&(t=e.isHorizontalLayout?"row-reverse":"column-reverse"),t},e=>{let t="";return e.isHorizontalLayout?"rtl"===e.theme.settings.textDirection?"right"===e.side?t+="border-right: none;":t+="border-left: none;":"left"===e.side?t+="border-right: none;":t+="border-left: none;":"left"===e.side?t+="border-bottom: none;":t+="border-top: none;",t}),I=h.default.div.withConfig({componentId:"sc-f78c658b-2"})(["position:absolute;z-index:",";top:0;left:0;width:100%;height:100%;"," user-select:none;"," .goal{position:absolute;z-index:",";left:calc(50% - 80px);top:-1px;","}.center{position:absolute;z-index:",";bottom:-1px;left:calc(50% - 64px);","}.c1,.c2{position:absolute;z-index:",";top:0;}.c1{left:0;}.c2{right:0;","}.logo{position:absolute;z-index:",";bottom:16px;right:12px;}"],a.Py.Backdrop,e=>e.isHorizontalLayout&&"height: ".concat(428,"px;"),e=>"rtl"===e.theme.settings.textDirection&&e.isHorizontalLayout?"left"===e.side&&"transform: rotate(180deg);":"right"===e.side&&"transform: rotate(180deg);",a.Py.Backdrop,e=>e.isHorizontalLayout&&"\n transform-origin: top left;\n transform: translateY(160px) rotate(-90deg);\n top: calc(50% - 80px);\n left: -1px;\n ",a.Py.Backdrop,e=>e.isHorizontalLayout&&"\n transform: rotate(-90deg);\n transform-origin: top;\n top: 50%;\n right: -1px;\n left: unset;\n ",a.Py.Backdrop,e=>e.isHorizontalLayout&&"\n transform: rotate(180deg);\n top: unset;\n right: unset;\n bottom: 0;\n left: 0;\n ",a.Py.Backdrop);var z=s(10292),M=s(84942);function T(e){let{value:t,eventTimestamp:s,characteristic:r}=e;return(0,i.jsx)(a.so,{border:t?"onColor.primary":"onSurface.nLv3",minW:"24px",maxH:"16px",justify:"center",align:"center",px:"xs",bg:"surface.s1",position:"absolute",top:"34px",children:(0,i.jsx)(a.EY,{font:"assistive.default",lineHeight:"16px",color:t?void 0:"onSurface.nLv3",style:{textWrap:"nowrap"},children:t?(0,i.jsxs)(i.Fragment,{children:[r===o.kA.Age&&(0,i.jsxs)(i.Fragment,{children:[(0,l.Dr)(t,s)," ",(0,i.jsx)(n.A,{id:"years_shorter"})]}),r===o.kA.MarketValue&&(0,i.jsx)(y.o,{parsedMoney:(0,u.oaz)(t)}),r===o.kA.Height&&"number"==typeof t&&(0,i.jsx)(f.Z,{value:t,fromUnit:"cm"})]}):"-"})})}var R=s(87827),V=s(54409);let L=e=>{let{incident:t,isNumber:s}=e;return(0,i.jsx)(a.so,{br:"50%",backgroundColor:s?t.color:"onColor.primary",border:s?"onColor.primary":"neutral.highlight",h:s?"14px":"16px",w:s?"14px":"16px",justify:"center",align:"center",children:s?(0,i.jsx)(a.EY,{font:"display.micro",fontWeight:700,lineHeight:"14px",color:"onColor.primary",children:t.count}):"matchMVP"===t.name?(0,i.jsx)(V.ue7,{w:12,h:12,fill:t.color}):t.icon&&(0,i.jsx)(V.NcS,{icon:t.icon,width:12,height:12,fill:t.color})})};function O(e){let{alignment:t,incidents:s,compactDisplay:l}=e;return(0,i.jsx)(a.so,{w:"right"===t?void 0:"16px",h:"50px",position:"relative",direction:"column",maxW:"22px",minW:"16px",gap:"1px",children:s.map(e=>e.isVisible?(0,i.jsxs)(a.so,{align:"center",children:[(0,i.jsx)(L,{incident:e}),"right"===t&&e.count&&e.count>=2&&(0,i.jsx)(a.so,{position:"absolute",gap:"1px",left:l?"1px":"8px",children:(0,i.jsx)(L,{incident:e,isNumber:!0})})]},e.name):(0,i.jsx)(a.az,{h:16},e.name))})}var E=s(99326);function G(e){var t;let{player:s,incidents:l,isMatchMVP:n,lineupsType:r,compactDisplay:d,hasRating:c}=e,{playerLeftStatistics:u,playerRightStatistics:p}=(0,E.H_)(s,l,n),h=(0,E.lV)(s,r);return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(a.so,{w:"100%",h:"100%",px:d?void 0:"3px",position:"absolute",justify:r===o.V7.Confirmed?"space-between":"flex-start",children:[u&&(0,i.jsx)(O,{alignment:"left",incidents:u}),r===o.V7.Confirmed&&p&&(0,i.jsx)(O,{alignment:"right",incidents:p,compactDisplay:d})]}),c&&(0,i.jsx)(a.so,{position:"absolute",top:"33px",children:(0,i.jsx)(R.G,{rating:h,format:"box",decimalPoints:(null==(t=s.statistics)?void 0:t.rating)?void 0:2,size:"sm",isOnColor:!0})})]})}var N=s(49519);function F(e){var t,s;let{player:l,chipType:n}=e,r=null==(s=l.player)||null==(t=s.country)?void 0:t.alpha2;return(0,i.jsxs)(a.so,{p:"xxs",br:"xxs",bg:"onColor.primary",elevation:2,justify:"center",align:"center",position:"absolute",top:"31px",children:[n===o.kA.Club&&(0,i.jsx)(N.p,{id:null==l?void 0:l.teamId,size:16}),n===o.kA.Nationality&&(r?(0,i.jsx)(N.w,{alpha2:r,size:16}):(0,i.jsx)(a.az,{w:"lg",h:"lg",bg:"surface.s2",br:"50%"}))]})}let B=e=>{var t;let{player:s,isMatchMVP:l,incidents:n,chipType:r,lineupsType:d,numberOfPlayersInRow:c,eventTimestamp:u,hasRating:h}=e,{mediaBreakpoint:x,isDesktopMedium:g}=(0,w.$c)(),[m,f]=(0,p.useState)(),y=(0,M.z)(s.player,!0),j=r===o.kA.Performance,v=[o.kA.Club,o.kA.Nationality].includes(r),b=[o.kA.Age,o.kA.MarketValue,o.kA.Height].includes(r),_=(null==n?void 0:n.filter(e=>{var t;return(null==e||null==(t=e.player)?void 0:t.id)===s.player.id&&("red"===e.incidentClass||"yellowRed"===e.incidentClass)}).length)!==0&&j;return(0,p.useEffect)(()=>{var e,t,i;switch(r){case o.kA.Age:f(null==(e=s.player)?void 0:e.dateOfBirthTimestamp);break;case o.kA.MarketValue:f(null==(t=s.player)?void 0:t.proposedMarketValueRaw);break;case o.kA.Height:f(null==(i=s.player)?void 0:i.height)}},[r]),(0,i.jsxs)(a.so,{direction:"column",align:"center",children:[(0,i.jsxs)(a.so,{position:"relative",direction:"column",justify:"center",align:"center",w:"100%",h:"100%",maxW:"68px",maxH:"52px",children:[(0,i.jsx)(a.az,{w:"40px",h:"40px",br:"50%",bg:"surface.s0",children:(0,i.jsx)(z.t,{size:40,id:null==(t=s.player)?void 0:t.id,style:{opacity:_?.5:1}})}),j&&(0,i.jsx)(G,{player:s,incidents:n,isMatchMVP:l,lineupsType:d,compactDisplay:g||"xxs"===x&&5===c,hasRating:h}),v&&(0,i.jsx)(F,{player:s,chipType:r}),b&&(0,i.jsx)(T,{value:m,eventTimestamp:u,characteristic:r})]}),(0,i.jsxs)(a.EY,{font:"table.small",lineHeight:"12px",color:"onColor.primary",align:"center",mt:"md",px:"xs",w:"100%",block:!0,children:[(0,i.jsx)(a.EY,{font:"table.small",lineHeight:"12px",color:"onColor.secondary",display:"inline-block",mr:"xxs",children:s.jerseyNumber}),s.captain?"(c) ".concat(y):y]})]})};function D(e){let{side:t,linesColor:s,isHorizontalLayout:l}=e;return(0,i.jsxs)(I,{side:t,isHorizontalLayout:l,children:[(0,i.jsx)("div",{className:"goal",children:(0,i.jsxs)("svg",{version:"1.1",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0 0 160 70",width:"160",height:"70",children:[(0,i.jsx)("defs",{children:(0,i.jsx)("clipPath",{id:"cutoffRect",children:(0,i.jsx)("rect",{x:"0",y:"1",width:"160",height:"70"})})}),(0,i.jsxs)("g",{stroke:s,fill:"transparent",strokeWidth:"2",children:[(0,i.jsx)("rect",{clipPath:"url(#cutoffRect)",x:"1",y:"0",width:"158",height:"46"}),(0,i.jsx)("rect",{clipPath:"url(#cutoffRect)",x:"42",y:"0",width:"74",height:"24"}),(0,i.jsx)("path",{d:"M 39 46 A 50 50 0 0 0 119 46"})]})]})}),(0,i.jsx)("div",{className:"c1",children:(0,i.jsx)("svg",{viewBox:"0 0 14 14",height:"14",width:"14",children:(0,i.jsx)("circle",{stroke:s,fill:"transparent",strokeWidth:"2",cx:"0",cy:"0",r:"12"})})}),(0,i.jsx)("div",{className:"c2",children:(0,i.jsx)("svg",{viewBox:"0 0 14 14",height:"14",width:"14",children:(0,i.jsx)("circle",{stroke:s,fill:"transparent",strokeWidth:"2",cx:"14",cy:"0",r:"12"})})}),(0,i.jsx)("div",{className:"center",children:(0,i.jsx)("svg",{viewBox:"0 0 128 64",width:"128",height:"64",children:(0,i.jsx)("circle",{stroke:s,fill:"transparent",strokeWidth:"2",cx:"64",cy:"64",r:"62"})})})]})}function Y(e){let{teamSide:t,playerFormation:s,incidents:l,playerOfTheMatchId:n,playerCharacteristic:r,lineupsType:o,isHorizontalLayout:d,order:c,event:p,showLastMatches:x,hasRatings:g}=e,m="rtl"===(0,h.useTheme)().settings.textDirection,{openEventPlayerStatistics:f}=(0,k.d)(),{mediaBreakpoint:y,isDesktopMedium:j}=(0,w.$c)(),v=x||p.hasEventPlayerStatistics?e=>f({event:p,player:e.player},C._.Lineups):void 0,b=j||"xxs"===y&&5===s.length;return(0,i.jsxs)(P,{side:t,isHorizontalLayout:d,mx:d?0:"sm",order:c,children:[(0,i.jsx)(H,{side:t,isHorizontalLayout:d,children:s.map((e,c)=>{let h=d?t===(m?"left":"right")?"column":"column-reverse":t===(m?"right":"left")?"row":"row-reverse";return(0,i.jsx)(a.so,{flex:"1 1 auto",align:"center",justify:"space-evenly",direction:h,children:(0,i.jsx)(a.so,{w:d?void 0:"100%",h:d?"100%":void 0,justify:"space-evenly",direction:h,children:e.map(t=>(0,i.jsx)(a.so,{direction:"column",justify:"flex-start",align:"center",flex:"1 1 100%",w:b?"60px":void 0,maxW:[112,5===s.length?86:108],minW:"60px",maxH:"76px",pt:d?0:"6px",cursor:"pointer",onClick:()=>{v&&v(t)},children:(0,i.jsx)(a.az,{w:"100%",children:(0,i.jsx)(S.A,{player:v?void 0:t.player,sportSlug:u.QCR.Football,children:(0,i.jsx)(B,{player:t,isMatchMVP:t.player.id===n,incidents:l,chipType:r,lineupsType:o,numberOfPlayersInRow:e.length,eventTimestamp:p.startTimestamp,hasRating:!!g},t.player.id)},t.player.id)})},t.player.id))})},c)})}),(0,i.jsx)(D,{side:t,linesColor:A,isHorizontalLayout:d})]})}var U=s(62859),W=s(76410),Z=s(54863);let Q=(0,p.forwardRef)((e,t)=>{let{leftFormation:s,rightFormation:l,playerOfTheMatchId:n,shareButton:r}=e,{location:c,event:h,leftTeam:x,rightTeam:g}=(0,p.useContext)(U.y$),f=h.tournament.category.sport.slug,y=h.status.type===u.XUj.NotStarted&&f===u.QCR.Football,{isDesktop:j}=(0,w.$c)(),v=j&&c===U.cb.EventPage,[k,C]=(0,p.useState)(o.kA.Performance),[S,A]=(0,Z.ax)(e.lineups),{isAdsTestTreatment:P}=(0,m.Q)();if(!s||!l)return null;let H=(0,E.ZB)(s,l,h.startTimestamp),I=e.lineups.left.players.some(e=>!!e.avgRating)||e.lineups.right.players.some(e=>!!e.avgRating),z=[...s||[],...l||[]].some(e=>e.some(e=>{var t;return null==(t=e.statistics)?void 0:t.rating})),M=h.status.type===u.XUj.NotStarted,T=f===u.QCR.Football?h.status.type===u.XUj.NotStarted?I:z:void 0,R=h.status.type===u.XUj.Finished||e.confirmed?o.V7.Confirmed:o.V7.Possible,V=[o.kA.Age,o.kA.MarketValue,o.kA.Height].includes(k);return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(a.az,{px:P?"sm":void 0,children:[(0,i.jsx)(_,{isConfirmed:e.confirmed,eventStatus:h.status.type,shareButton:r,order:v?1:2,isHorizontalLayout:!!v}),(0,i.jsx)(d,{isNational:!!h.homeTeam.national&&!!h.awayTeam.national,eventTimestamp:h.startTimestamp,onTabChange:e=>{(0,W.ke)({action:"click",location:"event_lineups",type:e===o.kA.MarketValue?"market_value":e}),C(e)},order:v?2:1,isHorizontalLayout:!!v})]}),(0,i.jsxs)(a.so,{ref:t,position:"relative",w:"100%",direction:v?"row":"column",justify:"space-between",wrap:"wrap",children:[(0,i.jsx)(b,{team:x,teamSide:u.cxP.Left,formation:e.lineups.left.formation,jersey:e.lineups.leftJerseyUrls.player,chipType:k,avgRating:S,avgData:V?H[k].leftTeamValue:void 0,avgMessageId:V?H[k].messageId:void 0,order:3,isHorizontalLayout:v,isNotStarted:M}),(0,i.jsx)(Y,{teamSide:u.cxP.Left,playerFormation:s,incidents:e.incidents,playerOfTheMatchId:n,lineupsType:R,playerCharacteristic:k,showLastMatches:y,isHorizontalLayout:v,order:v?4:3,event:h,hasRatings:T}),(0,i.jsx)(Y,{teamSide:u.cxP.Right,playerFormation:l,incidents:e.incidents,playerOfTheMatchId:n,lineupsType:R,playerCharacteristic:k,showLastMatches:y,isHorizontalLayout:v,order:v?5:4,event:h,hasRatings:T}),(0,i.jsx)(b,{team:g,teamSide:u.cxP.Right,formation:e.lineups.right.formation,jersey:e.lineups.rightJerseyUrls.player,chipType:k,avgRating:A,avgData:V?H[k].rightTeamValue:void 0,avgMessageId:V?H[k].messageId:void 0,order:v?3:5,isHorizontalLayout:v,isNotStarted:M})]})]})})},16206:(e,t,s)=>{s.d(t,{A:()=>W});var i=s(6029),l=s(41249),a=s(55729),n=s(62859),r=s(73011),o=s(9489),d=s(21377),c=s(48886),u=s(5326);let p=e=>{let t=e.statistics;for(let e=0;e0)return!0}return!1},h=(e,t,s)=>t===d.QCR.Football&&e===u.aS?s.player.position===u.sI:t===d.QCR.Handball?e!==u.v1||p(s):t===d.QCR.IceHockey?e!==u.aS||p(s):t!==d.QCR.AmericanFootball||p(s),x=(e,t)=>{var s,i,l,a,n;return!!e.value&&null!=(s=t.statistics)&&!!s[e.value]||!!e.secondaryValue&&null!=(i=t.statistics)&&!!i[e.secondaryValue]||!!e.madesValue&&null!=(l=t.statistics)&&!!l[e.madesValue]||!!e.attemptsValue&&null!=(a=t.statistics)&&!!a[e.attemptsValue]||e.replacementValue&&!!(null==(n=t.statistics)?void 0:n[e.replacementValue])},g=(e,t,s)=>s===d.QCR.AmericanFootball?Object.keys(e).filter(s=>e[s].find(e=>!!t.left.players.find(t=>x(e,t))||!!t.right.players.find(t=>x(e,t)))):Object.keys(e),m=e=>{let t={};return Object.keys(e).forEach(s=>{t[s]={stat:e[s],dir:c.U.DESC}}),t};var f=s(16620),y=s(40237),j=s(90248),v=s(69559),b=s(54409),_=s(35474),w=s(70591),k=s(94493),C=s(24159),S=s(54917),A=s(85306);let P=e=>{let{teamId:t,teamName:s}=e;return(0,i.jsx)(l.XI.Cell,{children:(0,i.jsx)(l.az,{py:"xs",px:"sm",children:(0,i.jsx)(y.p,{id:t,name:s,size:24})})})},H=e=>{let{player:t,onClick:s}=e,a=(0,v.o)(),n=a===d.QCR.Basketball&&!!t.ejected;return(0,i.jsx)(l.XI.Cell,{children:(0,i.jsx)(w.uc,{player:t,onClick:e=>s(e,t),sportSlug:a,children:(0,i.jsxs)(l.so,{direction:"column",py:"sm",px:"lg",align:"flex-start",children:[(0,i.jsx)(l.EY,{font:"body.small",color:"onSurface.nLv1",hover:!0,children:(0,i.jsx)(C.c,{entity:t})}),n&&(0,i.jsx)(l.so,{bg:"error.default",display:"inline-flex",h:12,align:"center",br:"md",px:"sm",children:(0,i.jsx)(l.EY,{font:"assistive.micro",c:"surface.s1",lineHeight:1,children:(0,i.jsx)(j.A,{id:"basketball_player_ejected_long"})})})]})})})},I=e=>{let{statistic:t,isSortBy:s,position:a}=e,n=t.configStatsKey.replacementValue,r=n&&"number"==typeof t.stats[n]?n:t.configStatsKey.value,o=(0,_.Rs)(t.stats,t.configStatsKey);return(0,i.jsxs)(l.XI.Cell,{style:{position:"relative",whiteSpace:"nowrap"},children:[(0,i.jsx)(l.az,{position:"absolute",top:0,left:0,w:"100%",h:"100%",bg:s?"surface.s2":"transparent"}),(0,i.jsx)(l.EY,{py:"sm",px:"lg",font:"body.small",color:"onSurface.nLv1",align:"center",as:"div",position:"relative",children:r===A.K.ExpectedGoals?(0,i.jsx)(i.Fragment,{children:o||"-"}):r===A.K.Rating?(0,i.jsx)(l.so,{justify:"center",children:(0,i.jsx)(y.G,{rating:t.stats[r]})}):r===A.K.Position?a?(0,i.jsx)(S.F,{id:a,short:!0}):"-":r!==A.K.Notes?o:o.split("\n").map(e=>e.length?(0,i.jsx)("div",{children:e},e):null)})]})},z=e=>{let{filteredTeamId:t,onFilterClick:s,leftTeam:a,rightTeam:n}=e;return(0,i.jsx)(l.XI.HeadCell,{w:170,maxW:170,minW:160,children:(0,i.jsxs)(l.so,{py:"md",px:"sm",gap:"sm",align:"center",justify:"center",children:[(0,i.jsxs)(l.az,{minW:"fit-content",p:"xs",br:"20px",border:t?"none":"primary.highlight",bg:t?"surface.s2":"primary.highlight",onClick:()=>s(void 0),cursor:"pointer",children:[(0,i.jsx)(y.p,{id:a.id,name:a.name,size:24,style:{verticalAlign:"top"}}),(0,i.jsx)(l.EY,{font:"assistive.default",color:"onSurface.nLv3",mx:"xs",children:"+"}),(0,i.jsx)(y.p,{id:n.id,name:n.name,size:24,style:{verticalAlign:"top"}})]}),(0,i.jsx)(l.az,{p:"xs",br:"50%",border:t===a.id?"primary.highlight":"none",bg:t===a.id?"primary.highlight":"surface.s2",onClick:()=>s(a.id),cursor:"pointer",children:(0,i.jsx)(y.p,{id:a.id,name:a.name,size:24,style:{verticalAlign:"top"}})}),(0,i.jsx)(l.az,{p:"xs",br:"50%",border:t===n.id?"primary.highlight":"none",bg:t===n.id?"primary.highlight":"surface.s2",onClick:()=>s(n.id),cursor:"pointer",children:(0,i.jsx)(y.p,{id:n.id,name:n.name,size:24,style:{verticalAlign:"top"}})})]})})},M=e=>{let{statistic:t,sortConfig:s,onColumnClick:a,sport:n}=e,r=t.configStatsKey.replacementValue,o="";o=r&&"number"==typeof t.stats[r]?r:t.configStatsKey.value;let u=s.stat.value===t.configStatsKey.value,p=u&&s.dir===c.U.ASC,h=o===A.K.Notes;return(0,i.jsx)(l.XI.HeadCell,{onClick:()=>{o!==A.K.Notes&&a(t.configStatsKey)},style:{position:"relative"},children:(0,i.jsxs)(l.az,{minW:h?124:n===d.QCR.AmericanFootball?100:void 0,p:"xs",textAlign:"center",cursor:h?"default":"pointer",children:[(0,i.jsx)(l.so,{position:"absolute",top:0,left:0,w:"100%",h:"100%",bg:u?"surface.s2":"transparent"}),(0,i.jsx)(l.so,{minH:32,align:"center",justify:"center",position:"relative",children:(0,i.jsx)(l.EY,{font:"body.small",color:"onSurface.nLv3",align:"center",children:(0,i.jsx)(k.w,{id:o})})}),(0,i.jsx)(b.Bfd,{fill:h?"transparent":u?"primary.default":"onSurface.nLv4",style:{transition:"transform 0.3s ease-in-out",transform:" rotate(".concat(180*!!p,"deg)")}})]})})};var T=s(947),R=s(99586),V=s(50677),L=s(27892),O=s(4967);let E=(e,t,s)=>{let i=[];for(let l of e.players){let a=[];for(let s of t){let{statistics:t}=l;if(!e.players.every(e=>{var t;return!s.textualDescription&&!(null==(t=e.statistics)?void 0:t[s.value])&&s.hideIfNone})&&t){let e={stats:{},configStatsKey:{...s}};if(e.stats[s.value]=s.value in t?t[s.value]:0,"minutesPlayed"===s.value&&"number"==typeof e.stats[s.value]&&(e.stats[s.value]="".concat(e.stats[s.value],"'")),s.secondaryValue&&(e.stats[s.secondaryValue]=s.secondaryValue in t?t[s.secondaryValue]:0),s.madesValue&&(e.stats[s.madesValue]=s.madesValue in t?t[s.madesValue]:0),s.attemptsValue&&(e.stats[s.attemptsValue]=s.attemptsValue in t?t[s.attemptsValue]:0),s.textualDescription){let i=Object.keys(s.textualDescription),l={};for(let e of i)l[e]=Number(t[e]||0);e.stats[s.value]=l}s.replacementValue&&"number"==typeof t[s.replacementValue]&&(e.stats[s.replacementValue]=t[s.replacementValue]),a.push(e)}}i.push({player:{...l.player,...s(l.player.id),position:l.position,ejected:l.ejected},statistics:a})}return i},G=(e,t)=>{let s={};for(let i of e)if(i.statistics){if((t===d.QCR.Football||t===d.QCR.Basketball)&&!("minutesPlayed"in i.statistics)&&!("secondsPlayed"in i.statistics))continue;let e=Number(i.statistics.totalClearance||0)+Number(i.statistics.outfielderBlock||0)+Number(i.statistics.interceptionWon||0)+Number(i.statistics.totalTackle||0),l=Number(i.statistics.duelWon||0)+Number(i.statistics.duelLost||0),a=Number(i.statistics.aerialWon||0)+Number(i.statistics.aerialLost||0),n=l-a,r=i.statistics.aerialWon||l-n-Number(i.statistics.aerialLost||0),o=i.statistics.groundWon||Number(i.statistics.duelWon)-Number(r),c=Number(i.statistics.faceOffTaken||0),u=Number(i.statistics.kickingFgAttempts||0),p=i.statistics.minutesPlayed,h="-";!p&&i.statistics.secondsPlayed&&(t===d.QCR.IceHockey?h=(0,O.OV)(Number(i.statistics.secondsPlayed)):p=Math.floor(Number(i.statistics.secondsPlayed)/60));let x=0;"number"==typeof i.statistics.saves&&"number"==typeof i.statistics.gkShots&&i.statistics.gkShots>0&&(x=Number(i.statistics.saves)/Number(i.statistics.gkShots)*100),"number"==typeof i.statistics.saves&&"number"==typeof i.statistics.shotsAgainst&&i.statistics.shotsAgainst>0&&(x=Number(i.statistics.saves)/Number(i.statistics.shotsAgainst)*100);let g=0;"number"==typeof i.statistics.goals&&"number"==typeof i.statistics.shotsTaken&&i.statistics.shotsTaken>0&&(g=Number(i.statistics.goals)/Number(i.statistics.shotsTaken)*100);let m=0;(0,_.Kk)(i.statistics)&&(m=(0,_.C2)(i.statistics)),s[i.player.id]={...i,statistics:{...i.statistics,totalDefensiveActions:e,totalDuels:l,totalAerialDuels:a,totalGroundDuels:n,aerialWon:r,groundWon:o,duelWon:i.statistics.duelWon||0,minutesPlayed:p,timeOnIce:h,faceOffTakenOnly:c,kickingFg:u,goalkeeperEfficiencyPercentage:x,shotAccuracy:g,position:i.position||0,passingRating:m}}}return s},N=(e,t,s)=>{for(let i of e.statistics)if(i.configStatsKey.textualDescription)for(let e of Object.keys(i.configStatsKey.textualDescription))i.configStatsKey.textualDescription[e]=t.formatMessage({id:(0,L.O)(V,e,s)});return e},F=(e,t,s,i,l,r)=>{let{event:o,leftTeam:d,rightTeam:c}=(0,a.useContext)(n.y$),u=(0,T.A)(),p=o.tournament.category.sport.slug,x={},g={},m=(e,t)=>{r&&r!==t.id||(x[e.player.id]={teamId:t.id,teamName:t.name},g[e.player.id]=e)};i.left.players.forEach(e=>m(e,d)),i.right.players.forEach(e=>m(e,c));let f=G(Object.values(g),p);return E({players:Object.values((0,R.C)(f,e,l,p))},s,e=>x[e]).filter(e=>h(t,p,e)).map(e=>N(e,u,p))};var B=s(71046);let D=e=>{let{sortConfig:t,updateSortStatistic:s,filteredTeamId:r,onFilterClick:o,defaultSortStat:d,stats:u,lineups:p,groupName:h}=e,{event:x,leftTeam:g,rightTeam:m}=(0,a.useContext)(n.y$),{openEventPlayerStatistics:y}=(0,f.d)(),j=(e,t)=>{e.preventDefault(),x.hasEventPlayerStatistics&&y({event:x,player:t},c._.PlayerStats)},v=F(t,h,u,p,d,r);return v.length?(0,i.jsxs)(l.XI,{w:"100%",children:[(0,i.jsx)(l.XI.Head,{children:(0,i.jsxs)(l.XI.Row,{children:[(0,i.jsx)(l.XI.HeadCell,{maxW:40,w:40,children:(0,i.jsx)(l.az,{w:40,h:24})}),(0,i.jsx)(z,{filteredTeamId:r,onFilterClick:o,leftTeam:g,rightTeam:m}),v[0].statistics.map(e=>(0,i.jsx)(M,{sport:(0,B.c5)(x),statistic:e,sortConfig:t,onColumnClick:()=>s(e.configStatsKey,h)},e.configStatsKey.value))]})}),(0,i.jsx)(l.XI.Body,{children:v.map(e=>(0,i.jsxs)(l.XI.Row,{children:[(0,i.jsx)(P,{teamId:e.player.teamId,teamName:e.player.teamName}),(0,i.jsx)(H,{player:e.player,onClick:j}),e.statistics.map(s=>(0,i.jsx)(I,{statistic:s,isSortBy:s.configStatsKey.value===t.stat.value,position:e.player.position},s.configStatsKey.value))]},e.player.id))})]}):null};var Y=s(71306);let U=(e,t)=>{let s=(0,a.useMemo)(()=>{let s={};return Object.keys(u.Oi[e]).forEach(i=>{let l=u.Oi[e][i];s[i]=t[i].find(e=>e.value===l)||t[i][0]}),s},[e]),[i,l]=(0,a.useState)(()=>m(s));return{defaultSorts:s,sortConfigs:i,updateSortStatistic:(e,t)=>{l(s=>({...s,[t]:(0,Y.I)(s[t],e)}))}}},W=e=>{let{lineups:t}=e,s=(0,a.useContext)(n.Ws),d=(0,r.nm)(s),c=g(d,t,s),[u,p]=(0,a.useState)(c[0]),[h,x]=(0,a.useState)(),{defaultSorts:m,sortConfigs:f,updateSortStatistic:y}=U(s,d),j=(0,a.useCallback)(e=>x(e),[]);return c?(0,i.jsxs)(l.tU,{variant:"tertiary",initialValue:0,value:u||0,onChange:e=>p(e),children:[(0,i.jsx)(l.so,{px:"lg",pt:"sm",mb:"sm",align:"center",rowGap:"xs",wrap:"wrap",children:c.map(e=>(0,i.jsx)(l.tU.Tab,{ml:0,mr:"xs",mb:"sm",tabKey:e,children:(0,i.jsx)(l.EY,{font:"assistive.default",color:"onSurface.nLv1",textTransform:"capitalize",children:(0,i.jsx)(o.R,{id:e})})},e))}),c.map(e=>(0,i.jsx)(l.tU.Panel,{tabKey:e,children:(0,i.jsx)(l.az,{pb:"lg",children:(0,i.jsx)(l.az,{style:{overflowX:"auto"},children:(0,i.jsx)(D,{sortConfig:f[e],updateSortStatistic:y,defaultSortStat:m[e],filteredTeamId:h,onFilterClick:j,stats:d[e],lineups:t,groupName:e})})})},e))]}):null}},22835:(e,t,s)=>{s.d(t,{M:()=>r});var i=s(21377),l=s(4967),a=s(52839),n=s(86679);let r=e=>{let t=t=>e.status.type===i.XUj.NotStarted&&e.season&&e.tournament.uniqueTournament&&e.seasonStatisticsType&&a.u.includes(e.tournament.category.sport.slug)?i.cWY.topPlayers(t,e.tournament.uniqueTournament.id,e.season.id,e.seasonStatisticsType):void 0,s=t(e.homeTeam.id),r=t(e.awayTeam.id),{hasHome:o,hasAway:d}=(0,n.A)({hasHome:{route:t(e.homeTeam.id),skipCheck:!s,deduplicationInterval:15*l.pY},hasAway:{route:t(e.awayTeam.id),skipCheck:!r,deduplicationInterval:15*l.pY}},[s,r]);return{hasPregameTopPlayers:!!o&&!!d,couldHavePregameTopPlayers:!1!==o&&!1!==d&&!!s&&!!r}}},23695:(e,t,s)=>{s.d(t,{K:()=>F});var i=s(6029),l=s(32523),a=s(21377),n=s(4967),r=s(44194),o=s(41249),d=s(55729),c=s(90248),u=s(45860),p=s(65789),h=s(62859),x=s(54409),g=s(7263),m=s(76356),f=s(28446),y=s(90112),j=s(9127),v=s(8703),b=s(67717),_=s(65078),w=s(44259);function k(e){let{selectedPlayer:t,setSelectedPlayer:s,showSubstitutes:l,substitutionIds:a,setShowSubstitutes:n,selectedSide:u,players:p}=e,{event:x}=(0,d.useContext)(h.y$),g=Array.from(a).reduce((e,t)=>{let s=p.find(e=>e.player.id===t);return s?[...e,s]:e},[]),m=(null==t?void 0:t.id)&&a.has(t.id);return(0,d.useEffect)(()=>{m&&!l&&n(!0)},[t]),(0,i.jsxs)(o.so,{br:"24",h:"92",mb:"xs",align:"flex-start",direction:"column",children:[(0,i.jsx)(o.Sc,{px:"lg",name:"showSubstitutes-".concat(x.id),onChange:e=>{let t=e.currentTarget.checked;n(t),(!t&&m||t&&!m)&&s(void 0)},checked:l,style:{overflow:"hidden"},boxColor:"onColor.primary",children:(0,i.jsx)(o.EY,{color:"onColor.primary",children:(0,i.jsx)(c.A,{id:"show_substitutions"})})}),(0,i.jsx)(r.tR,{buttonStyle:"clipped",colorPalette:"primary",overflowCheckDeps:[g.map(e=>e.player.id).join(", ")],children:(0,i.jsx)(o.so,{px:"lg",w:"fit-content",align:"center",h:44,children:(0,i.jsx)(y.N,{initial:!1,children:g.map(e=>{let{player:l,jersey:a,fillColor:n,numberColor:r,hasLowPoints:d}=e;return(0,i.jsx)(j.m.div,{initial:{opacity:0},animate:{opacity:(0,w.cl)(d,!!t,(null==t?void 0:t.id)===l.id)},exit:{opacity:0},transition:{duration:.2},onClick:()=>s(l),style:{cursor:"pointer"},children:(0,i.jsx)(o.so,{align:"center",p:"xs",w:"32",h:"32",br:"50%",ml:"xs",textAlign:"center",justify:"center",bg:n,style:{pointerEvents:"none",userSelect:"none"},children:(0,i.jsx)(o.EY,{font:"display.medium",color:r,children:a})})},l.id)})},u)})})]})}var C=s(10292),S=s(24159);function A(e){let{selectedPlayer:t,players:s,setSelectedPlayer:l}=e;return t?(0,i.jsx)(o.so,{position:"absolute",justify:"center",w:"100%",bottom:0,children:(0,i.jsxs)(o.so,{br:"xl",h:"48",mb:"xs",mx:"sm",bg:"surface.sp",py:"sm",pl:"xs",pr:"md",w:"100%",maxW:344,align:"center",justify:"space-between",onClick:()=>l(void 0),cursor:"pointer",children:[(0,i.jsxs)(o.so,{align:"center",children:[(0,i.jsx)(C.t,{size:40,id:t.id}),(0,i.jsxs)(o.az,{pl:"md",children:[(0,i.jsx)(o.EY,{block:!0,font:"display.medium",color:"onSurface.nLv1",children:(0,i.jsx)(S.c,{entity:t})}),s.find(e=>{let{player:s,hasLowPoints:i}=e;return s.id===t.id&&i})&&(0,i.jsx)(o.EY,{font:"assistive.default",color:"onSurface.nLv3",mt:"xxs",children:(0,i.jsx)(c.A,{id:"low_player_involvement"})})]})]}),(0,i.jsx)(o.$n,{w:"36",h:"36",p:"0",variant:"unshielded",children:(0,i.jsx)(x.zQC,{icon:"close",fill:"onSurface.nLv1"})})]})}):null}var P=s(41735),H=s(5961),I=s(94497);let z=(0,P.default)(o.az).withConfig({componentId:"sc-d817f2df-0"})(["canvas{transform:rotate(-90deg) translate(-70px,-70px) scale(1,-1);animation:"," 200ms ease-in-out 1;}"],I.qG),M={WIDTH:280,HEIGHT:420},T=e=>{let{heatmap:t,heatmapTransform:s,eventId:l,theme:a,isLineupsBackground:n}=e,r="".concat(l,"-avg-positions");return((0,d.useEffect)(()=>{t&&(0,H.IJ)(t,{containerId:r,width:M.HEIGHT-16,height:M.WIDTH-16},a,n)},[t,r]),t)?(0,i.jsx)(z,{id:r,position:"absolute",w:M.WIDTH-16,h:M.HEIGHT-16,top:"sm",left:"sm",style:{transform:s,overflow:"hidden"}}):null},R=e=>{let{eventId:t,heatmap:s,heatmapTransform:l,children:a,isLineupsBackground:n,...r}=e,d=(0,P.useTheme)(),c=d.colors;return(0,i.jsxs)(o.az,{position:"relative",m:"auto",w:M.WIDTH,h:M.HEIGHT,children:[(0,i.jsx)("svg",{style:{position:"absolute",top:0,left:0},width:M.WIDTH,height:M.HEIGHT,viewBox:"0 0 ".concat(M.WIDTH," ").concat(M.HEIGHT),xmlns:"http://www.w3.org/2000/svg",children:(0,i.jsx)("g",{fill:"none",fillRule:"evenodd",children:(0,i.jsx)("rect",{fill:c.graphicsTerrain.footballLineups,width:M.WIDTH,height:M.HEIGHT,rx:"4"})})}),(0,i.jsx)(T,{heatmap:s,heatmapTransform:l,theme:d,eventId:t,isLineupsBackground:n}),(0,i.jsx)("svg",{style:{position:"absolute",top:0,left:0},width:M.WIDTH,height:M.HEIGHT,viewBox:"0 0 ".concat(M.WIDTH," ").concat(M.HEIGHT),xmlns:"http://www.w3.org/2000/svg",...r,children:(0,i.jsx)("g",{fill:"none",fillRule:"evenodd",children:(0,i.jsxs)("g",{children:[(0,i.jsx)("path",{stroke:c.onColor.primary,strokeWidth:"2",strokeLinejoin:"round",d:"M9.333 9.333h261.333V210H9.333z"}),(0,i.jsx)("path",{d:"M168 210c0-15.464-12.536-28-28-28s-28 12.536-28 28M72.333 9.333h135.333V70H72.333zM116.667 70c.365.655.752 1.295 1.164 1.915C122.693 79.216 130.809 84 140 84c9.195 0 17.315-4.787 22.175-12.095A28.66 28.66 0 0 0 163.333 70",stroke:c.onColor.primary,strokeWidth:"2",strokeLinejoin:"round"}),(0,i.jsx)("path",{stroke:c.onColor.primary,strokeWidth:"2",strokeLinejoin:"round",d:"M107.333 9.333h65.333V28h-65.333z"}),(0,i.jsx)("circle",{cx:"2.333",cy:"2.333",r:"2.333",transform:"translate(137.667 51.333)",fill:c.onColor.primary}),(0,i.jsx)("path",{d:"M9.333 18.667a9.333 9.333 0 0 0 9.334-9.334M261.333 9.333a9.333 9.333 0 0 0 9.334 9.334",stroke:c.onColor.primary,strokeWidth:"2",strokeLinejoin:"round"}),(0,i.jsxs)("g",{children:[(0,i.jsx)("path",{stroke:c.onColor.primary,strokeWidth:"2",strokeLinejoin:"round",d:"M9.333 410.667h261.333V210H9.333z"}),(0,i.jsx)("path",{d:"M168 210c0 15.464-12.536 28-28 28s-28-12.536-28-28M72.333 410.667h135.333V350H72.333zM116.667 350c.365-.655.752-1.295 1.164-1.915C122.693 340.784 130.809 336 140 336c9.195 0 17.315 4.787 22.175 12.095.41.618.795 1.254 1.158 1.905",stroke:c.onColor.primary,strokeWidth:"2",strokeLinejoin:"round"}),(0,i.jsx)("path",{stroke:c.onColor.primary,strokeWidth:"2",strokeLinejoin:"round",d:"M107.333 410.667h65.333V392h-65.333z"}),(0,i.jsx)("circle",{cx:"2.333",cy:"2.333",r:"2.333",transform:"matrix(1 0 0 -1 137.667 368.667)",fill:c.onColor.primary}),(0,i.jsx)("path",{d:"M9.333 401.333a9.333 9.333 0 0 1 9.334 9.334M261.333 410.667a9.333 9.333 0 0 1 9.334-9.334",stroke:c.onColor.primary,strokeWidth:"2",strokeLinejoin:"round"})]}),(0,i.jsx)("g",{children:a})]})})})]})};var V=s(54863);let L=e=>{let{style:t}=e;return(0,i.jsx)(m.az,{position:"absolute",top:"[43px]",borderLeft:"12px solid transparent",borderRight:"12px solid transparent",borderBottom:"8px solid",borderBottomColor:"graphics.terrain.footballLineups",style:t})},O={left:{group:void 0,text:(0,w.$8)()?"translate(0 4)":void 0,heatmap:"scale(1, -1)"},right:{group:"matrix(-1 0 0 -1 0 0), translate(-".concat(M.WIDTH," -").concat(M.HEIGHT,")"),text:"scale(-1 -1) ".concat((0,w.$8)()?"translate(0 4)":""),heatmap:"scale(-1, 1)"}},E=(0,f.A)().domain([0,100]).range([8,M.WIDTH-8]),G=(0,f.A)().domain([0,100]).range([8,M.HEIGHT-8]);function N(){let{event:e,location:t}=(0,d.useContext)(h.y$),[s,n]=(0,d.useState)(a.cxP.Left),[r,o]=(0,d.useState)(!1),[c,p]=(0,d.useState)(void 0),[{group:x,text:g,heatmap:f},C]=(0,d.useState)(O[s]),S=t===h.cb.Widget,{data:P,error:H}=(0,u.Ay)(a.bnp.averagePositions(e.id),(0,v.rf)(e)),{data:I}=(0,u.Ay)(c?a.bnp.playerHeatmap(e.id,c.id):null),[z,M]=(0,_.jr)(P,"home","away"),{lineups:T,error:N}=(0,V.Ir)();(0,d.useLayoutEffect)(()=>{C(O[s]),p(void 0),o(!1)},[s]);let F="left"===s?z:M;if(!P)return(0,i.jsx)(l.E,{uniqueKey:"average-position-cl",br:"lg",h:"420"});if(H||N)return null;let B={in:new Set,out:new Set},D=P.substitutions.sort((e,t)=>{var s,i;return(null!=(s=e.time)?s:0)-(null!=(i=t.time)?i:0)});for(let e=0;e({x:E(e.averageY),y:G(e.averageX),jersey:Y[s].get(e.player.id),player:e.player,hasLowPoints:(0,w.XU)(e.pointsCount),...(0,w.jM)(e.player,null==T?void 0:T[s])}))),W=e=>()=>{(null==c?void 0:c.id)===e.id?p(void 0):p(e)};return(0,i.jsxs)(m.az,{children:[(0,i.jsxs)(m.so,{w:"100%",gap:"sm",align:"center",justify:"center",position:"relative",children:[(0,i.jsx)(b.n,{w:"100%",p:"sm",gap:"sm",activeTeam:s,onTeamClick:n,isBackgroundInverse:S}),s===a.cxP.Left?(0,i.jsx)(L,{style:{left:"calc(25% - 10px)"}}):(0,i.jsx)(L,{style:{right:"calc(25% - 10px)"}})]}),(0,i.jsxs)(m.az,{position:["initial","relative"],bg:"graphics.terrain.footballLineups",m:"auto",textAlign:"center",pt:"sm",pb:"4xl",children:[(0,i.jsx)(k,{selectedPlayer:c,setSelectedPlayer:p,substitutionIds:B.in,showSubstitutes:r,setShowSubstitutes:o,selectedSide:s,players:U}),(0,i.jsx)(m.az,{position:"relative",children:(0,i.jsx)(R,{eventId:e.id,heatmap:null==I?void 0:I.heatmap,heatmapTransform:f,isLineupsBackground:!0,children:(0,i.jsx)("g",{transform:x,textAnchor:"middle",fontSize:"16px",fontWeight:"700",fontFamily:"'Sofascore Sans', sans-serif",children:(0,i.jsxs)(y.N,{children:[(0,i.jsxs)(j.m.g,{fill:"white",initial:{opacity:0},animate:{opacity:.5},transform:"translate(136 136)",children:[(0,i.jsx)("rect",{width:"8",height:"116"}),(0,i.jsx)("path",{d:"M16 8 4 16V0zM0 6h4v4H0z",transform:"translate(0 116), rotate(90), scale(2)",style:{transformOrigin:"4px 8px"}})]},s),U.map(e=>{let{x:t,y:s,player:l,fillColor:a,hasLowPoints:n}=e;return(r?B.out.has(l.id):B.in.has(l.id))?null:(0,i.jsx)(j.m.circle,{initial:{opacity:0,r:0},animate:{opacity:(0,w.cl)(n,!!c,l.id===(null==c?void 0:c.id)),r:16},transition:r&&!c?{delay:.2}:void 0,fill:a,cx:t,cy:s,style:{cursor:"pointer"},onClick:W(l)},l.id+"circle")}),U.map(e=>{let{x:t,y:s,player:l,jersey:a,numberColor:n,hasLowPoints:o}=e;return(r?B.out.has(l.id):B.in.has(l.id))?null:(0,i.jsx)(j.m.text,{initial:{opacity:0},animate:{opacity:(0,w.cl)(o,!!c,l.id===(null==c?void 0:c.id))},transition:r&&!c?{delay:.2}:void 0,x:t,y:s+1,style:{transformOrigin:"".concat(t,"px ").concat(s,"px"),zIndex:1,cursor:"pointer"},transform:g,fill:n,alignmentBaseline:"middle",onClick:W(l),children:a},l.id+"txt")})]})})})}),(0,i.jsx)(A,{selectedPlayer:c,setSelectedPlayer:p,players:U})]})]})}function F(){let{event:e,location:t}=(0,d.useContext)(h.y$),[s,m]=(0,d.useState)(!1),{isDesktop:f}=(0,r.$c)(),{data:y}=(0,u.Ay)([a.bnp.averagePositions(e.id),"HEAD"],{fetcher:g.n}),j=25>(0,n.Ui)(Date.now(),e.startTimestamp,"minutes"),v=f&&t===h.cb.EventPage,b=v||j,_=!1;return(y?_=!0:e.status.type===a.XUj.InProgress&&(_=j&&1===e.detailId),_)?(0,i.jsxs)(p.Zp,{isInverseDesktop:!0,children:[b&&(0,i.jsxs)(o.so,{onClick:()=>{j||m(!s)},align:"center",cursor:j?"default":"pointer",hoverBg:j?void 0:"surface.s0",br:"lg",p:"md",children:[(0,i.jsx)(o.az,{mr:"md",h:"32",w:"24",children:(0,i.jsx)(x.uEu,{fill:"graphicsTerrain.football"})}),(0,i.jsxs)(o.so,{direction:"column",children:[(0,i.jsx)(o.EY,{font:"display.small",color:"primary.default",children:(0,i.jsx)(c.A,{id:"players_average_positions"})}),j&&(0,i.jsx)(o.EY,{mt:"xxs",font:"assistive.default",color:"onSurface.nLv3",children:(0,i.jsx)(c.A,{id:"average_positions_available_when"})})]})]}),j?null:v?(0,i.jsxs)(o.aF,{isOpen:s,onClose:()=>m(!1),w:"400",children:[(0,i.jsx)(o.EY,{as:"h3",align:"center",font:"display.large",color:"onSurface.nLv1",mb:"md",children:(0,i.jsx)(c.A,{id:"players_average_positions"})}),(0,i.jsx)(o.az,{br:"lg",overflow:"hidden",children:(0,i.jsx)(N,{})})]}):(0,i.jsxs)(o.az,{children:[(0,i.jsx)(o.EY,{as:"h3",align:"center",font:"display.large",color:"onSurface.nLv1",mb:0,children:(0,i.jsx)(c.A,{id:"players_average_positions"})}),(0,i.jsx)(o.az,{br:"0 0 lg lg",overflow:"hidden",children:(0,i.jsx)(N,{})})]})]}):void 0===y&&1===e.detailId&&e.status.type!==a.XUj.NotStarted?(0,i.jsx)(o.az,{children:(0,i.jsx)(l.E,{uniqueKey:"average-position-container-cl",h:56})}):null}},24985:(e,t,s)=>{s.d(t,{Vj:()=>l.A,g9:()=>i.g9,Ir:()=>a.Ir});var i=s(12785);s(75318),s(23695),s(31130),s(61777);var l=s(27778),a=s(54863);s(55529)},27778:(e,t,s)=>{s.d(t,{A:()=>x});var i=s(6029),l=s(21377),a=s(44194),n=s(21501),r=s(41249),o=s(55729),d=s(65789),c=s(62859),u=s(69559),p=s(56008),h=s(22835);function x(){let e=(0,u.o)(),{event:t,location:s,initialHasLineups:x}=(0,o.useContext)(c.y$),{couldHavePregameTopPlayers:g}=(0,h.M)(t),{isDesktop:m}=(0,a.$c)(),f=m&&s===c.cb.EventPage,y=(0,n.hX)();return e!==l.QCR.Football&&g?(0,i.jsx)(p.A,{}):y&&!x?null:f?(0,i.jsx)(d.Zp,{children:(0,i.jsxs)(r.az,{display:["none","block"],children:[(0,i.jsx)(r.az,{h:46}),(0,i.jsx)(r.az,{h:48}),(0,i.jsxs)(r.so,{pb:"sm",px:"sm",gap:"sm",children:[(0,i.jsx)(r.az,{h:72,w:"50%",bg:"surface.s2",br:"lg"}),(0,i.jsx)(r.az,{h:72,w:"50%",bg:"surface.s2",br:"lg"})]}),(0,i.jsx)(r.az,{h:432,bg:"surface.s2",mx:"sm"}),(0,i.jsx)(r.az,{h:56,m:"sm",bg:"surface.s2",br:"lg"}),(0,i.jsx)(r.az,{h:240})]})}):(0,i.jsx)(r.az,{display:["block","none"],h:946})}},30182:(e,t,s)=>{s.d(t,{m:()=>x});var i=s(6029),l=s(10292),a=s(41249),n=s(55729),r=s(65789),o=s(5276),d=s(70591),c=s(24159),u=s(41078);function p(e){let{missingPlayer:t,left:s,first:n}=e;return t?(0,i.jsxs)(a.so,{h:56,w:"100%",align:"center",direction:s?"row":"row-reverse",gap:"lg",overflow:"hidden",pl:s?"lg":0,pr:s?0:"lg",cursor:"pointer",hoverBg:"surface.s2",children:[(0,i.jsx)(l.t,{size:40,id:t.player.id,style:{display:"block"}}),(0,i.jsxs)(a.so,{overflow:"hidden",direction:"column",justify:"center",align:s?"flex-start":"flex-end",gap:"xs",children:[(0,i.jsx)(a.EY,{font:"body.medium",color:"onSurface.nLv1",children:(0,i.jsx)(c.c,{entity:t.player,short:!0})}),(0,i.jsx)(o.Ck,{missingPlayer:t})]})]}):n?(0,i.jsx)(u.A,{messageId:"no_missing_players",isInverted:!s,width:"100%"}):null}function h(e){let{home:t,away:s,first:l}=e,r=(null==t?void 0:t.player)?d.uc:n.Fragment,o=(null==s?void 0:s.player)?d.uc:n.Fragment;return(0,i.jsxs)(a.so,{justify:t||l?"space-between":"flex-end",children:[(0,i.jsx)(r,{player:null==t?void 0:t.player,style:{width:"50%"},children:(0,i.jsx)(p,{missingPlayer:t,first:!!l,left:!0})}),(0,i.jsx)(o,{player:null==s?void 0:s.player,style:{width:"50%"},children:(0,i.jsx)(p,{missingPlayer:s,first:!!l})})]})}function x(e){let{home:t,away:s}=e;if(void 0===t&&void 0===s)return null;let l=Math.max((null==t?void 0:t.length)||0,(null==s?void 0:s.length)||0);return(0,i.jsxs)(r.Zp,{children:[(0,i.jsx)(r.Zp.Header,{titleId:"injuries_and_suspensions"}),Array.from({length:l}).map((e,l)=>{var a,n,r,o;return(0,i.jsx)(h,{home:null==t?void 0:t[l],away:null==s?void 0:s[l],first:0===l},"".concat(null==t||null==(n=t[l])||null==(a=n.player)?void 0:a.id).concat(null==s||null==(o=s[l])||null==(r=o.player)?void 0:r.id))}),(0,i.jsx)(r.Zp.Footer,{})]})}},31130:(e,t,s)=>{s.d(t,{A:()=>f});var i=s(6029),l=s(21377),a=s(44194),n=s(41249),r=s(55729),o=s(65789),d=s(62859),c=s(67717),u=s(79853),p=s(54863),h=s(5276),x=s(33243),g=s(5998);function m(){return(0,i.jsx)(n.az,{h:900})}function f(){var e;let{event:t,leftTeam:s,rightTeam:f,location:y}=(0,r.useContext)(d.y$),{managers:j}=(0,u.K)(t),{lineups:v,error:b}=(0,p.Ir)({jerseyStyle:"fancy"}),[_,w]=(0,r.useState)(l.cxP.Left),{isDesktop:k}=(0,a.$c)(),C=k&&y===d.cb.EventPage;if(b)return null;if(!v)return(0,i.jsx)(m,{});let[S,A,P]=_===l.cxP.Left?[s,null==j?void 0:j.leftManager,v.left]:[f,null==j?void 0:j.rightManager,v.right],H=P.players.filter(e=>!e.substitute),I=P.players.filter(e=>e.substitute),z=!!A||P.supportStaff&&(null==(e=P.supportStaff)?void 0:e.length)>0;return(0,i.jsxs)(o.HH,{isCard:C,children:[C&&(0,i.jsx)(o.Zp.Header,{titleId:"squads",as:"h2"}),(0,i.jsx)(n.az,{bg:"surface.s1",w:"100%",position:"sticky",top:[50,0],zIndex:n.Py.Sticky,p:"sm",children:(0,i.jsx)(c.n,{activeTeam:_,onTeamClick:e=>w(e)})}),(0,i.jsxs)(n.so,{direction:"column",p:"sm",gap:"sm",children:[!!H.length&&(0,i.jsxs)(o.Zp,{isInverseDesktop:!0,children:[(0,i.jsx)(o.Zp.Header,{titleId:"team_playing_eleven"}),(0,i.jsx)(g.A,{players:H,team:S,event:t,hideTeamHeader:!0,highlightStarters:!1})]}),!!I.length&&(0,i.jsxs)(o.Zp,{isInverseDesktop:!0,children:[(0,i.jsx)(o.Zp.Header,{titleId:"rest_of_squad"}),(0,i.jsx)(g.A,{players:I,team:S,event:t,hideTeamHeader:!0})]}),z&&(0,i.jsxs)(o.Zp,{isInverseDesktop:!0,children:[(0,i.jsx)(o.Zp.Header,{titleId:"support_staff"}),(0,i.jsx)(x.A,{manager:A,supportStaff:P.supportStaff||[]})]}),!!(v.left.missingPlayers||v.right.missingPlayers)&&(0,i.jsx)(h.Sb,{missingPlayers:P.missingPlayers})]})]})}},32190:(e,t,s)=>{s.d(t,{Et:()=>n.Et,GW:()=>l.A,pY:()=>a.p,tg:()=>i.t});var i=s(91407),l=s(12605),a=s(91603),n=s(19991)},33007:(e,t,s)=>{s.r(t),s.d(t,{default:()=>en});var i=s(6029),l=s(32523),a=s(21377),n=s(44194),r=s(76356),o=s(55729),d=s(62859),c=s(44565),u=s(5276),p=s(62827),h=s(73011);let x="HIDDEN_STATISTICS_GROUP",g="DEFAULT_GROUP_NAME",m={"american-football":{passing:"passingCompletions",rushing:"rushingAttempts",receiving:"receivingReceptions",defensive:"defensiveCombineTackles",interceptions:"defensiveInterceptions",fumbles:"fumbleFumbles",kicking:"kickingFgMade",punting:"puntingTotal","kick returns":"kickReturnsTotal","punt returns":"puntReturnsTotal"},basketball:{DEFAULT_GROUP_NAME:"points"},"ice-hockey":{skater:"goals",goalkeeper:"savePercentage"},handball:{players:"goals",goalkeepers:"goalkeeperEfficiencyPercentage"}};var f=s(87827),y=s(90248),j=s(69559),v=s(54409),b=s(71306),_=s(48886),w=s(12047),k=s(35474),C=s(94446),S=s(16620),A=s(12153),P=s(24159),H=s(54917);let I=e=>{let{player:t,hideImage:s}=e,l=(0,o.useContext)(d.Ws)===a.QCR.Basketball&&!t.substitute,c="rtl"===document.dir;return(0,i.jsxs)(r.so,{align:"center",h:"5xl",mr:s?"lg":void 0,children:[(0,i.jsx)(r.az,{w:"xs",h:"[52px]",bg:l?"status.val":void 0}),!s&&(0,i.jsxs)(r.az,{position:"relative",py:"sm",px:"md",mr:"xs",children:[(0,i.jsx)(C.t,{id:t.player.id,size:40,name:t.player.name,style:{display:"block"}}),l&&(0,i.jsx)(r.az,{position:"absolute",bottom:"xs",left:"[50%]",style:{transform:c?"translateX(50%)":"translateX(-50%)"},bg:"status.val",br:"[6px]",children:(0,i.jsx)(n.EY,{px:"xs",textStyle:"assistive.micro",color:"surface.s1",display:"block",children:(0,i.jsx)(y.A,{id:"starter"})})})]})]})},z=e=>{let{player:t,showTeamLogo:s,useShortName:l}=e,o=(0,j.o)()===a.QCR.Basketball&&!!t.ejected;return(0,i.jsxs)(r.az,{overflowX:"clip",children:[o&&(0,i.jsx)(r.so,{bg:"status.error.default",display:"inline-flex",h:"md",align:"center",px:"sm",br:"md",mb:"2xs",children:(0,i.jsx)(n.EY,{textStyle:"assistive.micro",color:"surface.s1",lineHeight:1,children:(0,i.jsx)(y.A,{id:"basketball_player_ejected_long"})})}),(0,i.jsx)(n.EY,{mb:"2xs",textStyle:"display.small",color:t.inPlay?"primary.default":"neutrals.nLv1",display:"block",truncate:!0,children:(0,i.jsx)(P.c,{entity:t.player,short:l})}),(0,i.jsxs)(r.so,{w:"100%",gap:"sm",align:"center",children:[s&&t.teamId&&(0,i.jsx)(C.p,{id:t.teamId,size:16}),!!t.jerseyNumber&&(0,i.jsx)(n.EY,{textStyle:"body.medium",children:t.jerseyNumber}),!!t.position&&(0,i.jsx)(n.EY,{textStyle:"body.medium",color:"neutrals.nLv3",truncate:!0,children:(0,i.jsx)(H.F,{id:t.position})})]})]})};function M(e){let{player:t,isHovered:s,onHoverStart:l,onHoverEnd:a,children:n}=e,{event:c}=(0,o.useContext)(d.y$),{openEventPlayerStatistics:u}=(0,S.d)();return(0,i.jsx)(A.A,{routeKey:"player",params:{slug:t.slug,id:t.id,sport:c.tournament.category.sport.slug},onClick:e=>{c.hasEventPlayerStatistics&&(e.preventDefault(),u({event:c,player:t},_._.BoxScore))},onMouseOver:()=>null==l?void 0:l(t.id),onMouseLeave:()=>null==a?void 0:a(t.id),children:(0,i.jsx)(r.so,{bg:s?"surface.s2":void 0,title:t.name,children:n})})}function T(e){let{player:t,hideImage:s,showTeamLogo:l,useShortName:a,isHovered:n,isLast:o,onHoverStart:d,onHoverEnd:c}=e;return(0,i.jsx)(M,{player:t.player,onHoverStart:d,onHoverEnd:c,isHovered:n,children:(0,i.jsxs)(r.so,{h:"5xl",align:"center",w:"100%",borderBottom:o?void 0:"1px solid {colors.neutrals.nLv4}",children:[(0,i.jsx)(I,{player:t,hideImage:s}),(0,i.jsx)(z,{player:t,showTeamLogo:l,useShortName:a})]})})}var R=s(21501),V=s(12364),L=s.n(V);let O=e=>{var t,s;return e.wideBoxScore||(null!=(s=null==(t=e.short)?void 0:t.length)?s:0)>4?40:36};function E(e){let{stats:t,sortedPlayers:s,sortStatistic:l,hoveredPlayerId:a,onHoverStart:o,onHoverEnd:d}=e;return(0,i.jsx)(i.Fragment,{children:s.map((e,c)=>{let u=(0,k.$i)(e.statistics||{});return(0,i.jsx)(M,{player:e.player,onHoverStart:o,onHoverEnd:d,children:t.map(t=>{let o=O(t),d=l.short===t.short&&s.length>1;return(0,i.jsx)(r.ov,{h:"5xl",style:{width:o},bg:a===e.player.id?"surface.s2":void 0,borderBottom:c{let{name:t,items:s}=e;return(0,i.jsxs)("div",{children:[t===g?null:(0,i.jsx)(n.EY,{textStyle:"assistive.default",pt:"lg",pb:"sm",display:"block",children:(0,i.jsx)(N.R,{id:t})}),s.map(e=>(0,i.jsxs)(r.so,{gap:"lg",py:"sm",children:[(0,i.jsx)(r.az,{w:"[36px]",children:(0,i.jsx)(n.EY,{textStyle:"assistive.default",color:"neutrals.nLv3",children:e.short})}),(0,i.jsx)(r.az,{children:(0,i.jsx)(n.EY,{textStyle:"body.small",children:(0,i.jsx)(B.w,{id:e.translationKey||e.value})})})]},e.short))]})},Y=e=>{let{groups:t,defaultTab:s}=e,[l,a]=(0,o.useState)(s||"passingGroup");return(0,i.jsx)(r.az,{w:{md:"[400px]"},children:(0,i.jsxs)(F.tU,{variant:"tertiary",value:l,onChange:e=>a(e),children:[(0,i.jsx)(F.tU.List,{px:"md",py:"sm",children:Object.keys(t).map(e=>(0,i.jsx)(F.tU.Tab,{tabKey:e,children:(0,i.jsx)(N.R,{id:e})},"tab-".concat(e)))}),(0,i.jsx)(r.az,{children:Object.keys(t).map(e=>(0,i.jsx)(F.tU.Panel,{tabKey:e,children:(0,i.jsx)(r.az,{px:"lg",children:(0,i.jsx)(D,{name:g,items:t[l]})})},"panel-".concat(e)))})]})})},U=e=>{let{groups:t,sport:s,defaultTab:l}=e,{isMobile:o}=(0,n.$c)();return s===a.QCR.AmericanFootball&&o?(0,i.jsx)(Y,{groups:t,defaultTab:l}):(0,i.jsx)(r.so,{px:"lg",direction:"column",gap:"lg",w:{md:"[400px]"},overflowY:"auto",children:Object.keys(t).map(e=>(0,i.jsx)(D,{name:e,items:t[e]},e))})},W=e=>{var t,s;let{group:l,showFullStats:c}=e,[u,p]=(0,o.useState)(!1),[x,m]=(0,o.useState)(void 0),{mediaBreakpoint:f}=(0,n.$c)(),j=(0,o.useContext)(d.Ws),b=(0,h.mR)(j,!0),_=e=>{p(!0),j===a.QCR.AmericanFootball&&m(e)};return(0,i.jsxs)(r.az,{flexGrow:1,children:[(0,i.jsxs)(n.EY,{textStyle:"assistive.default",color:"primary.default",display:"inline-block",cursor:"pointer",mr:"2xs",style:{width:(t=f,s=b[l].length,c?"md"===t?6===s?32:50:"unset":"unset")},onClick:()=>_(l),truncate:!0,children:[(0,i.jsx)(N.R,{id:l===g?"legend_info_button_title":l}),(0,i.jsx)(v.G_L,{w:16,h:16,fill:"primary.default",ml:"xxs",mb:"xxs"})]}),(0,i.jsx)(G.A,{isOpen:u,setIsOpen:p,header:(0,i.jsx)(n.EY,{textStyle:"display.large",p:"lg",display:"block",children:(0,i.jsx)(y.A,{id:"bottom_sheet_stats_expl_title"})}),children:(0,i.jsx)(U,{groups:b,sport:j,defaultTab:x})})]})};function Z(e){let{iconDirection:t,hasPlayerRatings:s,onClick:l}=e,{isMobile:a}=(0,n.$c)(),o="right"===t;return(0,i.jsx)(r.ov,{h:"4xl",pb:"2xs",w:"[20px]",position:"relative",right:!s&&o?{md:"xs"}:void 0,children:(0,i.jsx)(n.K0,{variant:"clear",onClick:l,userSelect:"none",children:(0,i.jsx)(r.ov,{w:"[20px]",h:"[20px]",children:a?(0,i.jsx)(v.Bfd,{fill:"onSurface.nLv3",width:8,height:8,style:{transform:o?"rotate(270deg)":"rotate(90deg)"}}):(0,i.jsx)(v.QtO,{fill:"primary.default",width:16,height:16,style:{transform:o?"rotate(270deg)":"rotate(90deg)"}})})})})}let Q=e=>{let{isActive:t,stat:s,title:l}=e;return(0,i.jsx)(n.EY,{style:{width:O(s)},title:l,textStyle:"tab.secondary",color:t?"primary.default":"neutrals.nLv3",textAlign:"center",display:"block",children:s.shortTranslationKey?(0,i.jsx)(y.A,{id:s.shortTranslationKey}):s.short})},K=e=>{let{group:t,onLeftArrowClick:s,showFullStats:l}=e;return(0,i.jsxs)(r.so,{h:"4xl",align:"center",pl:"lg",pr:"xs",children:[(0,i.jsx)(W,{group:t,showFullStats:l}),s&&(0,i.jsx)(Z,{onClick:s,iconDirection:"left"})]})};function $(e){let{stat:t,isActive:s,isSortable:l,sortDir:a,isLast:n,onClick:o}=e;return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(r.so,{position:"relative",h:"[20px]",align:"center",userSelect:"none",children:[(0,i.jsx)(B.w,{id:String(t.value),children:e=>(0,i.jsx)(r.az,{onClick:o,cursor:l?"pointer":void 0,mr:n?void 0:"[-1px]",children:(0,i.jsx)(Q,{title:e.toString(),stat:t,isActive:s})})}),!n&&(0,i.jsx)(r.cG,{color:"neutrals.nLv4",borderInlineEndStyle:"solid",orientation:"vertical"})]}),s&&(0,i.jsx)(r.az,{w:"lg",h:"lg",children:(0,i.jsx)(v.Bfd,{fill:"primary.default",width:16,height:16,style:s&&a===_.U.ASC?{transform:"rotate(180deg)"}:void 0})})]})}let X=(0,o.forwardRef)((e,t)=>{let{children:s,...l}=e,a=(0,w.Ay)()+48;return(0,i.jsx)(r.az,{...l,position:"sticky",bg:"surface.s1",zIndex:"sticky",style:{top:a},ref:t,children:s})}),q=()=>{let e=(0,j.o)(),{event:t}=(0,o.useContext)(d.y$);return t.tournament.uniqueTournament?e===a.QCR.Football||t.tournament.uniqueTournament&&[a.G6l.NBA,138,141].includes(t.tournament.uniqueTournament.id)?(0,i.jsx)(y.A,{id:"sofascore_rating_basketball_box_score"}):(0,i.jsx)(y.A,{id:"sofascore_rating_basketball_box_score_finished"}):null};function J(e){let{location:t}=(0,o.useContext)(d.y$),{mediaBreakpoint:s,isDesktop:l}=(0,n.$c)(),{statNames:a,group:c,sortedPlayers:u,showFullStats:p,updateSortStatistic:h,sortConfig:x}=e,g=u.map(e=>{var t;return{playerId:e.player.id,rating:null==(t=e.statistics)?void 0:t.rating}}),m=g.some(e=>"number"==typeof e.rating&&e.rating>0),y=m?l?20:12:0,{hoveredPlayerId:j,onHoverStart:b,onHoverEnd:_}=function(){let[e,t]=(0,o.useState)(void 0);return{hoveredPlayerId:e,onHoverStart:(0,o.useCallback)(e=>t(e),[]),onHoverEnd:(0,o.useCallback)(e=>t(t=>t===e?void 0:t),[])}}(),{leftColumnBasis:w,rightColumnBasis:k,...C}=function(e,t,s){let i=(0,o.useRef)(null),l=(0,o.useRef)(null),a=(0,o.useRef)(null),n=e.reduce((e,t)=>e+O(t),0),r=e.length>6?180-t:Math.min(n,220-t),d=Math.min(290-t-r,s?120-t:136-t),[c,u]=(0,o.useState)(void 0),[p,h]=(0,o.useState)(void 0),x=()=>{l.current&&(u(l.current.scrollLeft>0),h(l.current.scrollLeft{var t;i.current="header",null==(t=l.current)||t.scroll({left:Math.max(e,0),behavior:"smooth"}),x()};return(0,R.st)(()=>{x()},void 0,[s]),{currentElementInfo:i,headerRef:l,contentRef:a,leftColumnBasis:"".concat(d,"px"),rightColumnBasis:"".concat(r,"px"),leftColumnMax:"max(".concat(200-t,"px, calc(100% - ").concat(n,"px))"),rightColumnMax:n,rightCanGrow:n>r,onLeftClick:c?()=>{var e;return g(((null==(e=l.current)?void 0:e.scrollLeft)||0)-108)}:void 0,onRightClick:p?()=>{var e;return g(((null==(e=l.current)?void 0:e.scrollLeft)||0)+108)}:void 0,onScroll:L()(x,100)}}(a,y,p),S=l&&t===d.cb.EventPage;return(0,i.jsxs)(r.az,{pb:m?void 0:{base:"sm",md:"md"},children:[(0,i.jsxs)(r.so,{h:"100%",w:"100%",position:"relative",overflowX:"clip",justify:"space-between",children:[(0,i.jsxs)(r.az,{flexGrow:1,flexShrink:1,style:{flexBasis:w,width:w,maxWidth:C.leftColumnMax},children:[(0,i.jsx)(X,{children:(0,i.jsx)(K,{group:c,onLeftArrowClick:C.onLeftClick,showFullStats:p})}),(0,i.jsx)(r.so,{display:"flex",flexDirection:"column",overflow:"hidden",maxW:"100%",position:"relative",children:u.map((t,l)=>(0,i.jsx)(T,{player:t,stats:a,showTeamLogo:e.showTeamLogo,hideImage:["xxs","md"].includes(s)&&p&&!S,useShortName:p&&!S,isHovered:j===t.player.id,onHoverStart:b,onHoverEnd:_,isLast:u.length-1===l},t.player.id))})]}),(0,i.jsxs)(r.so,{direction:"column",flexGrow:C.rightCanGrow?1:void 0,flexShrink:C.rightCanGrow?1:void 0,style:{flexBasis:C.rightCanGrow?k:void 0,width:k,maxWidth:C.rightColumnMax},children:[(0,i.jsx)(X,{scrollbar:"hidden",ref:C.headerRef,overflow:"auto",onScroll:e=>{let t=e.target.scrollLeft;window.requestAnimationFrame(()=>{if("header"===C.currentElementInfo.current){var e;null==(e=C.contentRef.current)||e.scroll({left:t}),C.onScroll()}})},onMouseOver:()=>C.currentElementInfo.current="header",onTouchStart:()=>C.currentElementInfo.current="header",children:(0,i.jsx)(r.az,{children:(0,i.jsx)(r.so,{w:"100%",children:a.map((e,t)=>{let s=x.stat.short===e.short,l=u.length>1;return(0,i.jsx)(X,{display:"flex",flexDirection:"column",justifyContent:"flex-end",alignItems:"center",h:"4xl",pb:s&&l?void 0:"lg",children:(0,i.jsx)($,{stat:e,isActive:l&&s,isSortable:l,sortDir:s?x.dir:void 0,isLast:a.length-1===t,onClick:()=>{var s;h(e),null==(s=C.headerRef.current)||s.scroll({left:Math.max(36*(t-2),0),behavior:"smooth"})}},e.value)},e.short)})})})}),(0,i.jsx)(r.az,{scrollbar:"hidden",ref:C.contentRef,w:"100%",overflowX:"auto",onScroll:e=>{let t=e.target.scrollLeft;window.requestAnimationFrame(()=>{if("content"===C.currentElementInfo.current){var e;null==(e=C.headerRef.current)||e.scroll({left:t}),C.onScroll()}})},onMouseOver:()=>C.currentElementInfo.current="content",onTouchStart:()=>C.currentElementInfo.current="content",children:(0,i.jsx)(E,{stats:a,sortStatistic:x.stat,sortedPlayers:u,hoveredPlayerId:j,onHoverStart:b,onHoverEnd:_})})]}),(0,i.jsxs)(r.so,{w:m?{base:"2xl",md:"3xl"}:{base:"[20px]",md:"xl"},direction:"column",position:"relative",children:[(0,i.jsx)(X,{w:m?{base:"2xl",md:"3xl"}:{base:"[20px]",md:"xl"},h:"4xl",children:C.onRightClick&&(0,i.jsx)(Z,{iconDirection:"right",hasPlayerRatings:m,onClick:C.onRightClick})}),m&&(0,i.jsx)(i.Fragment,{children:g.map((e,t)=>(0,i.jsx)(M,{player:u[t].player,onHoverStart:b,onHoverEnd:_,children:(0,i.jsx)(r.az,{bg:j===e.playerId?"surface.s2":void 0,h:"5xl",py:"lg",px:"xs",borderBottom:t{e.showFullStats||void 0!==e.statNames.find(e=>e.short===t.stat.short)||s({stat:e.defaultSortStat,dir:_.U.DESC})},[e.showFullStats]),(0,i.jsx)(J,{statNames:e.statNames,showFullStats:e.showFullStats,showTeamLogo:e.showTeamLogo,group:e.group,sortConfig:t,sortedPlayers:l,updateSortStatistic:a})}function et(e){let{activeTab:t,players:s,showFull:l}=e,n=(0,o.useContext)(d.Ws),{leftTeam:r,rightTeam:c}=(0,o.useContext)(d.y$);if(!(t===a.cxP.Left?r:t===a.cxP.Right?c:r&&c)||!n)return null;let u=(0,h.mR)(n,l),p=n===a.QCR.Basketball?{[g]:s}:s.reduce((e,t)=>(t.statistics&&Object.keys(t.statistics).forEach(s=>{(function(e,t){let s=[],i=(0,h.mR)(t,!0);for(let t in i)i[t].some(t=>[t.value,t.attemptsValue,t.madesValue,t.secondaryValue].includes(e))&&s.push(t);return s.length?s:[x]})(s,n).forEach(i=>{if(n!==a.QCR.AmericanFootball||0!==t.statistics[s])if("G"===t.position&&["playersGroup","skatersGroup"].includes(i)&&!t.statistics[s])return;else e[i]?e[i][t.player.id]=t:e[i]={[t.player.id]:t}})}),e),{});return(0,i.jsx)(i.Fragment,{children:Object.keys(u).map(e=>{var a,r;if(e===x||!p[e])return null;let o=u[e].filter(e=>!e.hideIfNone||s.some(t=>{var s,i;return(null==(s=t.statistics)?void 0:s[null!=(i=e.compareValue)?i:e.value])!==void 0})),d=null!=(r=null==m||null==(a=m[n])?void 0:a[e])?r:"";return(0,i.jsx)(ee,{group:e,statNames:l?o:o.slice(0,3),showTeamLogo:"all"===t,lineup:p[e],defaultSortStat:o.find(e=>e.value===d)||o[0],showFullStats:l,sport:n},e)})})}var es=s(33144);function ei(e){let{activeTab:t,leftTeam:s,rightTeam:l,onTabChange:n}=e,o=(0,w.Ay)();return(0,i.jsx)(r.ov,{bg:"surface.s1",w:"100%",p:"sm",position:"sticky",style:{top:o},zIndex:"dropdown","data-testid":"team-pillows-selector",children:(0,i.jsxs)(F.tU,{variant:"secondary",value:t,onChange:n,children:[(0,i.jsx)(F.tU.Tab,{tabKey:a.cxP.Left,h:32,grow:1,basis:0,textAlign:"center",style:{paddingBlock:"3px"},"data-testid":a.cxP.Left,children:(0,i.jsx)(es.p,{size:24,id:s.id,name:s.name})}),(0,i.jsxs)(F.tU.Tab,{tabKey:"all",h:32,grow:1,basis:0,style:{display:"flex",justifyContent:"center",alignItems:"center",gap:"4px",paddingBlock:"3px"},children:[(0,i.jsx)(es.p,{size:24,id:s.id,name:s.name}),"+",(0,i.jsx)(es.p,{size:24,id:l.id,name:l.name})]}),(0,i.jsx)(F.tU.Tab,{tabKey:a.cxP.Right,h:32,grow:1,basis:0,textAlign:"center",style:{paddingBlock:"3px"},"data-testid":a.cxP.Right,children:(0,i.jsx)(es.p,{size:24,id:l.id,name:l.name})})]})})}function el(e){let{value:t,toggle:s}=e;return(0,i.jsxs)(r.so,{px:"lg",py:"md",align:"center",justify:"space-between",children:[(0,i.jsxs)(r.az,{children:[(0,i.jsx)(n.EY,{textStyle:"body.medium",display:"block",mb:"2xs",children:(0,i.jsx)(y.A,{id:"boxScoreAppearance"})}),(0,i.jsx)(n.EY,{textStyle:"body.small",display:"block",color:t?"primary.default":"neutrals.nLv3",children:(0,i.jsx)(y.A,{id:"toggleDetailedView"})})]}),(0,i.jsx)(F.lM,{checked:t,onChange:()=>s()})]})}var ea=s(30182);function en(e){let{showDivider:t=!0}=e,{leftTeam:s,rightTeam:h,location:x}=(0,o.useContext)(d.y$),[g,m]=(0,o.useState)("all"),[f,y]=(0,p.yR)("box-score-appearance-toggle-value",!1),{lineups:j,error:v}=(0,c.A)(),{isDesktop:b}=(0,n.$c)(),_=x===d.cb.EventPage&&b;if(v)return null;if(!j)return(0,i.jsx)(l.E,{uniqueKey:"box-score-cl",height:640,animate:!0});let w=j.left.players.map(e=>({...e,teamId:s.id})),k=j.right.players.map(e=>({...e,teamId:h.id})),C=g===a.cxP.Left?w:g===a.cxP.Right?k:[...w,...k];return s&&h?(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(r.az,{bg:"surface.s1",children:[!_&&(0,i.jsx)(el,{value:f,toggle:()=>{y(e=>!e)}}),!_&&t&&(0,i.jsx)(r.cG,{color:"neutrals.nLv4",borderBlockEndStyle:"solid"}),(0,i.jsx)(ei,{activeTab:g,leftTeam:s,rightTeam:h,onTabChange:m}),(0,i.jsx)(et,{activeTab:g,players:C,showFull:f||_})]}),!!(j.left.missingPlayers||j.right.missingPlayers)&&(0,i.jsx)(r.az,{p:"sm",children:"all"===g?(0,i.jsx)(ea.m,{home:j.left.missingPlayers,away:j.right.missingPlayers}):(0,i.jsx)(u.Sb,{missingPlayers:g===a.cxP.Left?j.left.missingPlayers:j.right.missingPlayers})})]}):null}},41078:(e,t,s)=>{s.d(t,{A:()=>r});var i=s(6029),l=s(41249),a=s(90248),n=s(54409);function r(e){let{messageId:t,isInverted:s,width:r}=e;return(0,i.jsxs)(l.so,{direction:s?"row-reverse":"row",gap:"sm",align:"center",h:56,maxW:r||"50%",px:"sm",children:[(0,i.jsx)(n.G_L,{width:24,height:24,fill:"onSurface.nLv3",style:{display:"block",minWidth:"24px"}}),(0,i.jsx)(l.EY,{font:"body.medium",color:"onSurface.nLv3",as:"div",children:(0,i.jsx)(a.A,{id:t})})]})}},44259:(e,t,s)=>{s.d(t,{$8:()=>o,T0:()=>n,XU:()=>d,cl:()=>c,eA:()=>a,jM:()=>r});var i=s(21377);class l{dist(e){return Math.sqrt((e.x-this.x)**2+(e.y-this.y)**2)}atan(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:new l(0,0);return Math.atan2(this.y-e.y,this.x-e.x)}add(e,t){let s=this.atan(t);return this.x+=e*Math.cos(s),Math.abs(s-Math.PI)>.005&&(this.y+=e*Math.sin(s)),[this.x,this.y]}constructor(e,t){this.x=e,this.y=t}}function a(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:24,s=arguments.length>2&&void 0!==arguments[2]?arguments[2]:4,i=e.map(e=>{let{x:t,y:s}=e;return new l(t,s)}),a=0;do for(let s=0;s({...e,...i[t]}))}let n=e=>{let t=new Map;if(e)for(let s=0;s{var s,i,l,a,n,r,o,d;let c=(null==t||null==(s=t.playerColor)?void 0:s.primary)||(null==t||null==(i=t.playerColor)?void 0:i.outline),u=(null==t||null==(l=t.playerColor)?void 0:l.fancyNumber)||(null==t||null==(a=t.playerColor)?void 0:a.number);return"G"===e.position&&(c=(null==t||null==(n=t.goalkeeperColor)?void 0:n.primary)||(null==t||null==(r=t.goalkeeperColor)?void 0:r.outline),u=(null==t||null==(o=t.goalkeeperColor)?void 0:o.fancyNumber)||(null==t||null==(d=t.goalkeeperColor)?void 0:d.number)),{fillColor:c=(null==c?void 0:c.startsWith("#"))?"#fff":"#"+c,numberColor:u=(null==u?void 0:u.startsWith("#"))?"#000":"#"+u}};function o(){let e=!1;return!(0,i.S$s)()&&"navigator"in window&&(e=/Firefox/.test(window.navigator.userAgent)),e}function d(e){return e>1&&e<=7}function c(e,t,s){return t?e?s?.75:.25:s?1:.5:e?.5:1}},44565:(e,t,s)=>{s.d(t,{A:()=>d});var i=s(21377),l=s(55729),a=s(45860),n=s(62859),r=s(8703),o=s(30720);function d(){let{swrConfig:e,event:t,shouldFetch:s=!0,jerseyStyle:d="fancy"}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{shouldFetch:!0},c={refreshInterval:6e4,...e},{event:u}=(0,l.useContext)(n.y$),p=s?t||u:void 0,{data:h,error:x,isLoading:g}=(0,a.Ay)(p?i.bnp.lineups(p.id):null,p?(0,r.rf)(p,c):c),[m,f]=(0,o.A)(h,"home","away"),y=p?{leftJerseyUrls:{player:i.bnp.playerJersey(p.id,"home",d),goalkeeper:i.bnp.goalkeeperJersey(p.id,"home",d)},rightJerseyUrls:{player:i.bnp.playerJersey(p.id,"away",d),goalkeeper:i.bnp.goalkeeperJersey(p.id,"away",d)}}:{leftJerseyUrls:{player:"",goalkeeper:""},rightJerseyUrls:{player:"",goalkeeper:""}},[j,v]=(0,o.A)(y,"leftJerseyUrls","rightJerseyUrls");return{lineups:h?{left:m,right:f,leftJerseyUrls:j,rightJerseyUrls:v}:void 0,isLoading:g,confirmed:null==h?void 0:h.confirmed,error:x}}},45527:(e,t,s)=>{s.d(t,{N:()=>l,i:()=>a});var i=s(6029);let l=(0,s(55729).createContext)("left"),a=e=>{let{side:t,children:s}=e;return(0,i.jsx)(l.Provider,{value:t,children:s})}},52839:(e,t,s)=>{s.d(t,{t:()=>a,u:()=>l});var i=s(21377);let l=[i.QCR.AmericanFootball,i.QCR.Basketball,i.QCR.Handball,i.QCR.IceHockey];function a(e){switch(e){case i.QCR.AmericanFootball:return["passingTouchdowns","rushingTouchdowns","receivingTouchdowns","passingCompletionPercentage","rushingYardsPerAttempt","receivingYardsPerReception","defensiveInterceptions","defensiveTotalTackles","defensiveSacks","kickingFgMade"];case i.QCR.Basketball:return["points","rebounds","assists","steals","blocks","turnovers","fieldGoalsPercentage","threePointsPercentage"];case i.QCR.Handball:return["goals","assists","goals7m","steals","twoMinutePenalties","saves","goalkeeperEfficiencyPercentage","gk7mSaves"];case i.QCR.IceHockey:return["points","goals","assists","plusMinus","timeOnIce","blocked","hits","goalsAgainstAverage","savePercentage","shutouts"];default:return null}}},54863:(e,t,s)=>{s.d(t,{Ir:()=>i.A,ax:()=>d,rR:()=>h});var i=s(44565),l=s(21377),a=s(55729),n=s(45860),r=s(62859);function o(e){let t=e.reduce((e,t)=>t.statistics&&t.statistics.rating?{sum:e.sum+Number(t.statistics.rating),count:e.count+1}:e,{count:0,sum:0});return t.count?t.sum/t.count:void 0}function d(e){let{event:t}=(0,a.useContext)(r.y$),s=o(e.left.players),i=o(e.right.players),d=!!s&&!!i,{data:c}=(0,n.Ay)(d?null:l.bnp.prematchStandings(t.id));return((null==c?void 0:c.homeTeam.avgRating)||(null==c?void 0:c.awayTeam.avgRating))&&(s=null==c?void 0:c.homeTeam.avgRating,i=null==c?void 0:c.awayTeam.avgRating),[s,i]}var c=s(34765),u=s(79853),p=s(45527);function h(){let{event:e,leftTeam:t,rightTeam:s}=(0,a.useContext)(r.y$),{managers:l}=(0,u.K)(e),{lineups:n}=(0,i.A)(),{incidents:o}=(0,c.L)(),d=(0,a.useContext)(p.N);if(void 0===d)throw Error("useLineupSide must be used within a SideProvider");return"left"===d?{event:e,team:t,manager:l.leftManager,lineups:null==n?void 0:n.left,incidents:o,jersey:null==n?void 0:n.leftJerseyUrls.player,jerseyNumberColor:null==n?void 0:n.left.playerColor,startingPlayers:(null==n?void 0:n.left.players.filter(e=>!e.substitute))||[],substitutePlayers:(null==n?void 0:n.left.players.filter(e=>e.substitute))||[]}:{event:e,team:s,manager:l.rightManager,lineups:null==n?void 0:n.right,incidents:o,jersey:null==n?void 0:n.rightJerseyUrls.player,jerseyNumberColor:null==n?void 0:n.right.playerColor,startingPlayers:(null==n?void 0:n.right.players.filter(e=>!e.substitute))||[],substitutePlayers:(null==n?void 0:n.right.players.filter(e=>e.substitute))||[]}}},55529:(e,t,s)=>{s.d(t,{V7:()=>i,kA:()=>l,vD:()=>r,Cy:()=>o,Xj:()=>d,uU:()=>c,WM:()=>n,fP:()=>a});var i=function(e){return e.Possible="possible",e.Confirmed="confirmed",e}({}),l=function(e){return e.Performance="performance",e.Club="club",e.Nationality="nationality",e.Age="age",e.MarketValue="marketValue",e.Height="height",e}({});let a={performance:"manager.performance",nationality:"nationality",club:"lineups_chip_club",age:"age",marketValue:"market_value",height:"player_height"},n=2,r={1:{gridColumn:1,gridRow:1},2:{gridColumn:3,gridRow:1},3:{gridColumn:5,gridRow:1},4:{gridColumn:2,gridRow:2},5:{gridColumn:4,gridRow:2},6:{gridColumn:1,gridRow:3},7:{gridColumn:5,gridRow:3},8:{gridColumn:3,gridRow:3},9:{gridColumn:1,gridRow:4},10:{gridColumn:2,gridRow:5},11:{gridColumn:1,gridRow:7},12:{gridColumn:3,gridRow:5},13:{gridColumn:4,gridRow:5},14:{gridColumn:5,gridRow:7},15:{gridColumn:3,gridRow:7}},o={1:{top:"5%"},2:{top:"5%"},3:{top:"5%"},4:{top:"-10%"},5:{top:"-10%"},6:{top:"-20%"},7:{top:"-20%"},8:{top:"25%"},9:{top:"25%"},10:{top:"-20%"},11:{top:"-50%"},12:{top:"30%"},13:{top:"90%"},14:{top:"-50%"},15:{top:"10%"}},d={1:{gridColumn:1,gridRow:2},2:{gridColumn:2,gridRow:2},3:{gridColumn:3,gridRow:2},4:{gridColumn:1,gridRow:4},5:{gridColumn:2,gridRow:5},6:{gridColumn:3,gridRow:5},7:{gridColumn:4,gridRow:6}},c={1:{top:"-10%"},2:{top:"25%"},3:{top:"-10%"},4:{top:"55%"},5:{top:"5%"},6:{top:"60%"},7:{top:"25%"}}},56008:(e,t,s)=>{s.d(t,{A:()=>n});var i=s(6029),l=s(41249),a=s(65789);function n(){return(0,i.jsxs)(a.Zp,{children:[(0,i.jsx)(a.Zp.Header,{titleId:"top_players"}),(0,i.jsx)(l.az,{h:780})]})}},58657:(e,t,s)=>{s.d(t,{M:()=>Q});var i=s(6029),l=s(43681),a=s(10953),n=s(91289),r=s(97080),o=s(13181),d=s(45079),c=s(84684),u=s(86877),p=s(77749),h=s(80339),x=s(14532),g=s(35518),m=s(31698),f=s(32256),y=s(51555),j=s(12275),v=s(65549),b=s(49336),_=s(26624),w=s(4653),k=s(67996),C=s(61390),S=s(84262),A=s(55217),P=s(61848),H=s(79826),I=s(23147),z=s(33787),M=s(2424),T=s(75341),R=s(86838),V=s(20191),L=s(63788),O=s(27974),E=s(55807),G=s(87234),N=s(18682);let F={card:{yellow:{fill:"scoreRating.s65",Icon:e=>(0,i.jsx)(x.A,Object.assign({},e))},yellowRed:{Icon:e=>(0,i.jsx)(p.A,Object.assign({},e))},red:{fill:"error.default",Icon:e=>(0,i.jsx)(h.default,Object.assign({},e))}},goal:{football:{regular:{fill:"secondary.default",Icon:e=>(0,i.jsx)(g.A,Object.assign({},e))},penalty:{fill:"secondary.default",Icon:e=>(0,i.jsx)(f.A,Object.assign({},e))},ownGoal:{fill:"error.default",Icon:e=>(0,i.jsx)(m.A,Object.assign({},e))}},futsal:{regular:{fill:"secondary.default",Icon:e=>(0,i.jsx)(g.A,Object.assign({},e))},penalty:{fill:"secondary.default",Icon:e=>(0,i.jsx)(f.A,Object.assign({},e))},ownGoal:{fill:"error.default",Icon:e=>(0,i.jsx)(m.A,Object.assign({},e))},accumulatedPenalty:{fill:"secondary.default",Icon:e=>(0,i.jsx)(a.A,Object.assign({},e))}},minifootball:{regular:{fill:"secondary.default",Icon:e=>(0,i.jsx)(g.A,Object.assign({},e))},penalty:{fill:"secondary.default",Icon:e=>(0,i.jsx)(f.A,Object.assign({},e))},accumulatedPenalty:{fill:"secondary.default",Icon:e=>(0,i.jsx)(a.A,Object.assign({},e))},ownGoal:{fill:"error.default",Icon:e=>(0,i.jsx)(m.A,Object.assign({},e))}},"american-football":{fieldGoal:{fill:"secondary.default",Icon:e=>(0,i.jsx)(r.A,Object.assign({},e))},rouge:{fill:"secondary.default",Icon:e=>(0,i.jsx)(o.A,Object.assign({},e))},twoPointConversion:{fill:"secondary.default",Icon:e=>(0,i.jsx)(u.A,Object.assign({},e))},touchdown:{fill:"secondary.default",Icon:e=>(0,i.jsx)(c.A,Object.assign({},e))},extraPoint:{fill:"secondary.default",Icon:e=>(0,i.jsx)(n.A,Object.assign({},e))},safety:{fill:"secondary.default",Icon:e=>(0,i.jsx)(d.A,Object.assign({},e))}},rugby:{onePoint:{fill:"secondary.default",Icon:e=>(0,i.jsx)(I.A,Object.assign({},e))},twoPoints:{fill:"secondary.default",Icon:e=>(0,i.jsx)(R.A,Object.assign({},e))},threePoints:{fill:"secondary.default",Icon:e=>(0,i.jsx)(M.A,Object.assign({},e))},try:{fill:"secondary.default",Icon:e=>(0,i.jsx)(T.A,Object.assign({},e))},penaltyTry:{fill:"secondary.default",Icon:e=>(0,i.jsx)(z.A,Object.assign({},e))}},"ice-hockey":{regular:{fill:"secondary.default",Icon:e=>(0,i.jsx)(v.A,Object.assign({},e))},emptynet:{fill:"secondary.default",Icon:e=>(0,i.jsx)(v.A,Object.assign({},e))},ownGoal:{fill:"error.default",Icon:e=>(0,i.jsx)(b.A,Object.assign({},e))},powerplay:{fill:"secondary.default",Icon:e=>(0,i.jsx)(w.A,Object.assign({},e))},shorthanded:{fill:"secondary.default",Icon:e=>(0,i.jsx)(k.A,Object.assign({},e))}},handball:{regular:{fill:"secondary.default",Icon:e=>(0,i.jsx)(y.A,Object.assign({},e))},penalty:{fill:"secondary.default",Icon:e=>(0,i.jsx)(j.A,Object.assign({},e))}},waterpolo:{regular:{fill:"secondary.default",Icon:e=>(0,i.jsx)(G.A,Object.assign({},e))},penalty:{fill:"secondary.default",Icon:e=>(0,i.jsx)(N.A,Object.assign({},e))}},regular:{Icon:()=>null}},substitution:{injury:{fill:"primary.default",Icon:e=>(0,i.jsx)(L.A,Object.assign({},e))},temporary:{fill:"primary.default",Icon:e=>(0,i.jsx)(O.A,Object.assign({},e))},regular:{fill:"primary.default",Icon:e=>(0,i.jsx)(V.A,Object.assign({},e))}},penaltyShootout:{"ice-hockey":{scored:{fill:"secondary.default",Icon:e=>(0,i.jsx)(_.A,Object.assign({},e))}},waterpolo:{scored:{fill:"secondary.default",Icon:e=>(0,i.jsx)(N.A,Object.assign({},e))}},rugby:{scored:{fill:"secondary.default",Icon:e=>(0,i.jsx)(P.A,Object.assign({},e))},missed:{fill:"error.default",Icon:e=>(0,i.jsx)(A.A,Object.assign({},e))}},taker:{fill:"secondary.default",Icon:e=>(0,i.jsx)(H.A,Object.assign({},e))},scored:{fill:"secondary.default",Icon:e=>(0,i.jsx)(f.A,Object.assign({},e))},missed:{fill:"error.default",Icon:e=>(0,i.jsx)(S.A,Object.assign({},e))}},inGamePenalty:{taker:{fill:"secondary.default",Icon:e=>(0,i.jsx)(H.A,Object.assign({},e))},scored:{fill:"secondary.default",Icon:e=>(0,i.jsx)(f.A,Object.assign({},e))},missed:{fill:"error.default",Icon:e=>(0,i.jsx)(S.A,Object.assign({},e))}},varDecision:{regular:{fill:"primary.default",Icon:e=>(0,i.jsx)(E.A,Object.assign({},e))}},suspension:{minifootball:{regular:{fill:"error.default",Icon:e=>(0,i.jsx)(l.A,Object.assign({},e))}},handball:{regular:{fill:"error.default",Icon:e=>(0,i.jsx)(l.A,Object.assign({},e))}},twoMinutes:{fill:"error.default",Icon:e=>(0,i.jsx)(l.A,Object.assign({},e))},"ice-hockey":{zeroMinutes:{fill:"error.default",Icon:e=>(0,i.jsx)(C.A,Object.assign({},e))},twoMinutes:{fill:"error.default",Icon:e=>(0,i.jsx)(C.A,Object.assign({},e))},fourMinutes:{fill:"error.default",Icon:e=>(0,i.jsx)(C.A,Object.assign({},e))},fiveMinutes:{fill:"error.default",Icon:e=>(0,i.jsx)(C.A,Object.assign({},e))},tenMinutes:{fill:"error.default",Icon:e=>(0,i.jsx)(C.A,Object.assign({},e))},regular:{fill:"error.default",Icon:e=>(0,i.jsx)(C.A,Object.assign({},e))}}}};function B({incidentType:e,incidentClass:t,sport:s,title:l,svgProps:a,fallback:n=null}){var r,o,d,c,u,p;let h=(null==(o=null==(r=F[e])?void 0:r[s])?void 0:o.regular)||(null==(d=F[e])?void 0:d.regular);if(t&&(h=(null==(u=null==(c=F[e])?void 0:c[s])?void 0:u[t])||(null==(p=F[e])?void 0:p[t])||F[e].regular),!(null==h?void 0:h.Icon))return n;let x=h.Icon;return(0,i.jsx)(x,Object.assign({width:24,height:24,fill:h.fill,title:l,style:{minWidth:(null==a?void 0:a.width)||"24px",display:"inline-block"}},a))}var D=s(41249),Y=s(55729),U=s(947),W=s(62859),Z=s(78944);let Q=e=>{var t;let s=(0,U.A)(),l=(0,Y.useContext)(W.Ws),a=null!=(t=e.sport)?t:l,n=(0,Z.q6)(e.incidentType,e.incidentClass,a),r=n?s.formatMessage({id:n}):void 0;return(0,i.jsx)(B,{...e,sport:a,title:r,fallback:(0,i.jsx)(D.az,{w:16})})}},61234:(e,t,s)=>{s.d(t,{A:()=>h});var i=s(6029),l=s(91816),a=s(41249),n=s(55729),r=s(90248),o=s(65789),d=s(70591),c=s(84942),u=s(99326),p=s(73488);function h(e){let{manager:t,incidents:s,isBorderHidden:h,isCard:x=!1}=e,g=(0,c.z)(t),m=(0,n.useMemo)(()=>s?(0,u.h$)({id:t.id,incidents:s,type:"manager"}):{},[t,s]);return(0,i.jsx)(d.yI,{manager:t,style:{width:"100%"},children:(0,i.jsx)(o.HH,{isInverseDesktop:!0,isCard:!!x,children:(0,i.jsxs)(a.so,{children:[(0,i.jsx)(a.az,{px:"lg",py:"sm",children:(0,i.jsx)(l.d,{size:40,id:t.id,name:g})}),(0,i.jsx)(a.so,{borderBottom:h?void 0:"onSurface.nLv4",align:"center",flex:"1 1 auto",mr:"lg",children:(0,i.jsxs)(a.az,{flex:"1 1 auto",children:[(0,i.jsx)(a.so,{title:g,align:"center",children:(0,i.jsxs)(a.EY,{font:"body.medium",color:"onSurface.nLv1",mr:"xs",children:[(0,i.jsx)(a.az,{as:"span",mr:"xs",children:g}),m&&(0,i.jsx)(p.AG,{...m})]})}),(0,i.jsx)(a.EY,{font:"assistive.default",color:x?"primary.default":"onSurface.nLv3",mr:"xxs",ml:x?0:"xs",children:(0,i.jsx)(r.A,{id:"manager"})})]})})]})})})}},61777:(e,t,s)=>{s.r(t),s.d(t,{default:()=>ef,excludedSeasonIds:()=>eg});var i=s(6029),l=s(21377),a=s(44194),n=s(41249),r=s(55729),o=s(90248),d=s(45860),c=s(65789),u=s(62859),p=s(8703),h=s(16206),x=s(30182),g=s(10292),m=s(947),f=s(54409),y=s(52839),j=s(70591),v=s(30971),b=s(73959),_=s(24159),w=s(41078),k=s(56008),C=s(65078);function S(e){let{statistic:t,topPlayer:s,sport:l,first:a,left:r}=e;return s?(0,i.jsxs)(n.so,{h:56,w:"100%",align:"center",direction:r?"row":"row-reverse",gap:"lg",overflow:"hidden",hoverBg:"surface.s2",cursor:"pointer",pl:r?"lg":void 0,pr:r?void 0:"lg",children:[(0,i.jsx)(g.t,{size:40,id:s.player.id,style:{display:"block"}}),(0,i.jsxs)(n.so,{overflow:"hidden",direction:"column",justify:"center",align:r?"flex-start":"flex-end",gap:"xs",children:[(0,i.jsx)(n.EY,{font:"body.medium",color:"onSurface.nLv1",children:(0,i.jsx)(v.A,{sport:l,stat:s.statistics,selectedStat:t})}),(0,i.jsx)(n.EY,{w:"100%",font:"assistive.default",color:"onSurface.nLv3",ellipsis:!0,as:"div",children:(0,i.jsx)(_.c,{entity:s.player,short:!0})})]})]}):a?(0,i.jsx)(w.A,{messageId:"yet.to.perform",isInverted:!r,width:"100%"}):null}function A(e){let{statistic:t,homePlayer:s,awayPlayer:l,sport:a,first:o}=e;if(!s&&!l)return null;let d=(null==s?void 0:s.player)?j.uc:r.Fragment,c=(null==l?void 0:l.player)?j.uc:r.Fragment;return(0,i.jsxs)(n.so,{justify:s||o?"space-between":"flex-end",children:[(0,i.jsx)(d,{player:null==s?void 0:s.player,style:{width:"50%"},children:(0,i.jsx)(S,{statistic:t,topPlayer:s,sport:a,first:o,left:!0})}),(0,i.jsx)(c,{player:null==l?void 0:l.player,style:{width:"50%"},children:(0,i.jsx)(S,{statistic:t,topPlayer:l,sport:a,first:o})})]})}function P(e){let{statistic:t,homePlayers:s,awayPlayers:a,sport:o,type:d}=e,c=(0,m.A)(),[u,p]=(0,r.useState)(!1);return s.length||a.length?(0,i.jsxs)(n.az,{style:{userSelect:"none"},children:[(0,i.jsxs)(n.so,{bg:u?"surface.s2":"transparent",pt:"md",pb:"xs",align:"center",justify:"center",onClick:()=>p(e=>!e),cursor:"pointer",children:[(0,i.jsx)(n.EY,{font:"assistive.default",color:"onSurface.nLv3",mr:"xs",children:(0,b.y)(c,t,o,d===l.Vw_.playoffs)}),(0,i.jsx)(f.zQC,{icon:u?"chevron-up":"chevron-down",width:24,height:24,fill:"onSurface.nLv1"})]}),(0,i.jsx)(A,{statistic:t,homePlayer:s[0],awayPlayer:a[0],sport:o,first:!0}),u&&Array.from({length:4}).map((e,l)=>{let n=l+1;return(0,i.jsx)(A,{statistic:t,homePlayer:s[n],awayPlayer:a[n],sport:o},t+n)})]}):null}function H(e){let{homeTeamId:t,awayTeamId:s,sport:a,uniqueTournamentId:o,seasonId:u,type:p}=e,{data:h,error:x}=(0,d.Ay)(l.cWY.topPlayers(t,o,u,p)),{data:g,error:m}=(0,d.Ay)(l.cWY.topPlayers(s,o,u,p)),f=(0,r.useMemo)(()=>(0,y.t)(a),[o]);return x&&m||!f?null:((null==h?void 0:h.topPlayers)||x)&&((null==g?void 0:g.topPlayers)||m)?(0,i.jsxs)(c.Zp,{children:[(0,i.jsx)(c.Zp.Header,{titleId:"top_players"}),(0,i.jsx)(n.az,{pb:["sm","md"],children:f.map(e=>(0,i.jsx)(P,{sport:a,statistic:e,homePlayers:((null==h?void 0:h.topPlayers[e])||[]).filter(e=>e.playedEnough),awayPlayers:((null==g?void 0:g.topPlayers[e])||[]).filter(e=>e.playedEnough),type:p},e))})]}):(0,i.jsx)(k.A,{})}function I(e){var t,s;let{event:l}=e,a=l.tournament.category.sport.slug,n=(0,C.g3)();return l.seasonStatisticsType&&(null==(t=l.tournament.uniqueTournament)?void 0:t.id)&&(null==(s=l.season)?void 0:s.id)&&-1!==y.u.indexOf(a)?(0,i.jsx)(H,{homeTeamId:n?l.awayTeam.id:l.homeTeam.id,awayTeamId:n?l.homeTeam.id:l.awayTeam.id,sport:a,uniqueTournamentId:l.tournament.uniqueTournament.id,seasonId:l.season.id,type:l.seasonStatisticsType}):null}var z=s(79853),M=s(22835),T=s(73011),R=s(54863),V=s(12174),L=s(50154),O=s(99382),E=s(26331),G=s(73088),N=s(28132),F=s(90715),B=s(62827),D=s(30479),Y=s(23695),U=s(12785),W=s(19673),Z=s(10234),Q=s(52695);function K(e){let{event:t}=e,s=(0,E.A)(),a=(0,W.y)(s);if(t.tournament.category.sport.slug!==l.QCR.Football||!t.hasEventPlayerStatistics)return null;let r=t.tournament.uniqueTournament?(0,i.jsx)(Q.O,{uniqueTournament:t.tournament.uniqueTournament}):(0,i.jsx)(Z.J,{tournament:t.tournament});return(0,i.jsx)(c.Zp,{isInverseDesktop:!0,children:(0,i.jsxs)(n.so,{p:"md",gap:"lg",children:[(0,i.jsx)(f.G_L,{fill:"onSurface.nLv3",width:"24",height:"24",minW:24}),(0,i.jsxs)(n.az,{children:[(0,i.jsx)(n.EY,{block:!0,font:"body.small",color:"onSurface.nLv1",mb:"sm",children:(0,i.jsx)(o.A,{id:"rating_lineups_info",values:{name:r}})}),(0,i.jsxs)("a",{href:a,target:"_blank",rel:"noreferrer",children:[(0,i.jsx)(n.EY,{textTransform:"firstLetter",font:"assistive.default",color:"primary.default",children:(0,i.jsx)(o.A,{id:"read_more"})}),(0,i.jsx)(f.CCT,{width:"16",height:"16",ml:"xxs",fill:"primary.default",style:{verticalAlign:"middle"}})]})]})]})})}var $=s(67717),X=s(12047),q=s(61234),J=s(5276),ee=s(5998),et=s(33144),es=s(94604);let ei=e=>{let{sportSlug:t,team:s}=e;return(0,i.jsx)(n.so,{w:"100%",grow:1,justify:"flex-start",pl:"lg",children:(0,i.jsx)(j.gT,{team:s,sport:t,children:(0,i.jsxs)(n.so,{align:"center",cursor:"pointer",gap:"lg",children:[(0,i.jsx)(et.p,{id:s.id,name:s.name,size:40}),(0,i.jsx)(n.EY,{font:"display.large",children:(0,i.jsx)(es.Rm,{team:s})})]})})})};function el(e){var t,s,a,o,d,p,h,x,g,m;let{event:f,leftTeam:y,rightTeam:j}=(0,r.useContext)(u.y$),v=f.tournament.category.sport.slug,b=v===l.QCR.Football,_=e.lineups.left.players.some(e=>e.substitute)||e.lineups.right.players.some(e=>e.substitute),w=!!(e.lineups.left.players.find(e=>e.statistics&&e.statistics.rating)||e.lineups.right.players.find(e=>e.statistics&&e.statistics.rating));return(0,i.jsxs)(n.so,{direction:"column",gap:"sm",children:[b&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.so,{gap:"sm",my:"sm",children:[(0,i.jsx)(ei,{sportSlug:v,team:y}),(0,i.jsx)(ei,{sportSlug:v,team:j})]}),(0,i.jsxs)(n.so,{gap:"sm",children:[(0,i.jsx)(n.so,{w:"100%",maxW:"50%",grow:1,children:(null==(t=e.managers)?void 0:t.leftManager)&&(0,i.jsx)(q.A,{manager:null==(s=e.managers)?void 0:s.leftManager,isBorderHidden:!0,incidents:null==(a=e.incidents)?void 0:a.filter(e=>e.manager),isCard:!0})}),(0,i.jsx)(n.so,{w:"100%",maxW:"50%",grow:1,children:(null==(o=e.managers)?void 0:o.rightManager)&&(0,i.jsx)(q.A,{manager:null==(d=e.managers)?void 0:d.rightManager,isBorderHidden:!0,incidents:null==(p=e.incidents)?void 0:p.filter(e=>e.manager),isCard:!0})})]})]}),!e.hasFormation&&b&&(0,i.jsxs)(c.Zp,{children:[(0,i.jsx)(c.Zp.Header,{titleId:"startingEleven.title"}),(0,i.jsxs)(n.so,{children:[(0,i.jsx)(ee.A,{players:e.lineups.left.players.filter(e=>!e.substitute),team:y,manager:null==(h=e.managers)?void 0:h.leftManager,highlightStarters:!1,hasRating:w,event:f,...e},"left"),(0,i.jsx)(n.cG,{mt:"sm",mb:"md",vertical:!0,mx:"sm"}),(0,i.jsx)(ee.A,{players:e.lineups.right.players.filter(e=>!e.substitute),team:j,manager:null==(x=e.managers)?void 0:x.rightManager,hasTopBorder:!1,highlightStarters:!1,hasRating:w,event:f,...e},"right")]})]}),_&&(0,i.jsxs)(c.Zp,{isInverseDesktop:!0,children:[b&&(0,i.jsx)(c.Zp.Header,{titleId:"substitutions"}),(0,i.jsxs)(n.so,{children:[(0,i.jsx)(ee.A,{players:b?e.lineups.left.players.filter(e=>e.substitute):e.lineups.left.players,team:y,manager:null==(g=e.managers)?void 0:g.leftManager,hasRating:w,event:f,...e},"left"),(0,i.jsx)(n.cG,{mt:"sm",mb:"md",vertical:!0,mx:"sm"}),(0,i.jsx)(ee.A,{players:b?e.lineups.right.players.filter(e=>e.substitute):e.lineups.right.players,team:j,manager:null==(m=e.managers)?void 0:m.rightManager,hasTopBorder:!1,hasRating:w,event:f,...e},"right")]})]}),(0,i.jsx)(J.PM,{left:e.lineups.left.missingPlayers,right:e.lineups.right.missingPlayers})]})}function ea(e){var t,s,a;let o=(0,X.Ay)({isSportMenuVisible:!0,isInMobileTabs:!0}),[d,p]=(0,r.useState)(l.cxP.Left),h=d===l.cxP.Left?e.lineups.left:e.lineups.right,{event:x,leftTeam:g,rightTeam:m}=(0,r.useContext)(u.y$),f=e.hasFormation?h.players.filter(e=>e.substitute):h.players,y=x.tournament.category.sport.slug===l.QCR.Football,j=d===l.cxP.Left?null==(t=e.managers)?void 0:t.leftManager:null==(s=e.managers)?void 0:s.rightManager,v=e.lineups.left.players.some(e=>e.substitute)||e.lineups.right.players.some(e=>e.substitute),b=e.lineups[d].players.filter(e=>!e.substitute),_=e.lineups[d].players.filter(e=>e.substitute),w=!!(e.lineups.left.players.find(e=>e.statistics&&e.statistics.rating)||e.lineups.right.players.find(e=>e.statistics&&e.statistics.rating)),k=y&&!!b.length;return(0,i.jsxs)(n.az,{children:[(0,i.jsx)(n.PI,{top:o,children:e=>(0,i.jsx)(n.az,{bg:[void 0,"surface.s1"],mt:-8,mx:-8,px:"sm",py:e?0:"sm",children:(0,i.jsx)(n.az,{bg:"surface.s1",br:e?void 0:"lg",elevation:[e?void 0:2,void 0],w:[e?"100vw":"100%","100%"],mx:[e?-8:0,0],py:["sm",0],children:(0,i.jsx)($.n,{mt:"0",px:["sm",0],gap:"sm",activeTeam:d,onTeamClick:p})})})}),(0,i.jsxs)(n.so,{direction:"column",gap:"sm",children:[j&&(0,i.jsx)(q.A,{manager:j,incidents:null==(a=e.incidents)?void 0:a.filter(e=>e.manager),isCard:!0,isBorderHidden:!0}),!e.hasFormation&&(0,i.jsxs)(c.Zp,{isInverseDesktop:!0,children:[k&&(0,i.jsx)(c.Zp.Header,{titleId:"startingEleven.title",as:"h4"}),(0,i.jsx)(ee.A,{hideTeamHeader:!0,players:y?b:f,team:d===l.cxP.Left?g:m,highlightStarters:!y,hasRating:w,event:x,...e},d)]}),v&&y&&!!_.length&&(0,i.jsxs)(c.Zp,{isInverseDesktop:!0,children:[(0,i.jsx)(c.Zp.Header,{titleId:"substitutions",as:"h4"}),(0,i.jsx)(ee.A,{hideTeamHeader:!0,players:_,team:d===l.cxP.Left?g:m,hasRating:w,event:x,...e},d)]}),!!(e.lineups.left.missingPlayers||e.lineups.right.missingPlayers)&&(0,i.jsx)(J.Sb,{missingPlayers:h.missingPlayers})]})]})}function en(e){let{isMobile:t,isDesktop:s}=(0,a.$c)(),{location:l}=(0,r.useContext)(u.y$),n=s&&l===u.cb.EventPage;return t||!n?(0,i.jsx)(ea,{...e}):(0,i.jsx)(el,{...e})}function er(e){let t,l,d=(0,E.A)(),{event:c,location:p}=(0,r.useContext)(u.y$),{bestPlayer:h}=(0,V.Y)(c),{isDesktop:x}=(0,a.$c)(),g=x&&p===u.cb.EventPage,{isAdsTestTreatment:m}=(0,L.Q)();try{t=e.lineups.left.formation?(0,F.V)(e.lineups.left.formation,e.lineups.left.players.filter(e=>!e.substitute)):void 0,l=e.lineups.right.formation?(0,F.V)(e.lineups.right.formation,e.lineups.right.players.filter(e=>!e.substitute)):void 0}catch(e){console.error(e)}let y=!!(t&&l),j=window.location.host+G.z.getTranslatedRoute(d,"event",{id:c.customId,name:c.slug,sport:c.tournament.category.sport.slug}).route,v="#"+(0,D.HL)({id:c.id,tab:N.H.Lineups}),{isShareEnabled:b,componentRef:_,shareButton:w}=function(e,t){var l;let[a,d]=(0,B.yR)("sofa.isComponentShareEnabled",!!(null==(l=window.navigator.clipboard)?void 0:l.write)),[c,u]=(0,r.useState)(!1),p=(0,r.useRef)(null),h={autoClose:5e3,closeButton:!1,className:"sofa-toast--info",position:"bottom-center"},x=(0,r.useCallback)(async()=>{if(p.current&&a)try{u(!0);let e=(await s.e(3933).then(s.t.bind(s,63067,23))).default,l=await e(p.current,{useCORS:!0,allowTaint:!0}),a=await new Promise(e=>l.toBlob(e)),r=new Blob([t||""],{type:"text/plain"});a&&(await window.navigator.clipboard.write([new ClipboardItem({"image/png":a,"text/plain":r})]),(0,B.MZ)((0,i.jsxs)(n.so,{align:"center",children:[(0,i.jsx)(f.G_L,{fill:"onColor.primary",mr:"lg"}),(0,i.jsx)(n.EY,{block:!0,color:"onColor.primary",font:"display.small",children:(0,i.jsx)(o.A,{id:"basic.copiedToClipboard"})})]}),h))}catch(e){d(!1),(0,B.MZ)((0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.so,{align:"center",children:[(0,i.jsx)(f.cgL,{fill:"onColor.primary",mr:"md"}),(0,i.jsx)(n.EY,{block:!0,c:"onColor.primary",font:"display.small",children:(0,i.jsx)(o.A,{id:"error.anErrorOccurred"})})]}),e.message&&(0,i.jsx)(n.EY,{block:!0,c:"onColor.primary",font:"body.small",mt:"sm",children:e.message})]}),{...h,className:"sofa-toast--error"})}finally{u(!1)}},[p.current,c,a]),g=a?(0,i.jsx)(o.A,{id:"basic.share",children:t=>(0,i.jsx)(n.$n,{"aria-label":String(t),size:"xs",tertiary:!0,disabled:c,style:c?{cursor:"wait"}:void 0,onClick:x,children:e||(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(o.A,{id:"basic.share"}),(0,i.jsx)(f.VJ,{fill:"surface.s1",ml:"xxs",width:16,height:16})]})})}):null;return{isGeneratingScreenshot:c,shareButton:g,componentRef:p,isShareEnabled:a}}((0,i.jsxs)(n.so,{justify:"center",align:"center",children:[(0,i.jsx)(o.A,{id:"share_match_lineups"}),(0,i.jsx)(f.VJ,{fill:"surface.s1",ml:"xxs",width:"16",height:"16"})]}),j+v);return(0,i.jsxs)(n.az,{children:[y&&(0,i.jsx)(n.az,{bg:["surface.s1",void 0],px:[0,g&&!m?"sm":0],children:(0,i.jsx)(U.Ko,{...e,leftFormation:t,rightFormation:l,ref:_,playerOfTheMatchId:null==h?void 0:h.player.id,isShareEnabled:b,shareButton:w})}),(0,i.jsxs)(n.so,{direction:"column",gap:"sm",p:"sm",children:[(0,i.jsxs)(n.so,{direction:g?"column-reverse":"column",gap:"sm",children:[(0,i.jsx)(en,{...e,hasFormation:y,playerOfTheMatchId:null==h?void 0:h.player.id}),(0,i.jsx)(Y.K,{})]}),(0,i.jsx)(K,{event:c}),(0,i.jsx)(O.Xl,{event:c})]})]})}var eo=s(76868);function ed(e){let{lineups:t,managers:s}=e,[a,o]=(0,r.useState)(l.cxP.Left),{event:d,leftTeam:p,rightTeam:h}=(0,r.useContext)(u.y$),x=(0,X.Ay)(),[g,m,f]=a===l.cxP.Left?[p,s.leftManager,t.left]:[h,s.rightManager,t.right];return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.az,{bg:"surface.s1",w:"100%",position:"sticky",top:[x,0],zIndex:n.Py.Sticky,p:"sm",children:(0,i.jsx)($.n,{activeTeam:a,onTeamClick:e=>o(e)})}),(0,i.jsxs)(n.so,{p:"sm",gap:"sm",direction:"column",children:[(0,i.jsxs)(c.Zp,{isInverseDesktop:!0,children:[(0,i.jsx)(c.Zp.Header,{titleId:"probable_pitchers"}),(0,i.jsx)(ee.A,{players:f.players,team:g,event:d,hideTeamHeader:!0}),0===f.players.length&&(0,i.jsx)(eo.p,{graphic:"no-data",descriptionMessageId:"probable_pitchers_empty"})]}),!!(t.left.missingPlayers||t.right.missingPlayers)&&(0,i.jsx)(J.Sb,{missingPlayers:f.missingPlayers})]})]})}function ec(){return(0,i.jsx)(n.az,{h:900})}function eu(){let{event:e}=(0,r.useContext)(u.y$),{managers:t}=(0,z.K)(e),{lineups:s,confirmed:a,error:n}=(0,R.Ir)({jerseyStyle:"fancy"}),{data:o}=(0,d.Ay)(l.bnp.incidents(e.id),(0,p.rf)(e));return n?null:s?a?(0,i.jsx)(er,{lineups:s,incidents:null==o?void 0:o.incidents,managers:t,confirmed:a,showPlayerStatistics:!1}):(0,i.jsx)(ed,{lineups:s,managers:t}):(0,i.jsx)(ec,{})}var ep=s(31130),eh=s(27778),ex=s(75318);let eg=[17564,17565,17566,17567,17568,17569,17570,17571,1151,2636,16,2531,7528],em=e=>{let{showPlayerStatistics:t}=e,{event:s,location:g}=(0,r.useContext)(u.y$),m=s.tournament.category.sport.slug,{managers:f}=(0,z.K)(s),{lineups:y,confirmed:j,error:v}=(0,R.Ir)({jerseyStyle:m===l.QCR.Football?"clean":"fancy"}),{data:b}=(0,d.Ay)(l.bnp.incidents(s.id),(0,p.rf)(s)),{hasPregameTopPlayers:_}=(0,M.M)(s),{isDesktop:w}=(0,a.$c)(),k=w&&g===u.cb.EventPage,C=s.season&&eg.includes(s.season.id);if(_&&(v||y&&!j))return(0,i.jsxs)(n.so,{direction:"column",p:["sm",0],gap:["sm","md"],children:[(0,i.jsx)(I,{event:s}),(0,i.jsx)(x.m,{home:null==y?void 0:y.left.missingPlayers,away:null==y?void 0:y.right.missingPlayers})]});if(!y)return(0,i.jsx)(eh.A,{});let S=m!==l.QCR.Football?(0,i.jsx)(c.Zp.Header,{titleId:T.bU.includes(m)?"boxScore":"players",as:"h2"}):null;return w&&t?(0,i.jsxs)(c.HH,{isCard:k,children:[S,(0,i.jsxs)(n.tU,{variant:"secondary",initialValue:1,children:[(0,i.jsxs)(n.az,{pt:"md",px:"md",children:[(0,i.jsx)(n.tU.Tab,{tabKey:1,children:(0,i.jsx)(o.A,{id:"lineups"})}),!C&&(0,i.jsx)(n.tU.Tab,{tabKey:2,children:(0,i.jsx)(o.A,{id:"player_stats"})})]}),(0,i.jsx)(n.tU.Panel,{tabKey:1,children:(0,i.jsx)(er,{lineups:y,incidents:null==b?void 0:b.incidents,managers:f,confirmed:j})}),!C&&(0,i.jsx)(n.tU.Panel,{tabKey:2,children:(0,i.jsx)(h.A,{lineups:y})})]})]}):(0,i.jsxs)(c.HH,{isCard:k,children:[S,(0,i.jsx)(er,{lineups:y,incidents:null==b?void 0:b.incidents,managers:f,confirmed:j,showPlayerStatistics:t})]})};function ef(e){let{hasLineups:t,showPlayerStatistics:s}=e,{event:a}=(0,r.useContext)(u.y$),n=a.tournament.category.sport.slug,o=n===l.QCR.ESports&&(0,p.f2)(a.tournament.category.id),{couldHavePregameTopPlayers:d}=(0,M.M)(a);return o||!1===t&&!d?null:n===l.QCR.Cricket?(0,i.jsx)(ep.A,{}):n===l.QCR.Rugby?(0,i.jsx)(ex.u,{}):n===l.QCR.Baseball?(0,i.jsx)(eu,{}):(0,i.jsx)(em,{showPlayerStatistics:s})}},71306:(e,t,s)=>{s.d(t,{A:()=>r,I:()=>n});var i=s(55729),l=s(48886),a=s(99586);let n=(e,t)=>{let s=t.short||e.stat.short;return s&&t.short===e.stat.short||!s&&e.stat.value===t.value?{stat:e.stat,dir:e.dir===l.U.DESC?l.U.ASC:l.U.DESC}:{stat:t,dir:l.U.DESC}},r=(e,t,s)=>{let[r,o]=(0,i.useState)({stat:t,dir:l.U.DESC}),d=(0,a.C)(e,r,t,s),c=(0,i.useCallback)(e=>{o(t=>n(t,e))},[]);return{sortConfig:r,setSortConfig:o,sortedPlayers:d,updateSortStatistic:c}}},73488:(e,t,s)=>{s.d(t,{AG:()=>o,FU:()=>r,X0:()=>d});var i=s(6029),l=s(41249),a=s(54409),n=s(58657);let r=e=>{let{isInjury:t}=e;return t?(0,i.jsx)(a.NcS,{icon:"substitution-injured"}):(0,i.jsx)(a.NcS,{icon:"substitution"})},o=e=>{let{hasYellowCard:t,hasRedCard:s,hasYellowRedCard:l}=e;return l?(0,i.jsx)(a.NcS,{icon:"card-double-yellow",width:"16",height:"16"}):s?(0,i.jsx)(a.NcS,{icon:"card",width:"16",height:"16",fill:"error.default"}):t?(0,i.jsx)(a.NcS,{icon:"card",width:"16",height:"16",fill:"scoreRating.s65"}):null},d=e=>{let{goalsScored:t,hasScoredPenalty:s,hasScoredOwnGoal:r,inField:o}=e;if(r&&!t)return(0,i.jsx)(a.NcS,{icon:"football-own-goal",width:"16",height:"16",fill:"error.default","data-testid":"lineups_goal_info"});if(s&&1===t)return(0,i.jsx)(a.NcS,{icon:"football-penalty",width:"16",height:"16",fill:"secondary.default","data-testid":"lineups_goal_info"});if(t){if(o){let e=t>1;return(0,i.jsxs)(l.az,{position:"relative",left:e?"6":void 0,ml:"xxs","data-testid":"lineups_goal_info",children:[e&&(0,i.jsx)(l.EY,{font:"table.small",color:"secondary.default",position:"relative",children:t}),(0,i.jsx)(n.M,{incidentType:"goal",incidentClass:"regular",svgProps:{fill:"secondary.default",width:16,height:16}})]})}return(0,i.jsx)(l.az,{position:"relative",ml:"xxs","data-testid":"lineups_goal_info",children:Array(t).fill(0).map((e,t)=>(0,i.jsx)(n.M,{incidentType:"goal",incidentClass:"regular",svgProps:{fill:"secondary.default",width:16,height:16}},"goal-".concat(t)))})}return null}},75318:(e,t,s)=>{s.d(t,{u:()=>Y});var i=s(6029),l=s(44194),a=s(41249),n=s(55729),r=s(65789),o=s(62859),d=s(90248),c=s(33007),u=s(33144),p=s(8703),h=s(16620),x=s(48886),g=s(70591),m=s(24159),f=s(54863),y=s(55529),j=s(61234),v=s(5998),b=s(41735);let _=()=>{let{colors:e}=(0,b.useTheme)();return(0,i.jsx)("svg",{viewBox:"0 0 344 608",children:(0,i.jsxs)("g",{fill:"none",fillRule:"evenodd",children:[(0,i.jsx)("path",{fill:e.graphicsTerrain.football,d:"M0 0h344v608H0z"}),(0,i.jsx)("g",{fill:e.onSurface.nLv5,children:(0,i.jsx)("path",{d:"M4 52h336v72H4zM4 196h336v72H4zM4 340h336v72H4zM4 484h336v72H4z"})}),(0,i.jsxs)("g",{fill:e.surface.s1,fillRule:"nonzero",children:[(0,i.jsx)("path",{d:"M340 303H4v289h336V303zM5.953 305.001h332.094v285H5.953v-285z"}),(0,i.jsx)("path",{d:"M4 556.011h336v-2.054H4zM4 446.011h336v-2.054H4z"}),(0,i.jsx)("path",{d:"M28 458.011v-26h2v26zM134 532.012h25.436v-2.054H134zM112 356.012h26v-2.054h-26zM159 356.012h26v-2.054h-26zM205 356.012h26v-2.054h-26zM184 532.012h25.436v-2.054H184zM92 532.012H66v-2.054h12v-24.85h2v24.85h12zM92 356.027H80v11.985h-2v-11.985H66v-2.03h12v-11.985h2v11.985h12zM327 356.027h-12v11.985h-2v-11.985h-12v-2.03h12v-11.985h2v11.985h12zM42 356.027H30v11.985h-2v-11.985H16v-2.03h12v-11.985h2v11.985h12zM277 356.027h-12v11.985h-2v-11.985h-12v-2.03h12v-11.985h2v11.985h12zM280.339 532.012H255v-2.054h11.74v-24.85h2.054v24.85h11.545zM330.339 532.012H305v-2.054h11.74v-24.85h2.054v24.85h11.545zM42 532.012H16v-2.054h12v-24.85h2v24.85h12zM78 458.012v-26h2v26zM266.63 458.011v-26h2.054v26zM28 316.012h2v-12h-2zM78 316.012h2v-12h-2zM263 316.012h2v-12h-2zM313 316.012h2v-12h-2zM316.728 458.011v-26h2.055v26zM190.127 600.012l-3.509-34.731h-29.355l-3.507 34.693-1.965-.045 4.314-43.917h2.065l-.71 7.215h28.962l-.703-7.215h1.981l4.774 43.962z"}),(0,i.jsxs)("g",{children:[(0,i.jsx)("path",{d:"M340 305.011H4v-289h336v289zM5.953 303.01h332.094v-285H5.953v285z"}),(0,i.jsx)("path",{d:"M4 52h336v2.054H4zM4 162h336v2.054H4z"}),(0,i.jsx)("path",{d:"M28 150v26h2v-26zM134 75.999h25.436v2.054H134zM112 251.999h26v2.054h-26zM159 251.999h26v2.054h-26zM205 251.999h26v2.054h-26zM184 75.999h25.436v2.054H184zM92 75.999H66v2.054h12v24.85h2v-24.85h12zM92 251.984H80V240h-2v11.985H66v2.03h12v11.985h2v-11.985h12zM327 251.984h-12V240h-2v11.985h-12v2.03h12v11.985h2v-11.985h12zM42 251.984H30V240h-2v11.985H16v2.03h12v11.985h2v-11.985h12zM277 251.984h-12V240h-2v11.985h-12v2.03h12v11.985h2v-11.985h12zM280.339 75.999H255v2.054h11.74v24.85h2.054v-24.85h11.545zM330.339 75.999H305v2.054h11.74v24.85h2.054v-24.85h11.545zM42 75.999H16v2.054h12v24.85h2v-24.85h12zM78 149.999v26h2v-26zM266.63 150v26h2.054v-26zM28 291.999h2v12h-2zM78 291.999h2v12h-2zM263 291.999h2v12h-2zM313 291.999h2v12h-2zM316.728 150v26h2.055v-26zM190.127 7.999l-3.509 34.731h-29.355l-3.507-34.693-1.965.045 4.314 43.917h2.065l-.71-7.215h28.962L185.72 52h1.981l4.774-43.962z"})]})]})]})})},w=e=>{let{type:t,children:s}=e;return(0,i.jsxs)(a.az,{position:"relative",children:[(0,i.jsx)(_,{}),(0,i.jsx)(a.az,{position:"absolute",w:"100%",h:"100%",px:"1%",py:"15%",left:0,top:0,children:(0,i.jsx)(a.az,{w:"100%",h:"100%",display:"grid",style:{gridTemplateColumns:"repeat(".concat("fifteens"===t?5:4,", 1fr)"),gridTemplateRows:"repeat(".concat(7,", 1fr)")},children:s})})]})};var k=s(12605),C=s(19991),S=s(21377),A=s(54409),P=s(84942),H=s(99326),I=s(73488);let z=(0,b.default)(g.uc).withConfig({componentId:"sc-2735a21f-0"})(["display:flex;flex-direction:column;justify-content:flex-start;align-items:center;position:relative;z-index:",";border-radius:4px;text-align:center;cursor:pointer;transition:opacity 0.1s ease-in-out;width:56px;height:72px;&:hover{opacity:0.8;}"],a.Py.Button);function M(e){var t,s,l;let{player:r,incidents:o,onClick:c,jersey:u,color:p,useShortName:h,showSubstitutionNames:x=!0,showGoalScorer:g=!0,nameWidth:m,hasRatings:f,isPlayerOfTheMatch:y}=e,j=(0,n.useMemo)(()=>o?(0,H.h$)({id:r.player.id,incidents:o,useShortName:h}):{},[r,o]),v=null==(t=r.statistics)?void 0:t.rating,b=1;void 0===v&&r.avgRating&&(v=r.avgRating,b=2);let _=(0,P.z)(r.player,(0,H.kx)(r,h)),w=(0,H.sP)(_,r.captain);return(0,i.jsxs)(z,{onClick:c,player:r.player,"data-testid":"lineups_player",sportSlug:S.QCR.Rugby,children:[y&&(0,i.jsx)(A.ue7,{w:16,h:16,fill:(0,C.Et)(null==(s=r.statistics)?void 0:s.rating),position:"absolute",top:-16,left:"calc(50% - 8px)"}),(0,i.jsx)(a._V,{w:"28px",h:"32px",src:u,alt:""}),(0,i.jsx)(a.EY,{position:"absolute",top:"3px",left:"calc(50% - 12px)",align:"center",w:"xl",font:"table.large",fontSize:r.jerseyNumber&&r.jerseyNumber.length>=3?12:void 0,letterSpacing:"-0.2px",mt:r.jerseyNumber&&r.jerseyNumber.length>=3?"xxs":void 0,color:p?"#".concat(p.fancyNumber):"onSurface.nLv1","data-testid":"lineups_number",children:r.jerseyNumber}),j.substitutionIn&&(0,i.jsx)(a.az,{position:"absolute",top:"0",left:"-2","data-testid":"lineups_sub_info",children:(0,i.jsx)(I.FU,{isInjury:j.substitutionIn.isInjury})}),!j.substitutionIn&&j.substitutionOut&&(0,i.jsx)(a.az,{position:"absolute",top:"0",left:"-2","data-testid":"lineups_sub_info",children:(0,i.jsx)(I.FU,{isInjury:j.substitutionOut.isInjury})}),f&&(0,i.jsx)(a.az,{position:"absolute",top:"lg",left:-2,"data-testid":"lineups_rating",children:(0,i.jsx)(k.A,{rating:v,format:"box",size:"sm",decimalPoints:b})}),(0,i.jsx)(a.EY,{align:"center",lineHeight:1,font:"assistive.default",color:"onSurface.nLv1",pt:"xs",title:w,w:m,style:{hyphens:"auto"},"data-testid":"lineups_name",children:w}),x&&(null==(l=j.substitutionIn)?void 0:l.forPlayer)&&(0,i.jsxs)(a.EY,{align:"center",lineHeight:1,font:"table.small",color:"onSurface.nLv3",title:j.substitutionIn.forPlayer,children:[(0,i.jsx)(d.A,{id:"injury_status_out"}),": ",j.substitutionIn.forPlayer]}),(0,i.jsx)(a.az,{position:"absolute",top:"0",right:"-2",children:(0,i.jsx)(I.AG,{...j})}),g&&(0,i.jsx)(a.az,{position:"absolute",top:"lg",right:"-2",children:(0,i.jsx)(I.X0,{...j,inField:!0})})]})}let T=e=>{let{type:t="fifteens",players:s,incidents:l,jersey:n,jerseyNumberColor:r,onPlayerClick:o}=e,d="fifteens"===t?y.vD:y.Xj,c="fifteens"===t?y.Cy:y.uU,u=(e,t)=>{o&&(e.preventDefault(),o(t))};return(0,i.jsx)(w,{type:t,children:s.map(e=>e.shirtNumber?(0,i.jsx)(a.so,{position:"relative",justify:"center",align:"center",style:d[e.shirtNumber],children:(0,i.jsx)(a.az,{position:"absolute",style:c[e.shirtNumber],children:(0,i.jsx)(M,{player:e,incidents:l,jersey:n,color:r,nameWidth:64,showSubstitutionNames:!1,showGoalScorer:!1,onClick:t=>u(t,e.player)})})},e.player.id):null)})},R=()=>{let{event:e,team:t,incidents:s,manager:l,jersey:n,startingPlayers:r,jerseyNumberColor:o,substitutePlayers:d}=(0,f.rR)(),{openEventPlayerStatistics:c}=(0,h.d)();return e.isEditor?(0,i.jsxs)(a.so,{direction:"column",gap:"md",children:[(0,i.jsx)(g.gT,{team:t,sport:(0,p.c5)(e),children:(0,i.jsxs)(a.so,{gap:"lg",align:"center",children:[(0,i.jsx)(u.p,{size:40,id:t.id,name:t.name}),(0,i.jsx)(a.EY,{font:"display.large",children:(0,i.jsx)(m.c,{entity:t})})]})}),(0,i.jsx)(a.az,{br:"sm",overflow:"hidden",children:(0,i.jsx)(T,{type:e.tournament.category.sportVariant===y.WM?"sevens":"fifteens",players:r,incidents:s,jersey:n,jerseyNumberColor:o,onPlayerClick:e.hasEventPlayerStatistics?t=>c({event:e,player:t},x._.Lineups):void 0})}),l&&(0,i.jsx)(j.A,{manager:l,incidents:null==s?void 0:s.filter(e=>e.manager),isCard:!0,isBorderHidden:!0})]}):(0,i.jsxs)(a.so,{direction:"column",children:[(0,i.jsx)(g.gT,{team:t,sport:(0,p.c5)(e),children:(0,i.jsxs)(a.so,{gap:"lg",align:"center",px:"lg",py:"sm",hoverBg:"surface.s2",children:[(0,i.jsx)(u.p,{size:40,id:t.id,name:t.name}),(0,i.jsx)(a.EY,{font:"display.large",children:(0,i.jsx)(m.c,{entity:t})})]})}),(0,i.jsx)(v.A,{manager:l,hideTeamHeader:!0,team:t,event:e,players:[...r,...d],incidents:s})]})};var V=s(45527);let L=()=>{let{event:e,team:t,substitutePlayers:s,incidents:l}=(0,f.rR)();return(0,i.jsx)(v.A,{hideTeamHeader:!0,event:e,team:t,players:s,incidents:l})},O=()=>{let{event:e}=(0,n.useContext)(o.y$),{lineups:t}=(0,f.Ir)();return e.isEditor&&(0,H.kr)(t)?(0,i.jsxs)(a.az,{children:[(0,i.jsx)(a.EY,{font:"display.medium",align:"center",display:"block",pt:"xl",pb:"lg",children:(0,i.jsx)(d.A,{id:"substitutions"})}),(0,i.jsxs)(a.so,{children:[(0,i.jsx)(a.az,{flex:"1 1 0",children:(0,i.jsx)(V.i,{side:"left",children:(0,i.jsx)(L,{})})}),(0,i.jsx)(a.cG,{vertical:!0,mx:"md"}),(0,i.jsx)(a.az,{flex:"1 1 0",children:(0,i.jsx)(V.i,{side:"right",children:(0,i.jsx)(L,{})})})]})]}):null},E=()=>(0,i.jsxs)(a.az,{p:"sm",children:[(0,i.jsxs)(a.so,{children:[(0,i.jsx)(a.az,{flex:"1 1 0",children:(0,i.jsx)(V.i,{side:"left",children:(0,i.jsx)(R,{})})}),(0,i.jsx)(a.cG,{vertical:!0,mx:"md"}),(0,i.jsx)(a.az,{flex:"1 1 0",children:(0,i.jsx)(V.i,{side:"right",children:(0,i.jsx)(R,{})})})]}),(0,i.jsx)(O,{})]}),G=()=>(0,i.jsx)(a.az,{py:"lg",children:(0,i.jsxs)(a.tU,{variant:"secondary",children:[(0,i.jsxs)(a.az,{px:"lg",children:[(0,i.jsx)(a.tU.Tab,{children:(0,i.jsx)(d.A,{id:"lineups"})}),(0,i.jsx)(a.tU.Tab,{children:(0,i.jsx)(d.A,{id:"rugby_box_score"})})]}),(0,i.jsx)(a.tU.Panel,{children:(0,i.jsx)(E,{})}),(0,i.jsx)(a.tU.Panel,{children:(0,i.jsx)(a.az,{px:"sm",pt:"md",children:(0,i.jsx)(c.default,{showDivider:!1})})})]})}),N=()=>{let{openEventPlayerStatistics:e}=(0,h.d)(),{event:t,team:s,manager:n,incidents:r,jersey:o,startingPlayers:c,substitutePlayers:u,jerseyNumberColor:p}=(0,f.rR)(),{isDesktop:g}=(0,l.$c)();return t.isEditor?(0,i.jsxs)(a.az,{children:[(0,i.jsx)(T,{type:t.tournament.category.sportVariant===y.WM?"sevens":"fifteens",players:c,incidents:r,jersey:o,jerseyNumberColor:p,onPlayerClick:t.hasEventPlayerStatistics?s=>e({event:t,player:s},x._.Lineups):void 0}),(0,i.jsxs)(a.so,{direction:"column",py:"md",children:[n&&(0,i.jsx)(a.az,{px:"sm",children:(0,i.jsx)(j.A,{manager:n,incidents:null==r?void 0:r.filter(e=>e.manager),isCard:!0,isBorderHidden:!0})}),u.length>0&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(a.EY,{font:"display.medium",align:"center",pt:"xl",children:(0,i.jsx)(d.A,{id:"substitutions"})}),(0,i.jsx)(v.A,{hideTeamHeader:!0,team:s,event:t,players:u,incidents:r})]})]})]}):(0,i.jsxs)(i.Fragment,{children:[n&&(0,i.jsx)(a.az,{px:"sm",py:"sm",children:(0,i.jsx)(j.A,{manager:n,incidents:null==r?void 0:r.filter(e=>e.manager),isCard:g,isBorderHidden:!0})}),(0,i.jsx)(v.A,{hideTeamHeader:!0,team:s,event:t,players:[...c,...u],incidents:r})]})},F={height:"32px",display:"flex",justifyContent:"center",alignItems:"center",padding:0},B=()=>{let{team:e}=(0,f.rR)();return(0,i.jsx)(u.p,{size:24,id:e.id,name:e.name})},D=()=>(0,i.jsx)(a.az,{p:"sm",children:(0,i.jsx)(r.Zp,{isInverseDesktop:!0,children:(0,i.jsxs)(a.tU,{variant:"secondary",initialValue:S.cxP.Left,fullWidthTabs:!0,children:[(0,i.jsxs)(a.so,{p:"sm",children:[(0,i.jsx)(a.tU.Tab,{tabKey:S.cxP.Left,style:F,children:(0,i.jsx)(V.i,{side:"left",children:(0,i.jsx)(B,{})})}),(0,i.jsx)(a.az,{w:"lg"}),(0,i.jsx)(a.tU.Tab,{tabKey:S.cxP.Right,style:F,children:(0,i.jsx)(V.i,{side:"right",children:(0,i.jsx)(B,{})})})]}),(0,i.jsx)(a.tU.Panel,{tabKey:S.cxP.Left,children:(0,i.jsx)(V.i,{side:"left",children:(0,i.jsx)(N,{})})}),(0,i.jsx)(a.tU.Panel,{tabKey:S.cxP.Right,children:(0,i.jsx)(V.i,{side:"right",children:(0,i.jsx)(N,{})})})]})})});function Y(){let{event:e,location:t}=(0,n.useContext)(o.y$),{isDesktop:s}=(0,l.$c)(),d=s&&t===o.cb.EventPage,{lineups:c,error:u}=(0,f.Ir)({jerseyStyle:"fancy"});return u?null:d?(0,i.jsxs)(r.Zp,{children:[(0,i.jsx)(r.Zp.Header,{titleId:"players"}),c?e.hasEventPlayerStatistics?(0,i.jsx)(G,{}):(0,i.jsx)(E,{}):(0,i.jsx)(a.az,{h:900})]}):c?(0,i.jsx)(D,{}):(0,i.jsx)(a.az,{h:900})}},78944:(e,t,s)=>{s.d(t,{H7:()=>h,q6:()=>p});var i=s(6029),l=s(55729),a=s(947),n=s(90248),r=s(62859);let o=JSON.parse('{"rugby":{"goal.onePoint":"rugby.onePointGoal","goal.twoPoints":"rugby.twoPointGoal","goal.threePoints":"rugby.threePointGoal","goal.try":"rugby.try","goal.penaltyTry":"rugby.penaltyTry"},"basketball":{"One point":"basketball.onePoint","Two points":"basketball.twoPoints","Three points":"basketball.threePoints","Four points":"basketball_four_points"},"american-football":{"goal.touchdown":"touchdown","goal.extraPoint":"amf.extraPoint","goal.twoPointConversion":"amf.twoPointConversion","goal.defensive2ptConversion":"amf.defensive2ptConversion","goal.fieldGoal":"amf.fieldGoal","goal.safety":"amf.safety","goal.rouge":"amf.rouge"},"minifootball":{"accumulatedPenalty":"minifootball_accumulated_penalty"},"futsal":{"accumulatedPenalty":"minifootball_accumulated_penalty"},"ice-hockey":{"boarding":"penalty_boarding","broken_stick":"penalty_broken_stick","charging":"penalty_charging","closing_hand_on_puck":"penalty_closing_hand","cross_checking":"penalty_cross_checking","elbowing":"penalty_elbowing","clipping":"penalty_clipping","delay_game":"penalty_delay_of_game","illegal_check_to_head":"penalty_illegal_check","goalie_leave_crease":"penalty_goalie_leave_crease","hi_sticking":"penalty_hi_sticking","holding":"penalty_holding","holding_the_stick":"penalty_holding_the_stick","hooking":"penalty_hooking","illegal_stick":"penalty_illegal_stick","interference":"penalty_interference","instigator":"penalty_instigator","kneeing":"penalty_kneeing","interference_goalkeeper":"penalty_interference_on_gk","roughing":"penalty_roughing","slashing":"penalty_slashing","spearing":"penalty_spearing","tripping":"penalty_tripping","unsportsmanlike_conduct":"penalty_unsportsmanlike_conduct","delay_game_bench":"penalty_delay_of_game_bench","misconduct_10min":"penalty_misconduct","game_misconduct":"penalty_game_misconduct","goalie_participating_beyond_center":"penalty_goalie_beyond_the_center","aggressor":"penalty_aggressor","match_penalty":"penalty_match_penalty","ps_illegal_substitution":"penalty_shot_illegal_substitution","ps_goalkeeper_displaced_net":"penalty_shot_goalkeeper_displaced_net","ps_net_displaced":"penalty_shot_net_displaced","ps_covering_puck_in_crease":"penalty_shot_covering_puck","ps_picking_up_puck_in_crease":"penalty_shot_picking_up_puck","ps_throwing_object_on_ice":"penalty_shot_throwing_object","ps_interference_from_bench":"penalty_shot_interference_from_bench","ps_players_leaving_bench":"penalty_shot_players_leaving_bench","ps_throw_object_at_puck":"penalty_shot_throw_object_at_puck","ps_holding_on_breakaway":"penalty_shot_holding_on_breakaway","ps_holding_stick_on_breakaway":"penalty_shot_holding_stick_on_breakaway","ps_hooking_on_breakaway":"penalty_shot_hooking_on_breakaway","ps_tripping_on_breakaway":"penalty_shot_tripping_on_breakaway","ps_slash_on_breakaway":"penalty_shot_slash_on_breakaway","embellishment":"penalty_embellishment","minor":"penalty_minor","major":"penalty_major","bench":"penalty_bench","playing_without_a_helmet":"penalty_helmet","removing_opponents_helmet":"penalty_removing_opponents_helmet","goalie_removed_own_mask":"penalty_goalie_removed_mask","delay_game_unsucc_challenge":"penalty_delay_of_game_unsuccessful_challenge","licking":"penalty_kicking","attempt_to_injure":"penalty_attempt_to_injure","deliberate_injury":"penalty_deliberate_injury","checking_from_behind":"penalty_checking_from_behind","interference_bench":"penalty_interference_bench","throwing_stick":"penalty_throwing_stick","abusive_language":"penalty_abusive_language","fighting":"penalty_fighting","abuse_of_officials":"penalty_abuse_of_officials","refusal_to_play":"penalty_refusal_to_play","late_on_ice":"penalty_late_on_ice","not_proceeding_to_dressing_room":"penalty_not_proceeding_to_dressing_room","butt_ending":"penalty_butt_ending","head_butting":"penalty_head_butting","puck_thrown_fwd_goalkeeper":"penalty_puck_thrown_fwd_goalkeeper","removing_sweater":"penalty_removing_sweater","not_proceeding_dir_penbox":"penalty_not_proceeding_dir_penbox","leaving_penalty_box":"penalty_leaving_penalty_box","illegal_substitution":"penalty_illegal_substitution","protective_equipment":"penalty_protective_equipment","objects_on_ice":"penalty_objects_on_ice","interfere_with_official":"penalty_interfere_with_official","player_leaves_bench":"penalty_leaving_players_bench","leaving_players_penalty_bench":"penalty_leaving_penalty_bench","ineligible_player":"penalty_ineligible_player","unsustained_measurement":"penalty_unsustained_measurement","illegal_equipment":"penalty_illegal_equipment","too_many_men_on_ice":"penalty_too_many_men_on_ice","doubleMinor":"penalty_double_minor"},"Goal":"goal","goal.regular":"goal","Own goal":"ownGoal","goal.ownGoal":"ownGoal","Substitution":"substitution","Substitution in":"substitutionIn","Substitution out":"substitutionOut","substitution.injury":"substitution","substitution.temporary":"rugby_temporary_substitution","Penalty":"penalty","goal.penalty":"penalty","inGamePenalty.scored":"penalty","penaltyShootout.scored":"penalty","Missed Penalty":"missedPenalty","inGamePenalty.missed":"missedPenalty","penaltyShootout.missed":"missedPenalty","Penalty taker":"penaltyTaker","Yellow card":"yellowCard","card.yellow":"yellowCard","2nd Yellow card (Red)":"2ndYellowCard","card.yellowRed":"2ndYellowCard","Red card":"redCard","card.red":"redCard","Argument":"argument","Dangerous play":"dangerousPlay","Simulation":"simulation","Other reason":"otherReason","Unallowed field entering":"unallowedFieldEntering","Fight":"fight","Foul":"foul","Handball":"handball","Leaving field":"leavingField","On bench":"onBench","Off the ball foul":"offTheBallFoul","Persistent fouling":"persistentFouling","Professional foul":"professionalFoul","Professional handball":"professionalHandball","Professional foul last man":"professionalFoulLastMan","Rescinded Card":"rescindedCard","Unsporting behaviour":"unsportingBehaviour","Time wasting":"timeWasting","Violent conduct":"violentConduct","Post match":"postMatch","Off target":"offTarget","Woodwork":"woodwork","Goalkeeper save":"goalkeeperSave","zeroMinutes":"penalty_suspension","twoMinutes":"penalty_two_min_suspension","fourMinutes":"penalty_four_min_suspension","fiveMinutes":"penalty_five_min_suspension","tenMinutes":"penalty_ten_min_suspension","mistakenIdentity.false":"reviewed","cardUpgrade.false":"cardUpgrade.changed","cardUpgrade.true":"cardUpgrade.noChange","review.false":"reviewed","review.true":"reviewed","varDecision.goalAwarded":"varDecision","varDecision.goalNotAwarded":"varDecision","varDecision.penaltyAwarded":"varDecision","varDecision.penaltyNotAwarded":"varDecision","varDecision.redCardGiven":"varDecision","varDecision.cardUpgrade":"varDecision","varDecision.mistakenIdentity":"varDecision","goal.powerplay":"powerplayGoal","goal.shorthanded":"shorthandedGoal"}');var d=s(27892);let c="DEFAULT",u=(e,t)=>(0,d.O)(o,e,t,c),p=(e,t,s)=>{let i=u(t?"".concat(e,".").concat(t):e,s);return i!==c||t&&(i=u(t,s))!==c?i:(i=u(e,s))!==c?i:void 0},h=e=>{let{id:t}=e,s=(0,a.A)(),o=u(t,(0,l.useContext)(r.Ws));if(o!==c)return(0,i.jsx)(n.A,{id:o});let d=s.formatMessage({id:t});return d!==t?(0,i.jsx)(i.Fragment,{children:d}):null}},79853:(e,t,s)=>{s.d(t,{K:()=>o});var i=s(21377),l=s(55729),a=s(45860),n=s(62859),r=s(30720);function o(e){let t=(0,l.useContext)(n.y$),s=e||t.event,{data:o,error:d}=(0,a.Ay)(i.bnp.managers(s.id)),[c,u]=(0,r.A)(o,"homeManager","awayManager",s),[p,h]=(0,r.A)(o,"homeManagerName","awayManagerName",s);return{managers:{leftManager:c,leftManagerName:p,rightManager:u,rightManagerName:h},error:d}}},85306:(e,t,s)=>{s.d(t,{K:()=>i});var i=function(e){return e.Position="position",e.Rating="rating",e.Notes="notes",e.ExpectedGoals="expectedGoals",e}({})},90715:(e,t,s)=>{s.d(t,{V:()=>i});function i(e,t){if(11!==t.length)throw Error("getFormationMatrix(): Insufficient players to form formation ".concat(e,"."));let s=[],i=["1",...e.split("-")].map(Number),l=[...t];return i.forEach(e=>{s.push(l.splice(0,e))}),s}},94493:(e,t,s)=>{s.d(t,{w:()=>o});var i=s(6029),l=s(90248),a=s(62859),n=s(50677),r=s(27892);let o=e=>{let{id:t,children:s}=e;return(0,i.jsx)(a.Ws.Consumer,{children:e=>{let a=(0,r.O)(n,t,e);return(0,i.jsx)(l.A,{id:a,children:e=>a===String(e)?null:"function"==typeof s?s(e):(0,i.jsx)(i.Fragment,{children:e})})}})}},99326:(e,t,s)=>{s.d(t,{sP:()=>x,h$:()=>u,ZB:()=>o,H_:()=>m,lV:()=>g,kr:()=>c,kx:()=>h});var i=s(4967),l=s(55529);function a(e){let t={sum:0,count:0};return e.forEach(e=>{e.forEach(e=>{e.player.height&&(t.sum+=e.player.height,t.count+=1)})}),t.count>=7?Math.round(10*t.sum/t.count)/10:void 0}function n(e,t){let s={sum:0,count:0};return e.forEach(e=>{e.forEach(e=>{e.player.dateOfBirthTimestamp&&(s.sum+=(0,i.Dr)(e.player.dateOfBirthTimestamp,t),s.count+=1)})}),s.count>=7?Math.round(10*s.sum/s.count)/10:void 0}function r(e){let t={sum:0,count:0,currency:""};return e.forEach(e=>{e.forEach(e=>{var s;(null==(s=e.player.proposedMarketValueRaw)?void 0:s.value)&&(t.sum+=e.player.proposedMarketValueRaw.value,t.currency=e.player.proposedMarketValueRaw.currency,t.count+=1)})}),t.count>=7?{value:t.sum,currency:t.currency}:void 0}function o(e,t,s){let i={};return i[l.kA.Age]={messageId:"football_lineups_starters_average_age",leftTeamValue:n(e,s),rightTeamValue:n(t,s)},i[l.kA.MarketValue]={messageId:"football_lineups_starters_total_market_value",leftTeamValue:r(e),rightTeamValue:r(t)},i[l.kA.Height]={messageId:"football_lineups_starters_average_height",leftTeamValue:a(e),rightTeamValue:a(t)},i}var d=s(10387);function c(e){let t=null==e?void 0:e.left.players.filter(e=>e.substitute),s=null==e?void 0:e.right.players.filter(e=>e.substitute);return!!(t&&t.length>0||s&&s.length>0)}let u=e=>{let{id:t,incidents:s,useShortName:i,type:l="player"}=e;return s.filter(e=>{var s,i,a,n;return(null==(s=e[l])?void 0:s.id)===t||(null==(i=e.playerOut)?void 0:i.id)===t||(null==(a=e.playerIn)?void 0:a.id)===t||(null==(n=e.assist1)?void 0:n.id)===t}).reduce((e,s)=>{var l,a,n,r,o,d,c;switch(s.incidentType){case"card":switch(s.incidentClass){case"red":return{...e,hasRedCard:!0};case"yellow":return{...e,hasYellowCard:!0};case"yellowRed":return{...e,hasYellowRedCard:!0};default:return e}case"goal":if((null==(l=s.player)?void 0:l.id)===t)switch(s.incidentClass){case"ownGoal":return{...e,hasScoredOwnGoal:!0,ownGoalsScored:(e.ownGoalsScored||0)+1};case"penalty":return{...e,hasScoredPenalty:!0,penaltiesScored:(e.penaltiesScored||0)+1,goalsScored:(e.goalsScored||0)+1};default:return{...e,goalsScored:(e.goalsScored||0)+1}}if((null==(a=s.assist1)?void 0:a.id)===t)return{...e,goalsAssisted:(e.goalsAssisted||0)+1};return e;case"substitution":if((null==(n=s.playerOut)?void 0:n.id)===t)return{...e,substitutionOut:{forPlayer:(i?null==(r=s.playerIn)?void 0:r.shortName:null==(o=s.playerIn)?void 0:o.name)||s.playerNameIn,time:s.time,isInjury:"injury"===s.incidentClass}};return{...e,substitutionIn:{forPlayer:(i?null==(d=s.playerOut)?void 0:d.shortName:null==(c=s.playerOut)?void 0:c.name)||s.playerNameOut,time:s.time,isInjury:"injury"===s.incidentClass}};default:return e}},{})},p=(e,t)=>e.split(" ").map(e=>{let s=e;return e.length!==t||e.includes("-")||(s=e.slice(0,e.length/2)+"\xad"+e.slice(e.length/2)),s}).join(" ");function h(e,t){var s;return t||e.player.name.length>24||(null==(s=e.player.country)?void 0:s.alpha2)==="MG"}function x(e,t,s){let i=Math.max(...e.split(" ").map(e=>e.length));return i>=12&&(e=p(e,i)),t?s?"".concat(e," (c)"):"(c) ".concat(e):e}function g(e,t){if(t===l.V7.Confirmed){var s;return(null==(s=e.statistics)?void 0:s.rating)||e.avgRating}if(t===l.V7.Possible)return e.avgRating}function m(e,t,s){var i,l;let a=t?u({id:e.player.id,incidents:t,useShortName:!0}):{},n=a.hasYellowCard||a.hasYellowRedCard||a.hasRedCard,r={name:"card",icon:a.hasYellowRedCard?"card-double-yellow":"card",color:a.hasYellowRedCard?void 0:a.hasRedCard?"error.default":"scoreRating.s65",isVisible:!!n},o={name:"substitution",icon:(null==(i=a.substitutionOut)?void 0:i.isInjury)?"substitution-injured":"substitution",isVisible:!!a.substitutionOut},c={name:"goals",icon:a.goalsScored===a.penaltiesScored&&a.hasScoredPenalty?"football-penalty":"football-ball",count:a.goalsScored,color:"secondary.default",isVisible:!!a.goalsScored},p={name:"goalAssist",icon:"football-assist",count:a.goalsAssisted,color:"neutral.variant",isVisible:!!a.goalsAssisted},h={name:"ownGoals",icon:"football-own-goal",count:a.ownGoalsScored,color:"error.default",isVisible:!!a.ownGoalsScored};return{playerLeftStatistics:[r,o,{name:"matchMVP",color:(0,d.E)(null==(l=e.statistics)?void 0:l.rating),isVisible:!!s}],playerRightStatistics:[c,p,h]}}s(44259)},99382:(e,t,s)=>{s.d(t,{jP:()=>p,Xl:()=>h});var i=s(6029),l=s(21377),a=s(947),n=s(90248),r=s(79387),o=s(19451),d=s(26331),c=s(73088),u=s(30479);let p=e=>{let{event:t}=e,s=(0,a.A)(),p=(0,d.A)();return(0,i.jsx)(r.C,{callToAction:(0,i.jsx)(n.A,{id:"chart_embed"}),embedString:function(e,t,s){let{id:i,customId:a,homeTeam:n,awayTeam:r,slug:d,tournament:p}=e,h=p.category.sport.slug,x=(0,o.vf)(t.locale),g="".concat(l.yuv).concat(x?"/".concat(x):"","/embed/attackMomentum?id=").concat(i,"&widgetTheme=light"),m=(0,l.Lo9)(c.z.getTranslatedRoute(s,"event",{id:a,name:d,sport:h},(0,u.HL)({id:i})).route,{isApiRoute:!1}),f="".concat(n.name," - ").concat(r.name),y=t.formatMessage({id:"event.embed.lineupsBackLink"},{eventName:f,a:e=>'\n ').concat(e,"\n ")});return'\n
').concat(y,"
")}(t,s,p),px:0,mt:0})},h=e=>{let{event:t}=e,s=(0,a.A)(),p=(0,d.A)(),{id:h,customId:x,homeTeam:g,awayTeam:m,slug:f,tournament:y}=t,j=y.category.sport.slug,v=(0,o.vf)(s.locale),b="".concat(l.yuv).concat(v?"/".concat(v):"","/embed/lineups?id=").concat(h,"&widgetTheme=light"),_="sofa-lineups-embed-".concat(h),w=(0,l.Lo9)(c.z.getTranslatedRoute(p,"event",{id:x,name:f,sport:j},(0,u.HL)({id:h})).route,{isApiRoute:!1}),k="".concat(g.name," - ").concat(m.name),C=s.formatMessage({id:"event.embed.lineupsBackLink"},{eventName:k,a:e=>'\n ').concat(e,"\n ")}),S='\n
').concat(C,"
");return(0,i.jsx)(r.C,{callToAction:(0,i.jsx)(n.A,{id:"chart_embed"}),embedString:S,px:0,mt:0})}},99586:(e,t,s)=>{s.d(t,{C:()=>o});var i=s(99452),l=s.n(i),a=s(5326),n=s(85306),r=s(48886);function o(e,t,s,i){let o=t.stat,d=t.dir,c=[],u=[];if(o.value===n.K.Position&&(c.push(e=>a.EN[i].indexOf(e.position)),u.push(t.dir)),o.percentageOnly&&(c.push(e=>{let t=e.statistics&&o.madesValue?e.statistics[o.madesValue]:0,s=e.statistics&&o.attemptsValue?e.statistics[o.attemptsValue]:0;return t&&s?t/s:0}),u.push(t.dir)),o.madesValue){let e=o.madesValue;if(c.push(t=>{var s,i;return null!=(i=null==(s=t.statistics)?void 0:s[e])?i:0}),u.push(d),o.attemptsValue&&o.reverseSecondCompare){let e=o.attemptsValue;c.push(t=>{var s,i;return null!=(i=null==(s=t.statistics)?void 0:s[e])?i:0}),u.push(d===r.U.ASC?r.U.DESC:r.U.ASC)}}let p=o.compareValue;return p&&(c.push(e=>{var t,s;return null!=(s=null==(t=e.statistics)?void 0:t[p])?s:0}),u.push(d)),c.push(e=>{var t,s;return null!=(s=null==(t=e.statistics)?void 0:t[o.value])?s:0}),u.push(d),c.push(e=>{var t,i;return null!=(i=null==(t=e.statistics)?void 0:t[s.value])?i:0}),u.push(r.U.DESC),c.push(e=>{var t;return null!=(t=e.player.shortName)?t:""}),u.push(r.U.ASC),l()(e,c,u)}}}]);