PageSourceSearch

https://static-v1.mydramawave.com/frontend_static/assets/episode-page-DF190vx7.js

js mydramawave.com collected 2026-09-24 19:42:30 UTC 9,989 bytes, 1 lines download raw bytes

1import{c as le,an as ie,u as ne,ag as E,k as ue,o as B,bf as ce,n as h,bb as de}from"./index-clKWBUrY.js";import{o as pe}from"./open-dialog-JECqpbzm.js";import{u as me,b as fe,f as ge,l as H,p as N,a as U,c as F,d as V,e as Q,g as W,h as G,i as M,j as ve,k as he}from"./use-player-CbWO34dr.js";import{g as xe}from"./go-to-app-DzljYvSx.js";import{a as g}from"./track-CxuEyE8B.js";import{h as m,Q as be,f as we,p as _e,b as ye,w as ke,m as o,H as ze,n as Se}from"./v-deps-D54qY0Ks.js";import{B as J}from"./button-B4XtS-Wm.js";import"./vue-helper-digR9wZF.js";function De(i){return typeof i=="function"||Object.prototype.toString.call(i)==="[object Object]"&&!ze(i)}const Pe=le(null,()=>{const i=be(),y=m([]),l=m(),x=m(!0),k=m(!1),z=m(!0),S=m(!1),R=m(!1),b=m(),f=i.currentRoute.value.params.episodeId,T=i.currentRoute.value.query.subtitle_language,K=i.currentRoute.value.query.audiotrack_language??"en-US",{t:c}=ie(i.currentRoute.value.query.language),{t:d}=ne(["share.toast.takeOffShelf","share.episodeDialog.title","share.episodeDialog.description","share.episodeDialog.tips","share.episodeDialog.button","share.episodeDialog.limit24","share.watchNow"]),{player:u,isPlaying:D,showPlayOrPause:v,initPlayer:O,showLoading:X}=me(),q=we(()=>{var e,a,s,t,r,n,w,_,$;return(s=(a=(e=l.value)==null?void 0:e.episode_list)==null?void 0:a[0])!=null&&s.external_audio_h264_m3u8?(n=(r=(t=l.value)==null?void 0:t.episode_list)==null?void 0:r[0])==null?void 0:n.external_audio_h264_m3u8:(($=(_=(w=l.value)==null?void 0:w.episode_list)==null?void 0:_[0])==null?void 0:$.video_url)??""});(e=>{e.forEach(a=>{const s=new Image;s.src=a})})([V,Q,W,H,N,U,F,G,M]);const A=()=>{var e,a,s;(e=u.value)==null||e.on("canplay",()=>{var t;S.value||(S.value=!0,Y(),R.value&&((t=u.value)==null||t.play()))}),(a=u.value)==null||a.on("ready",()=>{oe()}),(s=u.value)==null||s.on("ended",()=>{D.value=!1,z.value=!0,L(),Se(()=>{var t;(t=u.value)==null||t.dispose(),u.value=void 0,S.value=!1,O({source:q.value,id:"mse"}),A()})})},Y=()=>{var s;const e=document.querySelectorAll(".prism-audio-selector .selector-list li"),a=(s=Array.from(e).filter(t=>t.textContent===K))==null?void 0:s[0];a&&a.click()},Z=()=>{var e,a,s;v.value=!0,u.value&&(((e=u.value)==null?void 0:e.getStatus())==="pause"?(a=u.value)==null||a.play():(s=u.value)==null||s.pause())},ee=async()=>{var e,a,s;if((s=(a=(e=l.value)==null?void 0:e.episode_list)==null?void 0:a[0])!=null&&s.subtitle_list&&typeof T<"u"){const t=l.value.episode_list[0].subtitle_list.find(r=>r.language===T);if(t){const n=await(await fetch(t.subtitle)).text();ae(n)}}},te=()=>{ve(f).then(async({data:e})=>{if(e){const{finish_status:a}=e.series_info;a===3?(x.value=!1,l.value=e.series_info,await ee(),O({source:q.value,id:"mse"}),A(),L()):(x.value=!0,B(d("share.toast.takeOffShelf",c("share.toast.takeOffShelf"))))}}).catch(e=>{x.value=!0,B(d("share.toast.takeOffShelf",c("share.toast.takeOffShelf")))})},ae=e=>{const a=/(\d{2}:\d{2}:\d{2},\d{3}) --> (\d{2}:\d{2}:\d{2},\d{3})\n([\s\S]*?)(?=\n\n|$)/g,s=e.matchAll(a),t=[];for(const r of s){const n=C(r[1]),w=C(r[2]),_=r[3].trim();t.push({start:n,end:w,text:_})}y.value=t},C=e=>{const a=e.split(":"),s=parseFloat(a[2].replace(",","."));return+a[0]*3600+ +a[1]*60+s};_e(()=>{se()}),ye(async()=>{E||g("H5_series","page","show",{series_id:f,share_user_id:i.currentRoute.value.query.share_user_id,page_type:"drm"}),I("//static-v1.mydramawave.com/frontend_static/aliplayer-min.css"),await I("//static-v1.mydramawave.com/frontend_static/aliplayer.js").then(()=>{te()})});let j;ke(()=>v.value,()=>{j&&clearTimeout(j),v.value&&(j=window.setTimeout(()=>{v.value=!1},3e3))});const I=e=>new Promise((a,s)=>{if(e.endsWith(".js")){const t=document.createElement("script");t.dataset.dynamic="true",t.src=e,t.type="text/javascript",t.onload=()=>a(t),t.onerror=()=>s(new Error(`Failed to load script: ${e}`)),document.head.appendChild(t)}else if(e.endsWith(".css")){const t=document.createElement("link");t.dataset.dynamic="true",t.href=e,t.rel="stylesheet",t.onload=()=>a(t),t.onerror=()=>s(new Error(`Failed to load stylesheet: ${e}`)),document.head.appendChild(t)}else s(new Error(`Unsupported file type: ${e}`))}),se=()=>{const e=document.querySelectorAll('script[data-dynamic="true"]'),a=document.querySelectorAll('link[data-dynamic="true"]');e.forEach(s=>s.remove()),a.forEach(s=>s.remove())},P=()=>{var r,n;const e=`${ce}?redirect=${encodeURIComponent("/detail?id="+((r=l.value)==null?void 0:r.id)+"&from_share=1")}`,t=`https://${window.location.hostname.indexOf("thedramabuzz")>=0?"m1.thedramabuzz.com":E?"free-reels.com":"mydramawave.com"}?redirect=${encodeURIComponent("/detail?id="+((n=l.value)==null?void 0:n.id)+"&from_share=1")}`;xe(de?t:e)},oe=()=>{var s;const e=(s=document.getElementById("mse"))==null?void 0:s.getElementsByTagName("video")[0];if(!e)return;function a(){if(!e)return;const t=e.currentTime;if(y.value.length>0){const r=y.value.find(n=>!n.start||!n.end?!1:t>=n.start&&t<=n.end);r?b.value=r.text:b.value=void 0}}e.addEventListener("timeupdate",a)},{language:p}=ue({language:"en"}),re=window.location.hostname.indexOf("thedramabuzz")>=0?fe:E?ge:H,L=()=>{var e,a,s;g("H5_series","popup","show",{series_id:f,share_user_id:i.currentRoute.value.query.share_user_id}),k.value=!0,pe({title:"",closeVisible:!0,body:o("div",{style:{backgroundImage:`url(${p!=="ar"?Q:G})`,backgroundSize:"100% 100%"},class:"flex min-h-[260px] flex-col bg-no-repeat p-2 pt-5"},[o("img",{src:p!=="ar"?W:M,class:h("fixed top-0 h-[102px] w-[104px] object-cover",p!=="ar"?"right-0":"left-0"),width:104,height:102}
1,null),o("x-title",{class:"line-clamp-3 w-[calc(100%-104px+0.5rem)] px-2 text-lg font-bold leading-snug text-[var(--black)]"},[d("share.episodeDialog.title",c("share.episodeDialog.title"))]),o("x-description",{class:"mt-2 line-clamp-2 w-[calc(100%-5rem)] pl-2 text-sm font-normal text-[var(--grey-7)]"},[d("share.episodeDialog.description",c("share.episodeDialog.description"))]),o("x-card",{class:"mt-3 flex h-auto w-full flex-col items-start gap-0 rounded-xl bg-[var(--white)] pb-3"},[o("x-tips",{style:"flex: 1 1 auto;",class:h("h-5 w-auto grow-0 bg-[#fc2763]/20 px-2 py-1 text-[10px] font-bold text-[var(--brand-6)]",p==="ar"?"rounded-bl-xl rounded-tr-xl":"rounded-br-xl rounded-tl-xl")},[d("share.episodeDialog.tips",c("share.episodeDialog.tips"))]),o("x-content",{class:h("mt-1 grid w-full grid-cols-[34.41px_auto] items-start gap-x-3 rounded-xl py-2  font-normal",p==="ar"?"pl-6 pr-2":"pl-2 pr-6")},[o("img",{src:(e=l.value)==null?void 0:e.cover,class:"row-span-2 h-12 max-h-12 w-[34.41px] rounded-lg object-cover"},null),o("div",{class:"mt-[6.5px] truncate text-sm text-[#090609]"},[(a=l.value)==null?void 0:a.name]),o("div",{class:"mb-[6.5px] mt-1 truncate text-xs text-[#797b7d]"},[(s=l.value)==null?void 0:s.desc])]),o(J,{onClick:()=>{g("H5_series","popupwatch","click",{series_id:f,share_user_id:i.currentRoute.value.query.share_user_id}),P()},class:"relative mx-2 mt-4 flex h-11 w-[calc(100%-1rem)] flex-nowrap items-center justify-center rounded-lg border-none bg-[#fc2763] text-base leading-tight text-white/90"},{default:()=>[o("div",{class:"w-full truncate px-2"},[d("share.episodeDialog.button",c("share.episodeDialog.button"))]),o("div",{class:h("absolute -top-[18px] h-[18px] w-auto rounded-xl border border-solid border-[#fff8e6] bg-[var(--gradient-1)] px-2 text-left text-[10px] leading-4 text-[var(--white)]",p==="ar"?"left-1":"right-1")},[d("share.episodeDialog.limit24",c("share.episodeDialog.limit24")),o("img",{src:p==="ar"?he:V,class:h("z-up absolute -bottom-[7px]  h-2 w-auto object-cover",p==="ar"?"left-[23px]":"right-[23px]")},null)])]})])]),beforeClose:()=>{var t;g("H5_series","popupclose","click",{series_id:f,share_user_id:i.currentRoute.value.query.share_user_id}),k.value=!1,z.value=!1;try{(t=u.value)==null||t.play()}catch{R.value=!0}}})};return()=>{var a,s,t,r;let e;return x.value?null:o("div",{class:"pc:w-[calc(var(--pc-page-max-width))]  size-full"},[o("x-video-player",{id:"mse",class:"relative flex size-full items-center justify-center"},null),o("x-video-controls",{class:"share-bottom"},[o("img",{src:re,class:"z-12 z-up-up fixed right-3 top-0 size-11 object-cover"},null),v.value&&o("img",{src:D.value?N:U,onClick:()=>{Z(),D.value||g("H5_series","play","click",{series_id:f,share_user_id:i.currentRoute.value.query.share_user_id})},class:"w-18 h-18 fixed left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2 object-cover"},null),!k.value&&X.value&&o("x-loading-wrapper",{class:"z-up-up fixed left-0 top-0 flex size-full items-center justify-center"},[o("img",{src:F,class:"size-16 animate-spin object-cover"},null)]),z.value&&o("img",{src:(a=l.value)==null?void 0:a.cover,class:"z-up fixed left-0 top-0 size-full object-cover"},null),b.value&&o("x-subtitle",{class:"pc:w-[calc(var(--pc-page-max-width))]  subtitle z-up fixed left-1/2 block w-full -translate-x-1/2 text-wrap break-words bg-transparent px-3 text-center text-[24px] text-[var(--white)]"},[b.value])]),o("x-footer",{class:"pc:w-[calc(var(--pc-page-max-width))] z-up-up  share-bottom fixed bottom-0 left-1/2 flex h-auto w-full -translate-x-1/2 flex-col rounded-t-lg bg-[rgba(36,_37,_38,_0.65)] px-3 pt-2 backdrop-blur-[2px]"},[o("x-episode",{class:"grid grid-cols-[44.49px_auto] gap-x-3"},[o("img",{src:(s=l.value)==null?void 0:s.cover,class:"max-h-15 row-span-2 h-auto w-[44.49px] rounded object-cover"},null),o("x-episode-title",{class:"mt-[11px] truncate text-base leading-tight text-[var(--white)]"},[(t=l.value)==null?void 0:t.name]),o("x-episode-description",{class:"mb-[11px] mt-1 truncate text-xs font-normal text-[var(--grey-7)]"},[(r=l.value)==null?void 0:r.desc])]),o(J,{onClick:()=>{g("H5_series","watchnow","click",{series_id:f,share_user_id:i.currentRoute.value.query.share_user_id}),P()},class:"mt-2 h-11 rounded-lg border-none bg-[var(--brand-6)] text-base leading-tight text-[rgba(255,_251,_255,_0.9)]"},De(e=d("share.watchNow",c("share.watchNow")))?e:{default:()=>[e]})])])}});
1export{Pe as EpisodePage,Pe 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.