PageSourceSearch

https://www.ewn.co.za/_nuxt/D_nB-MKF.js

js ewn.co.za collected 2026-10-02 02:33:02 UTC 5,099 bytes, 1 lines download raw bytes

1import{_ as j,c as r,o,a as t,d as O,F as Q,l as q,i as B,a1 as G,aq as H,k as v,Z as J,a2 as K,Y,A as V,B as m,n as e,aH as Z,b as w,w as I,t as E,a4 as X,P,N as W,I as ee,Q as te,j as se,aj as ae,s as ne,aI as oe,aJ as ie,aK as $}from"./CBZx7rdy.js";import{p as le,_ as re}from"./BZzmG6MK.js";import{_ as de}from"./BxuJWLtB.js";import{U as ue}from"./DNPHahWu.js";import{u as ce,a as me,b as pe}from"./DeRQV9iI.js";import"./DB0RT30T.js";import"./DYRToSYT.js";const _e={},ve={class:"w-full mt-4"},ge={class:"lg:grid grid-cols-12 gap-5"},he={class:"col-span-5"},fe={class:"space-y-4"};function ye(T,i){return o(),r("div",ve,[t("div",ge,[i[1]||(i[1]=O('<div class="col-span-7"><div class="aspect-video bg-gray-200 animate-pulse rounded-lg mb-4"></div><div class="h-8 bg-gray-200 animate-pulse rounded mb-2"></div><div class="h-4 bg-gray-200 animate-pulse rounded w-3/4 mb-2"></div><div class="h-4 bg-gray-200 animate-pulse rounded mb-1"></div><div class="h-4 bg-gray-200 animate-pulse rounded w-5/6 mb-1"></div><div class="h-4 bg-gray-200 animate-pulse rounded w-2/3"></div></div>',1)),t("div",he,[t("div",fe,[(o(),r(Q,null,q(5,l=>t("div",{key:l,class:"flex gap-3"},i[0]||(i[0]=[t("div",{class:"w-24 h-16 bg-gray-200 animate-pulse rounded"},null,-1),t("div",{class:"flex-1"},[t("div",{class:"h-4 bg-gray-200 animate-pulse rounded mb-1"}),t("div",{class:"h-3 bg-gray-200 animate-pulse rounded w-2/3"})],-1)]))),64))])])])])}const be=j(_e,[["render",ye]]),xe=P(te),we={key:1,class:"w-full mt-4 text-center py-8"},Te={key:2,class:"w-full mt-4"},Ae={class:"lg:grid grid-cols-12 gap-5"},ke={class:"col-span-7 lg:sticky lg:top-4 lg:h-fit"},Ee={class:"mt-3"},Ve={class:"flex flex-col gap-1"},Le={key:0,class:"text-paragraph-xs font-medium text-content-secondary"},Ne={key:1,class:"text-3xl tracking-tighter font-extrabold"},De={key:2,class:"text-paragraph-md"},Ce={key:0,class:"mt-3"},Se={class:"col-span-5"},Ue={key:3,class:"w-full mt-4 text-center py-8"},Ie=B({__name:"EWNTVDetail.client",props:{tvlanguage:{}},setup(T){const i=T,l=G(),g=H(),L=ce("cursor",void 0),N=v(()=>({first:10,language:i.tvlanguage,cursor:L.value})),{loading:h,result:p,error:R,execute:z}=me(N);J(()=>i.tvlanguage,async()=>{await z()},{immediate:!1});const s=v(()=>{var a,n;return!p.value||p.value.length===0?null:(n=(a=p.value[0])==null?void 0:a.node)==null?void 0:n.detail}),F=v(()=>!p.value||p.value.length===0?[]:p.value.slice(1)),M=v(()=>l.path!=="/ewn-tv"),{result:A}=pe();return K(()=>{var a,n,f;if(A.value){const _=(n=(a=A.value.livestreamAsset)==null?void 0:a.livestreamAssetList)==null?void 0:n.items;if(_&&_.length>0){const k=Math.floor(Date.now()/1e3),y=_.filter(u=>{var c,d;return((d=(c=u.livestreamAsset)==null?void 0:c.publishedAt)==null?void 0:d.unixSeconds)&&u.livestreamAsset.publishedAt.unixSeconds<k});if(y.length>0){const u=y.reduce((c,d)=>{var D,C,S,U;const b=((C=(D=c.livestreamAsset)==null?void 0:D.publishedAt)==null?void 0:C.unixSeconds)||0;return(((U=(S=d.livestreamAsset)==null?void 0:S.publishedAt)==null?void 0:U.unixSeconds)||0)>b?d:c});l.path==="/ewn-tv"&&((f=u.livestreamAsset)!=null&&f._url)&&g.push("/ewn-tv/livestream"+u.livestreamAsset._url)}}}}),Y(()=>{le()}),(a,n)=>{var d,b;const f=be,_=X,k=re,y=xe,u=ee,c=de;return e(h)?(o(),V(f,{key:0})):e(R)?(o(),r("div",we,[n[1]||(n[1]=t("p",{class:"text-red-600"},"Failed to load episodes. Please try again.",-1)),t("button",{class:"mt-4 px-4 py-2 bg-blue-600 text-white rounded hover:bg-blue-700",onClick:n[0]||(n[0]=x=>("navigateTo"in a?a.navigateTo:e(Z))(e(l).fullPath,{replace:!0}))}," Retry ")])):e(s)?(o(),r("div",Te,[t("div",Ae,[t("div",ke,[w(u,null,{default:I(()=>[e(s)?(o(),V(k,{key:0,data:{duration:e(s).duration,image:e(s).headerImage,mediaId:e(s).mediaId,title:e(s).headline,mediaType:e(s).__typename,isLiveStream:!1,autoplay:e(M)}},{default:I(()=>{var x;return[t("header",null,[t("div",Ee,[t("div",Ve,[(x=e(s).publishedAt)!=null&&x.unixSeconds?(o(),r("span",Le,E(("UTCDateToLocalDateWithTime"in a?a.UTCDateToLocalDateWithTime:e(ue))(e(s).publishedAt.unixSeconds)),1)):m("",!0),e(s).headline?(o(),r("h1",Ne,E(e(s).headline),1)):m("",!0),e(s).text?(o(),r("p",De,E(e(s).text),1)):m("",!0)])]),e(s).tags?(o(),r("div",Ce,[w(_,{tags:e(s).tags,max:
15},null,8,["tags"])])):m("",!0)])]}),_:1},8,["data"])):m("",!0),w(y,{"slot-id":("AdUnits"in a?a.AdUnits:e(W)).tv[0].id,sizes:("AdUnits"in a?a.AdUnits:e(W)).tv[0].size,"use-responsive-breakpoint":!0,class:"mt-3"},null,8,["slot-id","sizes"])]),_:1})]),t("div",Se,[w(c,{livestreams:(b=(d=e(A))==null?void 0:d.livestreamAsset)==null?void 0:b.livestreamAssetList,"ewn-tv-items":e(F)},null,8,["livestreams","ewn-tv-items"])])])])):!e(h)&&!e(s)?(o(),r("div",Ue,n[2]||(n[2]=[t("p",{class:"text-content-secondary"},"No episodes available for the selected language.",-1)]))):m("",!0)}}}),We=P(Ie),je=B({__name:"[...slug]",setup(T){const i=se(!1),{ewnTVLanguage:l}=ae();ne(()=>{l.value||(ie.value=oe.en),i.value=!0});const g=v(()=>!i.value||!l.value?null:l.value==="en"?$.en:$.zu);return(L,N)=>{const h=We;return e(g)?(o(),V(h,{key:0,tvlanguage:e(g)},null,8,["tvlanguage"])):m("",!0)}}});export{je as default};

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.