1(()=>{(function(){try{var p=typeof window!="undefined"?window:typeof global!="undefined"?global:typeof globalThis!="undefined"?globalThis:typeof self!="undefined"?self:{},E=new p.Error().stack;E&&(p._sentryDebugIds=p._sentryDebugIds||{},p._sentryDebugIds[E]="481245e9-33db-4317-956e-585ba58afa09",p._sentryDebugIdIdentifier="sentry-dbid-481245e9-33db-4317-956e-585ba58afa09")}catch(o){}})();(self.webpackChunkdice_web=self.webpackChunkdice_web||[]).push([[1171],{34584:((p,E,o)=>{o.r(E),o.d(E,{default:()=>Bt});var s=o(96540),I=o(71468),G=o(76213),X=o(94600),j=o(31036),$=o(1346),P=o(68407),dt=o(67354),ut=o(78955),vt=o(12544),ft=o(59530),gt=o(755),ht=o(88382),z=o(87585),St=o(2275),pt=o(32248),mt=o(58562),yt=o(90953),Ct=o(63196),Ot=o(9849),Et=o(39666),Pt=o(34479),Y=o(72414),J=o(73145),Dt=o(73575),Lt=o(57611),At=o(52955),F=o(16231),K=o(16505),Z=o(55488),Nt=o(9236);const Rt=({seriesId:t,seasonId:e,getReadyState:r,CardList:D,series:d,fetchSeries:m,fetchNextSeries:L,season:u,fetchSeasonContent:A,fetchNextSeasonContent:N,trackEvents:g,handleSeasonClick:y,updateSeriesData:R})=>{var C;const W=(0,Lt.W)(),U=(0,G.zy)(),{noContentAvailable:h,anErrorOccured:T,addToWatchlist:V}=(0,mt.b0)(["noContentAvailable","anErrorOccured","addToWatchlist"]),[v,q]=s.useState(e),[O,_]=s.useState(t),[b,tt]=s.useState([]),[Ht,et]=(0,Pt.M)(),Gt=(0,I.d4)(a=>a.services.session.user.isGuest),Xt=(0,I.d4)(a=>a.services.app.isRtL),{socialSharingStatus:$t,watchlistsEnabled:zt}=(0,yt.U)(),n=u==null?void 0:u.data[v],l=d==null?void 0:d.data[O],nt=W.action==="POP",H=(0,Ct.SO)([F.V7]),lt=H<F.V7,{hasLoginStateChanged:ot}=(0,At.O)(),x=(nt||U.hash.includes(Z.UT))&&n;s.useEffect(()=>{t?x||_(t):!x&&e&&q(e)},[t,e,x]),s.useEffect(()=>{t&&m(t)},[t]),s.useEffect(()=>{var a,i;l&&!v&&q((i=(a=l.seasons)==null?void 0:a[0])==null?void 0:i.id)},[l]),s.useEffect(()=>{v&&!x&&at(v)},[v,x]),s.useEffect(()=>{ot&&at(v)},[ot]),s.useEffect(()=>{var a,i;if(!(u.data&&v))return;let c;const S=(i=(a=u==null?void 0:u.data[v])==null?void 0:a.series)==null?void 0:i.seriesId;S?c=S:c=Object.keys(d==null?void 0:d.data).find(f=>{var M,it,rt;return Array.isArray((M=d.data[f])==null?void 0:M.seasons)?(rt=(it=d.data[f])==null?void 0:it.seasons)==null?void 0:rt.some(ct=>(ct==null?void 0:ct.id)===v):!1}),c&&(_(c),Object.keys(d.data).map(Number).some(f=>f==c)||m(c))},[u.data,v,d.data]),s.useEffect(()=>{const a=b.some(i=>i.id==(n==null?void 0:n.id));nt||U.hash.includes(Z.UT)||n!=null&&n.id&&(l!=null&&l.id)&&!a&&H>F.V7&&Yt(l.id,n.id)},[n==null?void 0:n.id,l==null?void 0:l.id,H]);const Yt=async(a,i)=>{const c=await Jt(a,i),S={id:n.id,title:n.title,description:n.description,longDescription:n.longDescription,coverUrl:n.coverUrl,smallCoverUrl:n.smallCoverUrl,episodeCount:n.episodeCount,seasonNumber:n.seasonNumber},f=[...c.precedingSeasons,S,...c.followingSeasons];tt(f)},Jt=async(a,i)=>{const c=K.LV.baseUrl.replace("/v2","/v4");return await K.LV.get(`${c}/series/${a}/adjacentTo/${i}`)},at=async a=>{await A(a)},Kt=({id:a,type:i,accessLevel:c,title:S})=>{var f;!lt&&d.data[O].seasons&&b.length>0&&(d.data[O].seasons=b,R(d.data[O])),(f=g==null?void 0:g.cardClick)==null||f.call(g,{id:a,type:i,accessLevel:c,title:S,collectionId:n.id})},Zt=()=>u.isFetching?null:s.createElement(D,{contentList:(n==null?void 0:n.episodes)||[],title:"playlist",seasonId:n==null?void 0:n.id,showInlineCards:!0,onCardClick:Kt}),Qt=async a=>{y==null||y(a)},wt=()=>{var a;N(v),(a=g==null?void 0:g.loadMore)==null||a.call(g,n.id)},st=s.createElement("div",{className:"empty"},s.createElement("span",null,h.value)),kt=()=>{if(n){const{title:a,episodes:i}=n;if(!(i!=null&&i.length)&&a)return st}else if(!u.isFetching)return st},qt=s.createElement(Ot.O,{handleClick:et,isBadge:!1}),_t=()=>{const a=[],i=t?l==null?void 0:l.socialSharingDetail:n==null?void 0:n.socialSharingDetail,c=t?O:v;return $t===pt.X4.ENABLED&&i&&a.push(s.createElement(Y.O,{contentId:c==null?void 0:c.toString(),linkType:t?P.OF.SERIES:P.OF.SEASON,shareTitle:t?l==null?void 0:l.title:n==null?void 0:n.title,shareDescription:t?l==null?void 0:l.description:n==null?void 0:n.description,socialSharingDetail:i,iconStyle:Y.p.LIGHT})),zt&&!Gt&&a.push((0,J.It)(qt,V.value,J.C_.RIGHT)),a},te=()=>{var a,i,c,S,f,M;return!l&&!n?null:{title:(a=n==null?void 0:n.title)!=null?a:l==null?void 0:l.title,titleImage:l==null?void 0:l.titleImage,channelLogo:l==null?void 0:l.channelLogo,tags:[(i=l==null?void 0:l.contentRating)==null?void 0:i.rating],description:(c=n==null?void 0:n.description)!=null?c:l==null?void 0:l.description,backgroundImage:(S=n==null?void 0:n.coverUrl)!=null?S:l==null?void 0:l.coverUrl,year:(M=(f=n==null?void 0:n.year)!=null?f:l==null?void 0:l.year)==null?void 0:M.toString(),extraCtaButtons:_t()}},ee=lt?l==null?void 0:l.seasons:b.length>0?b:l==null?void 0:l.seasons;return l!=null&&l.id?s.createElement(s.Fragment,null,s.createElement(Nt.e,{getReadyState:r,className:t?"collection":"playlist",list:Zt(),hasMoreContent:(C=n==null?void 0:n.paging)==null?void 0:C.moreDataAvailable,fetchNextContentPage:wt,hasMoreSeasons:l==null?void 0:l.paging.moreDataAvailable,fetchNextSeasonsPage:()=>L(O),emptyMessage:kt(),hero:te(),seasons:ee,setSeasonList:tt,selectedSeasonId:v,selectSeason:Qt,isLoadingContent:u.isFetching||u.isFetchingNext,error:u.error||d.error?T.value:null,currentSeriesId:l==null?void 0:l.id}),Ht&&s.createElement(Et.z,{AddToWatchlistPanel:Dt.A,eventId:String(t||e),toggleWatchlistModal:et,contentType:e?P.R6.VOD_SEASON:P.R6.VOD_SERIES,isRtL:Xt})):null};var Tt=Object.defineProperty,bt=Object.defineProperties,xt=Object.getOwnPropertyDescriptors,Q=Object.getOwnPropertySymbols,Mt=Object.prototype.hasOwnProperty,Ut=Object.prototype.propertyIsEnumerable,w=(t,e,r)=>e in t?Tt(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,B=(t,e)=>{for(var r in e||(e={}))Mt.call(e,r)&&w(t,r,e[r]);if(Q)for(var r of Q(e))Ut.call(e,r)&&w(t,r,e[r]);return t},k=(t,e)=>bt(t,xt(e));const It=({match:{params:{seasonId:t,seriesId:e}},season:r,series:D,getReadyState:d,fetchSeasonContent:m,fetchNextSeasonContent:L,fetchSeries:u,updateSeriesData:A,fetchNextSeries:N,setPageTitle:g,history:y})=>{const{routes:R}=s.useContext(ft.P),C=(0,G.zy)(),W={loadMore:(h,T)=>(0,z.u4)($.Y0.LOAD_MORE,{collectionId:h,page:T}),cardClick:h=>{(0,z.u4)($.Y0.CARD_CLICK,h)}},U=h=>{const{pathname:T,state:V}=(0,ut.Rw)(P.ji.SEASON,R,h==null?void 0:h.toString(),null,null,null,null,null,null,C);(0,St.mH)(T,y,{state:V})};return s.useEffect(()=>{if(r.data[t]){const h=r.data[t].title;g(h)}},[r.data]),s.createElement(Rt,{seasonId:parseInt(t,10),seriesId:parseInt(e,10),getReadyState:d,CardList:Wt,series:D,fetchSeries:u,fetchNextSeries:N,season:r,fetchSeasonContent:m,fetchNextSeasonContent:L,trackEvents:W,handleSeasonClick:U,updateSeriesData:A})},jt=t=>({fetchSeries:e=>t(j.X.fetchRequest({seriesId:e,shouldFetchFirstSeason:!1,rpp:20})),updateSeriesData:e=>t(j.X.fetchSuccess(e)),fetchNextSeries:e=>t(j.X.fetchNextRequest({seriesId:e,rpp:20})),fetchSeasonContent:e=>t(X.x.fetchRequest({seasonId:e})),fetchNextSeasonContent:e=>t(X.x.fetchNextRequest({seasonId:e})),setPageTitle:e=>t((0,dt.D)([e]))}),Ft=({season:t,series:e})=>({season:t,series:e}),Bt=(0,gt.y)((0,I.Ng)(Ft,jt)((0,ht.U)(It))),Wt=t=>{const e=k(B({},t),{contentList:Vt(t.contentList),playlistId:t.seasonId});return s.createElement(vt.A,B({},e))},Vt=t=>t.map(e=>{const{accessLevel:r,badge:D,description:d,duration:m,favourite:L,id:u,maxHeight:A,subEvents:N,thumbnailUrl:g,title:y,type:R,computedReleases:C}=e;return k(B({accessLevel:r,availablePurchases:[]},Object.prototype.hasOwnProperty.call(e,"badge")&&{badge:D}),{description:d,duration:m,favourite:L,id:u,maxHeight:A,subEvents:N,thumbnailUrl:g,title:y,type:R,computedReleases:C})})})}]);})(); 2 3//# sourceMappingURL=collection.07aba666003624a8fa34.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.