import{I as f,_ as v}from"./ProviderDetails.vue_vue_type_script_setup_true_lang-CXwX75cg.js";import{I}from"./ItemsListing-6VW59A0B.js";import{av as _,H as m,J as h,a3 as y,aL as o,b6 as b,a4 as w,aw as k,x as D,aD as p,ay as n,ag as E,ax as i}from"./index-C-Ivu3jU.js";import"./Toolbar-CLPRlZ-4.js";import"./VToolbar-DTucOBiF.js";import"./_plugin-vue_export-helper-DlAUqK2U.js";import"./marquee_text_sync-DUGxi-pZ.js";import"./MediaItemThumb-BsXB7IV6.js";import"./VDialog-BZuFHdVP.js";import"./layout-D2NB7OTD.js";import"./Container-DVyc_Yt_.js";import"./index-kQIztB-E.js";import"./VContainer-CNNJtZg6.js";import"./ListItem-BLmrgznL.js";import"./Button-FtStaD9_.js";import"./NowPlayingBadge.vue_vue_type_style_index_0_lang-B5IzKSW4.js";import"./VCheckboxBtn-BmKOjEU4.js";import"./VInput-CnrZS6Kh.js";import"./PanelviewItemCompact-5_ppRL3T.js";import"./VTextField-Bkx949P5.js";import"./VSnackbar-C_PtJN1U.js";import"./VRow-DOG0WeJD.js";import"./VVirtualScroll-C_Lzj3jv.js";import"./VAlert-B3qbTkCR.js";const S=_({__name:"PodcastDetails",props:{itemId:{},provider:{}},setup(l){const t=l,r=m(!1),e=m(),d=async function(){e.value=await o.getPodcast(t.itemId,t.provider)};h(()=>t.itemId,a=>{a&&d()},{immediate:!0}),y(()=>{const a=o.subscribe(b.MEDIA_ITEM_UPDATED,s=>{const c=s.data;e.value?.uri==c.uri&&(r.value=!0)});w(a)});const u=async function(a){return await o.getPodcastEpisodes(t.itemId,t.provider)};return(a,s)=>(i(),k(E,null,[D(f,{item:e.value},null,8,["item"]),e.value?(i(),p(I,{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:a.$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{S as default};
