(self.webpackChunk=self.webpackChunk||[]).push([[6884],{36884:(e,t,a)=>{"use strict";a.r(t),a.d(t,{FeaturedGames:()=>O,default:()=>P});var o=a(12139),n=a(58059),r=a(82762),i=a(58061),d=a(16575),l=a(85782),s=a(56747),c=a(35104),u=a(91193),m=a(96e3),p=a(46062),g=a.n(p),f=a(44036),h=a.n(f),x=a(96793),v=a.n(x),b=a(17892),_=a.n(b),y=a(11173),E=a.n(y),w=a(42464),k=a.n(w),I=a(61),N=a.n(I),T={};T.styleTagTransform=k(),T.setAttributes=_(),T.insert=v().bind(null,"head"),T.domAPI=h(),T.insertStyleElement=E(),g()(N(),T),N()&&N().locals&&N().locals;var A=a(56753);const C="featured-odds-button",D=(0,l.dG)(C),M=({outcome:e,value:t,onClick:a,selected:o,suspended:n=!1})=>(0,A.BX)("button",{className:(0,l.O5)(C,{selected:o}),onClick:a,children:[!n&&(0,A.BX)(A.HY,{children:[(0,A.tZ)("span",{className:D("outcome"),children:e}),(0,A.tZ)("span",{className:D("value"),children:t})]}),n&&(0,A.BX)("div",{className:D("susp-label"),children:[(0,A.tZ)(d.le,{className:D("lock"),name:"lock"}),(0,A.tZ)(d.vN,{tkey:"SPORT.SUSP"})]})]});var Z=a(44955),S=a(36368),G=a.n(S),$={};$.styleTagTransform=k(),$.setAttributes=_(),$.insert=v().bind(null,"head"),$.domAPI=h(),$.insertStyleElement=E(),g()(G(),$),G()&&G().locals&&G().locals;const R="featured-game-card",F=(0,l.dG)(R),U=({game:e})=>{const{selections:t}=(0,i.TK)(),a=(0,s.k6)(),n=(0,i.qM)(),{layout:p}=(0,i.$Y)(),{user:g}=(0,i.aF)(),f=(0,o.Ye)((()=>t.map((e=>`${e.eventId}_${e.id}`))),[t]),h=(0,l.Q5)({month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",weekday:"short",hourCycle:"h23"},m.b$.current),x=(0,o.Ye)((()=>e.markets[0].outcomes.slice(0,3)),[e]),v=(0,o.Ye)((()=>{var t,a,o;return null==(t=p.sportRibbon)||null==(a=t.allSports)||null==(o=a.find((t=>t.providerId===e.sportId)))?void 0:o.mediaItemId}),[e,p]),b=(0,o.I4)((t=>f.includes(`${e.id}_${t}`)),[f]);return(0,A.BX)("div",{className:R,onClick:()=>{var t,o,n;(0,l.PH)({event:r.GTMCustomEvents.FEATURED_GAMES_MODULE_REDIRECT_CLICK_EVENT,eventID:r.GTMCustomEventsIds.FEATURED_GAMES_MODULE_REDIRECT_CLICK_EVENT,country:(null==g||null==(t=g.account)?void 0:t.country)||c.NZ.defaults.countryCode,customerID:null!=g&&null!=(o=g.account)&&o.id?Number(null==g||null==(n=g.account)?void 0:n.id):null,platform:u.J}),(0,l.oK)(a,e,!1)},children:[(0,A.BX)("span",{className:F("date"),children:[(E=e.startTime,h(new Date(E),(e=>function(e){const t=new Date(e),a=new Date;return t.getDate()===a.getDate()&&t.getMonth()===a.getMonth()&&t.getFullYear()===a.getFullYear()}(E)?`${n("_TODAY")} ${e.hour}:${e.minute}`:`${e.weekday} ${e.day}/${e.month}. ${e.hour}:${e.minute}`)))," ",(0,A.tZ)(d.e0,{direction:"right"})]}),(0,A.BX)("div",{className:F("country-league-name"),children:[(0,A.tZ)(d.ZX,{iconId:v})," ",(0,A.tZ)("span",{children:(_=e.categoryName,y=e.competitionName,_&&y?`${_} | ${y}`:_&&!y?_:y)})]}),(0,A.BX)("div",{className:F("team-names"),children:[(0,A.tZ)("span",{className:F("team"),children:e.eventNames[0]}),(0,A.tZ)("span",{className:F("team"),children:e.eventNames[1]})]}),(0,A.BX)("div",{className:F("odds"),children:[0===x.length&&(0,A.tZ)("span",{className:F("no-outcome"),children:(0,A.tZ)(d.vN,{tkey:"FEATURED_GAMES.NO_MARKET_AVAILABLE"})}),x.length>0&&x.map((t=>{const a="v2"===c.NZ.apiVersion?t.entityId:t.id,o=b(a);return(0,A.tZ)(M,{outcome:(null==t?void 0:t.displayName)||t.name,value:t.value||"-",suspended:!t.active,selected:o,onClick:a=>{if(a.stopPropagation(),t.active){const a={type:r.BetType.PRE_MATCH,event:e,market:e.markets[0],outcome:t,categoryId:e.categoryId,competitionId:e.competitionId,sportId:e.sportId};var o,n,i,d;(0,Z.Ul)(a),(0,Z.yF)(a)&&(0,l.PH)({event:r.GTMCustomEvents.FEATURED_GAMES_MODULE_CLICK_EVENT,eventID:r.GTMCustomEventsIds.FEATURED_GAMES_MODULE_CLICK_EVENT,sportEventId:e.id,country:(null==g||null==(o=g.account)?void 0:o.country)||c.NZ.defaults.countryCode,platform:u.J,marketID:null==(n=e.markets[0])?void 0:n.id,selectionID:t.id,customerID:null!=g&&null!=(i=g.account)&&i.id?Number(null==g||null==(d=g.account)?void 0:d.id):null})}}})}))]})]});var _,y,E};var B=a(34495),L=a.n(B),X={};X.styleTagTransform=k(),X.setAttributes=_(),X.insert=v().bind(null,"head"),X.domAPI=h(),X.insertStyleElement=E(),g()(L(),X),L()&&L().locals&&L().locals;const z="featured-games",j=(0,l.dG)(z);function O({pageId:e}){const[t,a]=(0,o.eJ)([]),[l,s,c]=(0,i.CU)(!0,r.LoaderMode.Skeleton),u=(0,i.qM)();return(0,o.d4)((()=>{const t=n.jV.getFeaturedEvents(e,{mode:c.current,connector:s}).subscribe({next:e=>a(e.data)});return()=>t.unsubscribe()}),[]),(0,A.tZ)(d.Od,{visible:l,type:r.SkeletonType.FeaturedGames,fixedHeight:185,children:(0,A.BX)("div",{className:z,children:[(0,A.BX)("div",{className:j("header"),children:[(0,A.tZ)(d.ZX,{iconId:"Star_Icon"}),u("FEATURED_GAMES.TITLE")]}),(null==t?void 0:t.length)>0?(0,A.tZ)(d.rf,{children:t.map((e=>(0,A.tZ)(U,{game:e},e.id)))}):(0,A.tZ)(d.$J,{messageKey:"FEATURED_GAMES.NO_GAMES"})]})})}const P=O},36368:e=>{e.exports=[[e.id,".featured-game-card{display:flex;flex-direction:column;width:217px;height:148px;background:var(--color-white);box-shadow:0 0 5px var(--color-featured-games-box-shadow);border-radius:5px;padding:11px 10px;cursor:pointer}.featured-game-card__date,.featured-game-card__country-league-name{display:flex;align-items:center;width:100%;font-size:10px;line-height:13px;color:var(--color-featured-card-league-name)}.featured-game-card .media-item{width:12px;height:12px;display:flex;margin:0 3px 0 0}.featured-game-card__date{margin-bottom:4px;font-weight:700;justify-content:space-between}.featured-game-card__date .arrow-icon{font-size:14px;position:relative;left:5px}.featured-game-card__date .arrow-icon__glyph{display:block;width:1em;height:1em;color:var(--color-featured-game-sport-icon)}.featured-game-card__country-league-name{margin-bottom:7px;justify-content:flex-start}.featured-game-card__country-league-name span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.featured-game-card__team-names{display:flex;flex-direction:column;margin-bottom:8px}.featured-game-card__team{display:block;font-size:14px;line-height:19px;font-weight:700;color:var(--color-primary-text);width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.featured-game-card__odds{display:flex;align-items:center;justify-content:space-evenly;overflow:hidden;width:100%}.featured-game-card__no-outcome{display:flex;text-align:center;align-items:center;justify-content:center;font-size:13px;line-height:16px;margin-top:12px}","",""]]},34495:e=>{e.exports=[[e.id,".featured-games{display:flex;flex-direction:column;background:var(--color-featured-games-background-gradient);background-repeat:no-repeat;padding:8px 0;width:100%}.featured-games .horizontal-scroll-box__item{margin-right:9px}.featured-games .horizontal-scroll-box__item:first-child{margin-left:9px}.featured-games__header{display:flex;align-items:center;justify-content:flex-start;color:var(--color-featured-games-title);font-size:12px;line-height:16px;font-weight:700;text-transform:uppercase;margin-bottom:7px;padding:0 9px}.featured-games__header .media-item--icon{height:12px;width:12px;margin:0 5px 3px 0;fill:var(--color-featured-games-title)}.featured-games .info-message{display:flex;align-items:center;justify-content:center;background:var(--color-white) 0% 0% no-repeat padding-box;box-shadow:0px 0px 5px var(--color-featured-games-box-shadow);border-radius:5px;padding:22px;font-size:12px;line-height:16px;letter-spacing:0;color:var(--color-raisin-black);margin:34px 12px 52px}@media(min-width: 768px){.featured-games .info-message{margin:43px auto 42px;width:50%}}","",""]]},61:e=>{e.exports=[[e.id,'.featured-odds-button{display:flex;flex-direction:column;align-items:center;justify-content:center;min-width:60px;flex:1 1 auto;height:41px;padding:5px;font-family:"Roboto Condensed",sans-serif;background:linear-gradient(180deg, var(--color-odds-button-gradient-start) 0%, var(--color-odds-button-gradient-end) 100%);border:1px solid var(--color-odds-button-border);border-radius:2px;cursor:pointer}.featured-odds-button:not(:last-child){margin-right:8px}.featured-odds-button--selected{background:var(--color-cta-button-background);border-color:var(--color-cta-button-background)}.featured-odds-button__outcome{display:flex;align-items:center;font-size:10px;line-height:13px;font-weight:400;letter-spacing:0;color:var(--color-featured-card-market);word-break:break-all}.featured-odds-button__value{display:flex;align-items:center;justify-content:center;font-size:15px;line-height:20px;font-weight:700;color:var(--color-raisin-black)}.featured-odds-button__lock{height:16px;min-width:16px;max-width:16px;position:relative;bottom:1px;fill:var(--color-neutral-370)}.featured-odds-button__susp-label{width:100%;height:100%;display:flex;align-items:center;justify-content:center;font-size:13px;font-weight:700;line-height:20px;color:var(--color-neutral-370);cursor:not-allowed}',"",""]]}}]);