!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},s=(new e.Error).stack;s&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[s]="1f489494-2579-4052-a844-949513a3d1f6",e._sentryDebugIdIdentifier="sentry-dbid-1f489494-2579-4052-a844-949513a3d1f6")}catch(e){}}();"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3231],{7079:(e,s,t)=>{t.d(s,{X:()=>T});var l=t(6029),n=t(21377),i=t(95083),r=t(55729),o=t(947),a=t(41735),d=t(76356),c=t(93338),u=t(41249),m=t(90248),x=t(494),p=t(45860),h=t(54409),j=t(70591),g=t(10794),v=t(94604),y=t(19135),f=t(19168),b=t(50574),w=t(13892),k=t(82287),I=t(91816),C=t(67149);let S=e=>{var s;let{row:t,events:o,sport:a,position:m,columnKeys:y,promotionColors:S,isRTL:L}=e,{isNarrowLayout:T,selectedTeamId:D,homeTeamId:E,awayTeamId:z,displayType:_}=(0,r.useContext)(I.P),{isDesktopLarge:P}=(0,i.$c)(),A=(0,x.d4)(g.JV),N=t.team.id,Y=!!t.liveMatchWinnerCodeColumn,{texts:R}=(0,r.useContext)(k.C),{data:F}=(0,p.Ay)(t.promotion?n.oo$.singleEntity(t.promotion.id,A):null),B=(null==F?void 0:F.translation.value)||(null==(s=t.promotion)?void 0:s.text)||R[N],[M,O]=(0,r.useState)(!1);return(0,l.jsx)(j.gT,{sport:a,team:t.team,"data-testid":"standings_row",children:(0,l.jsxs)(w.fh,{"data-selected":D===N||void 0,team:E===N?"home":z===N?"away":"none",children:[D===N&&(0,l.jsx)(d.az,{position:"absolute",left:"[0px]",w:"xs",h:"100%",bg:"neutral.default"}),(0,l.jsx)(d.az,{children:(0,l.jsx)(d.so,{w:"xl",h:"xl",justify:"center",align:"center",br:"50%",textStyle:"display.small",cursor:"pointer",userSelect:"none",onClick:e=>{e.preventDefault(),e.stopPropagation(),B&&(M||(O(!0),setTimeout(()=>{O(!1)},3e3),(0,f.MZ)((0,l.jsxs)(d.so,{align:"center",children:[(0,l.jsx)(h.G_L,{fill:"surface.s1",mr:"lg"}),(0,l.jsxs)(i.EY,{textStyle:"display.small",color:"surface.s1",display:"block",children:[(0,l.jsx)(v.Rm,{team:t.team,short:!0})," – ".concat(B)]})]}))))},color:S[N]?"surface.s1":"neutrals.nLv1",style:{backgroundColor:S[N]?S[N]:c.S.var("colors.surface.s2")},title:B||void 0,children:m})}),"full"===_&&(!P||T)?null:(0,l.jsx)(u._V,{src:n.cWY.image(t.team.id),width:"32",height:"32",style:{verticalAlign:"top"},w:[32,24],h:[32,24],ml:"sm",fallback:(0,l.jsx)(d.I4.img,{style:{marginLeft:u.xI.sm},src:"/static/images/placeholders/team.svg",width:{base:"2xl",md:"xl"},height:{base:"2xl",md:"xl"},className:"standings-row-placeholder-image",alt:""}),alt:""}),(0,l.jsx)(d.az,{flexGrow:1,overflow:"auto",children:(0,l.jsxs)(d.so,{align:"center",pl:"sm",overflow:"hidden",w:"100%",children:[(0,l.jsx)(i.EY,{textStyle:"table.medium",color:Y?"status.live":"neutrals.nLv1",display:"block",truncate:!0,children:(0,l.jsx)(v.Rm,{team:t.team,short:!0})}),Y&&(0,l.jsx)(d.I4.small,{position:"relative",color:"status.live",_after:{content:"''",position:"relative",display:"inline-block",top:"[-1px]",width:"[6px]",height:"[6px]",ml:"xs",br:"50%",bg:"status.live",animation:"pulse 1s ease-in infinite"}})]})}),y.map(e=>{if("last5"===e)return(0,l.jsx)(b.o1,{events:o,referenceId:t.team.id},t.team.id+e);let s=C.oG(e,a,t,L),n=!1;e===t.liveMatchWinnerCodeColumn||"points"===e&&Y?n=!0:"percentage"===e&&Y&&(n=!0);let r=C.j8(e,a,!1);return(0,l.jsx)(d.az,{children:(0,l.jsx)(i.Ym,{textStyle:"table.medium",color:n?"status.live":"neutrals.nLv1",children:(0,l.jsx)(d.so,{justify:"center",style:{minWidth:r},children:s})})},e)})]})})};function L(e){let{sport:s,columnKeys:t,selectedSeason:n}=e,r=null==n?void 0:n.year;return(0,l.jsxs)(w.fh,{children:[(0,l.jsx)(d.az,{children:(0,l.jsx)(i.EY,{textStyle:"table.medium",color:"neutrals.nLv3",textAlign:"center",display:"block",w:"xl",children:"#"})}),(0,l.jsx)(d.az,{flexGrow:1,children:(0,l.jsx)(i.EY,{textStyle:"table.medium",color:"neutrals.nLv3",display:"block",pl:"sm",children:(0,l.jsx)(m.A,{id:"team"})})}),t.map(e=>{if("last5"===e)return(0,l.jsx)(d.so,{ml:"sm",wrap:"nowrap",flexBasis:"[120px]",justify:"center",align:"center",children:(0,l.jsx)(d.so,{minW:"2xl",justify:"center",children:(0,l.jsx)(i.EY,{textStyle:"table.medium",color:"neutrals.nLv3",children:(0,l.jsx)(y.N,{id:e})})})},"column-key-last5");let t=function(e,s){switch(e){case"pointsCurrSeason":return s;case"pointsPrevSeason":return Number(s)-1;case"pointsPrevPrevSeason":return Number(s)-2;default:return(0,l.jsx)(y.N,{id:e})}}(e,r),n=C.j8(e,s,!1);return(0,l.jsx)(d.az,{children:(0,l.jsx)(i.EY,{textStyle:"table.medium",color:"neutrals.nLv3",textTransform:"points"===e?"uppercase":void 0,children:(0,l.jsx)(d.so,{justify:"center",style:{minWidth:n},children:t})})},e)})]})}function T(e){let{type:s,table:t,teamEvents:d}=e,c=(0,r.useContext)(I.P),{uniqueTournamentId:u,isNarrowLayout:m,displayType:x,homeTeamId:p,awayTeamId:h,selectedTeamId:j,selectedSeason:g}=c,{isDesktop:v,mediaBreakpoint:y}=(0,i.$c)(),{settings:f}=(0,a.useTheme)(),b=(0,o.A)(),w=t.tournament.category.sport.slug,T=(0,r.useMemo)(()=>{let e=t.rows.reduce((e,s)=>Object.keys(s).length>Object.keys(e).length?s:e,t.rows[0]),l=t.rows.some(e=>0!==Number(e.gamesBehind)),n=t.rows.some(e=>void 0!==e.scoresFor||void 0!==e.scoresAgainst),i=!!(null==g?void 0:g.year)&&t.rows.some(e=>void 0!==e.pointsCurrSeason||void 0!==e.pointsPrevPrevSeason||void 0!==e.pointsPrevPrevSeason);if(e._isPlaceholderRow)return[b.formatMessage({id:"standings_placeholder_data"},{type:s,name:t.name})];let r="xxs"===y||"xs"===y||v&&m;return(0,C.Tx)(e,w,x,m,l,n,i,r,u)},[t.id,w,x,m]),{colors:D}=(0,r.useContext)(k.C),E=(0,r.useMemo)(()=>{let e={homeTeamId:p,awayTeamId:h,selectedTeamId:j};return s===n.lpv.Home&&(delete e.awayTeamId,delete e.homeTeamId,e.selectedTeamId=j),s===n.lpv.Away&&(delete e.awayTeamId,delete e.homeTeamId,e.selectedTeamId=j),e},[p,h,j,s]);return(0,l.jsxs)("div",{style:{width:"100%"},children:[(0,l.jsx)(L,{columnKeys:T,sport:w,selectedSeason:g}),(0,l.jsx)(I.P.Provider,{value:{...c,...E},children:t.rows.map((e,s)=>(0,l.jsx)(S,{columnKeys:T,promotionColors:D,position:s+1,row:e,sport:w,events:d?d[e.team.id]:null,isRTL:"rtl"===f.textDirection},e.id))})]})}},11033:(e,s,t)=>{t.d(s,{K:()=>S,c:()=>L});var l=t(6029),n=t(21377),i=t(95083),r=t(76356),o=t(41249),a=t(55729),d=t(90248),c=t(494),u=t(45860),m=t(54409),x=t(40548),p=t(10794),h=t(94604),j=t(84942),g=t(13892),v=t(82287);function y(e){let{description:s,transValue:t}=e;return(0,l.jsxs)(g.VY,{children:[s.teamName?(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(h.lC,{original:s.teamName}),":\xa0"]}):null,t||s.text]})}function f(e){let{description:s,locale:t}=e,{data:i}=(0,u.Ay)(n.oo$.singleEntity(s.id,t));return(0,l.jsx)(y,{description:s,transValue:null==i?void 0:i.translation.value})}function b(e){let{promotion:s,locale:t}=e,{data:r}=(0,u.Ay)(n.oo$.singleEntity(s.id,t));return(0,l.jsx)(i.EY,{display:"block",textStyle:"assistive.default",color:"neutrals.nLv3",lineHeight:1,children:(null==r?void 0:r.translation.value)||s.text})}function w(e){let{descriptions:s,locale:t}=e;return s&&s.length&&t?"en"===t?(0,l.jsx)(l.Fragment,{children:s.map(e=>(0,l.jsx)(y,{description:e},e.id))}):(0,l.jsx)(l.Fragment,{children:s.map(e=>(0,l.jsx)(f,{description:e,locale:t},e.id))}):null}let k=(e,s)=>{let{colors:t}=(0,a.useContext)(v.C),[l,n,i]=(0,a.useMemo)(()=>{let l=[],n=[],i={};return e.rows.forEach(e=>{var r;e.descriptions&&l.push(...e.descriptions.map(t=>({...t,teamName:(0,j.s)(e.team,s)}))),(null==(r=e.promotion)?void 0:r.text)&&!i[e.promotion.id]&&(n.push(e.promotion),i[e.promotion.id]=t[e.team.id])}),[l,n,i]},[e.rows]);return{rowDescriptions:l,rowPromotions:n,promotionColors:i,tieBreakingRules:e.tieBreakingRule?[e.tieBreakingRule]:[]}},I=e=>{let{children:s,defaultOpenedFirstRules:t}=e;return(0,l.jsx)(o.nD,{children:(0,l.jsxs)(o.nD.Item,{bg:"surface.s2",br:"sm",defaultOpened:t,children:[(0,l.jsx)(o.nD.Trigger,{bg:"transparent",children:(0,l.jsx)(i.EY,{textStyle:"display.small",children:(0,l.jsx)(d.A,{id:"rules"})})}),(0,l.jsx)(o.nD.Content,{children:(0,l.jsx)(i.EY,{textStyle:"body.small",display:"block",px:"md",pb:"md",children:s})})]})})},C=e=>{let{locale:s,descriptions:t,rowDescriptions:n,rowPromotions:i,tieBreakingRules:o,promotionColors:a,defaultOpenedFirstRules:d}=e;return(0,l.jsx)(r.az,{px:"sm",pb:"md",children:(0,l.jsx)(I,{defaultOpenedFirstRules:d,children:(0,l.jsxs)(r.so,{direction:"column",gap:"sm",children:[(0,l.jsx)("div",{children:i.map(e=>(0,l.jsxs)(r.so,{align:"center",h:"xl",children:[(0,l.jsx)(r.so,{justify:"center",align:"center",w:"xl",children:(0,l.jsx)(r.az,{h:"sm",w:"sm",br:"50%",style:{background:a[e.id]}})}),(0,l.jsx)(b,{promotion:e,locale:s})]},e.id))}),(0,l.jsx)(w,{descriptions:n,locale:s}),(0,l.jsx)(w,{descriptions:t,locale:s}),(0,l.jsx)(w,{descriptions:o,locale:s})]})})})};function S(e){var s;let t=(0,c.d4)(p.JV),{isMobile:n}=(0,i.$c)(),{rowDescriptions:o,rowPromotions:a,tieBreakingRules:u,promotionColors:h}=k(e,t),j=!!(o.length||(null==(s=e.descriptions)?void 0:s.length)||u.length);return j||a.length?n?(0,l.jsx)(r.az,{pt:"md",children:(0,l.jsx)(C,{locale:t,descriptions:e.descriptions,rowDescriptions:o,rowPromotions:a,tieBreakingRules:u,promotionColors:h,defaultOpenedFirstRules:e.defaultOpenedFirstRules})}):(0,l.jsx)(r.az,{p:"sm",borderTop:[e.noDivider?void 0:"neutrals.nLv4",void 0],children:(0,l.jsxs)(r.so,{br:"sm",py:"sm",px:{mdDown:"sm",md:"lg"},pt:{md:"sm"},direction:"column",children:[a.length>0&&(0,l.jsxs)(r.so,{align:"center",mb:"md",children:[(0,l.jsx)(m.G_L,{w:"24",h:"24",fill:"onSurface.nLv3",mr:"lg"}),(0,l.jsx)(r.az,{children:(0,l.jsx)(i.EY,{lineHeight:"32px",textStyle:"assistive.default",color:"neutrals.nLv3",children:(0,l.jsx)(d.A,{id:"standings.promotionInfo",values:{isMobile:n}})})})]}),j&&(0,l.jsxs)(x.N,{children:[(0,l.jsx)(w,{descriptions:o,locale:t}),(0,l.jsx)(w,{descriptions:e.descriptions,locale:t}),(0,l.jsx)(w,{descriptions:u,locale:t})]})]})}):null}function L(e){var s;let t=(0,c.d4)(p.JV),{isMobile:n}=(0,i.$c)(),{rowDescriptions:o,rowPromotions:a,tieBreakingRules:d,promotionColors:u}=k(e,t),m=!!(o.length||(null==(s=e.descriptions)?void 0:s.length)||d.length);return m&&0!==a.length?n?(0,l.jsx)(r.az,{pt:"md",children:(0,l.jsx)(C,{locale:t,descriptions:e.descriptions,rowDescriptions:o,rowPromotions:a,tieBreakingRules:d,promotionColors:u})}):(0,l.jsxs)(r.az,{px:"sm",children:[(0,l.jsx)(r.az,{pt:"sm",pb:{mdDown:"sm"},mb:{mdDown:"sm"},children:a.map(e=>(0,l.jsxs)(r.so,{align:"center",h:"2xl",gap:"sm",children:[(0,l.jsx)(r.so,{justify:"center",align:"center",h:"xl",w:"xl",children:(0,l.jsx)(r.az,{h:"sm",w:"sm",br:"50%",style:{background:u[e.id]}})}),(0,l.jsx)(b,{promotion:e,locale:t})]},e.id))}),(0,l.jsx)(r.so,{br:"sm",py:"sm",px:["sm","lg"],pt:{base:"sm",mdDown:void 0},direction:"column",children:m&&(0,l.jsxs)(x.N,{pb:"xs",children:[(0,l.jsx)(w,{descriptions:o,locale:t}),(0,l.jsx)(w,{descriptions:e.descriptions,locale:t}),(0,l.jsx)(w,{descriptions:d,locale:t})]})})]}):(0,l.jsx)(r.az,{h:"sm"})}},13892:(e,s,t)=>{t.d(s,{FF:()=>a,VY:()=>o,fh:()=>r});var l=t(62042),n=t(76356);let i=(0,l.Fj)({base:{display:"flex",alignItems:"center",position:"relative",textStyle:"table.medium",padding:"sm",height:{base:"4xl",md:"2xl"},_selected:{backgroundColor:"neutral.highlight"},_hover:{backgroundColor:"surface.s2"}},variants:{team:{none:{},home:{backgroundColor:"secondary.highlight",borderLeft:"xs solid {colors.secondary.default}",paddingLeft:"xs"},away:{backgroundColor:"primary.highlight",borderLeft:"xs solid {colors.primary.default}",paddingLeft:"xs"}}}}),r=(0,n.I4)("div",i),o=(0,n.I4)("p",{base:{margin:"0",padding:"0","& + &":{marginTop:"xs"}}}),a=(0,n.I4)("div",{base:{"& button":{border:"1px solid {colors.surface.s2}",paddingLeft:"xs",paddingRight:"xs","& svg":{margin:"0"},"& svg:nth-child(2)":{display:"none"}}}})},40548:(e,s,t)=>{t.d(s,{N:()=>d});var l=t(6029),n=t(95083),i=t(41249),r=t(55729),o=t(90248),a=t(54409);function d(e){let{children:s,closedHeight:t=64,...d}=e,[c,u]=(0,r.useState)(!1),[m,x]=(0,r.useState)(0),p=(0,r.useCallback)(()=>u(e=>!e),[]),{mediaBreakpoint:h}=(0,n.$c)(),j=(0,r.useRef)(null);(0,r.useEffect)(()=>{var e;x((null==j||null==(e=j.current)?void 0:e.scrollHeight)||0)},[j,s,h]);let g=m>t;return(0,l.jsxs)(i.az,{...d,children:[(0,l.jsx)(i.EY,{font:"body.small",color:"onSurface.nLv1",lineClamp:!c&&g?4:void 0,ref:j,as:"div",children:s}),g&&(0,l.jsx)(i.az,{cursor:"pointer",onClick:p,mt:"sm",children:(0,l.jsxs)(i.EY,{font:["assistive.default","display.small"],color:"primary.default",align:"right",hover:!0,as:"div",children:[(0,l.jsx)(o.A,{id:c?"show_less":"show_more"}),c?(0,l.jsx)(a.t8v,{ml:"xs",fill:"primary.default"}):(0,l.jsx)(a.QtO,{ml:"xs",fill:"primary.default"})]})})]})}},65457:(e,s,t)=>{t.d(s,{A:()=>u,u:()=>m});var l=t(6029),n=t(21377),i=t(95083),r=t(76356),o=t(41249),a=t(90248),d=t(54409),c=t(13892);function u(e){return e.isNarrowLayout?(0,l.jsx)(c.FF,{children:(0,l.jsx)(o.ms,{items:e.items||[...n.ur4],selectedItem:e.displayType,onSelectedItemChange:s=>{let{selectedItem:t}=s;t&&e.setDisplayType(t)},renderItem:(e,s)=>s?(0,l.jsx)(d.NwX,{fill:"onSurface.nLv1"}):(0,l.jsx)(a.A,{id:"standings."+e}),menuLabel:(0,l.jsx)(a.A,{id:"standings.appearance"}),alignRight:!0,buttonStyle:{width:36,height:36,zIndex:o.Py.Backdrop}})}):null}function m(e){let{displayType:s,setDisplayType:t,items:n,isNarrowLayout:o}=e;return(0,l.jsxs)(r.so,{justify:"space-between",p:"sm",borderBottom:"neutrals.nLv4",children:[(0,l.jsxs)(r.az,{children:[(0,l.jsx)(i.EY,{display:"block",textStyle:"assistive.default",color:"neutrals.nLv1",pt:"2xs",children:(0,l.jsx)(a.A,{id:"standings.appearance"})}),(0,l.jsx)(i.EY,{display:"block",textStyle:"body.small",color:"neutrals.nLv3",children:(0,l.jsx)(a.A,{id:"standings.appearance.select"})})]}),(0,l.jsx)(u,{displayType:s,setDisplayType:t,items:n,isNarrowLayout:o})]})}},82287:(e,s,t)=>{t.d(s,{C:()=>r,R:()=>o});var l=t(6029),n=t(55729),i=t(67149);let r=(0,n.createContext)({colors:{},texts:{}}),o=e=>{let{standings:s,children:t}=e,[o,a]=(0,n.useMemo)(()=>{let e=s.rows.map(e=>({...e.promotion,teamId:e.team.id})).filter(e=>!!e.id);return[(0,i.oB)(e),e.reduce((e,s)=>(e[s.teamId]=s.text,e),{})]},[null==s?void 0:s.id]);return(0,l.jsx)(r.Provider,{value:{colors:o,texts:a},children:t})}},91816:(e,s,t)=>{t.d(s,{P:()=>i});var l=t(78383),n=t.n(l);let i=(0,t(55729).createContext)({isNarrowLayout:!0,uniqueTournamentId:void 0,seasonId:void 0,displayTypeOptions:void 0,displayType:"short",setDisplayType:n(),standings:[],homeTeamId:void 0,awayTeamId:void 0,selectedTeamId:void 0,hasPerformanceGraphFeature:!1,hasHomeAwayStandings:!1,tournamentId:void 0,selectedSeason:void 0})}}]);