import{I as f,_ as v}from"./ProviderDetails.vue_vue_type_script_setup_true_lang-BaDwFhok.js";import{I as _}from"./ItemsListing-CqOkN5bP.js";import{d as I,i as m,ad as h,j as b,m as a,a_ as y,l as k,c as w,b as E,e as p,q as n,F as D,o as i}from"./index-BLuBzgcR.js";import"./MediaItemThumb-4FqrTjbr.js";import"./_plugin-vue_export-helper-DlAUqK2U.js";import"./Toolbar-RSDUeNZR.js";import"./VToolbar-BFOvSQM-.js";import"./VBtn-i8gedOhv.js";import"./marquee_text_sync-CbqHGytl.js";import"./VDialog-CUNnqGJy.js";import"./layout-Dtt5lK8k.js";import"./Container-BVutxj42.js";import"./index-CBho6rsP.js";import"./VContainer-DOe7JF0h.js";/* empty css              */import"./ListItem-D3UfOTqB.js";import"./Button-BEhYIX-0.js";import"./NowPlayingBadge.vue_vue_type_style_index_0_lang-Dwz4QKKd.js";import"./VInput-S8c2HXsf.js";import"./PanelviewItemCompact-Czo8xJLH.js";import"./VSpacer-FdmIBMIx.js";import"./VTextField-BRzkPyuL.js";import"./VInfiniteScroll-XtiIpwbc.js";import"./VRow-Dw7kUaJt.js";import"./VVirtualScroll-JP5E3DQw.js";import"./VAlert-Du-laR0E.js";const X=I({__name:"PodcastDetails",props:{itemId:{},provider:{}},setup(l){const t=l,r=m(!1),e=m(),d=async function(){e.value=await a.getPodcast(t.itemId,t.provider)};h(()=>t.itemId,o=>{o&&d()},{immediate:!0}),b(()=>{const o=a.subscribe(y.MEDIA_ITEM_UPDATED,s=>{const c=s.data;e.value?.uri==c.uri&&(r.value=!0)});k(o)});const u=async function(o){return await a.getPodcastEpisodes(t.itemId,t.provider)};return(o,s)=>(i(),w(D,null,[E(f,{item:e.value},null,8,["item"]),e.value?(i(),p(_,{key:0,itemtype:"podcastepisodes","parent-item":e.value,"show-provider":!1,"show-library":!1,"show-favorites-only-filter":!1,"show-track-number":!0,"show-refresh-button":!0,"load-items":u,"sort-keys":["position","position_desc","name","duration","duration_desc"],"update-available":r.value,title:o.$t("podcast_episodes"),"allow-key-hooks":!0,path:`podcast.${t.itemId}.${t.provider}`,"restore-state":!0,"no-server-side-sorting":!0},null,8,["parent-item","update-available","title","path"])):n("",!0),e.value?(i(),p(v,{key:1,"item-details":e.value},null,8,["item-details"])):n("",!0)],64))}});export{X as default};
