import{I as f,_ as v}from"./ProviderDetails.vue_vue_type_script_setup_true_lang-p2INfbe3.js";import{I}from"./ItemsListing-Bt7nSL64.js";import{d as _,r as m,ae as h,m as b,v as a,b2 as y,q as k,c as w,b as E,h as p,e as n,F as D,o as r}from"./index-BFxAF8P3.js";import"./Toolbar-IABQ_cGm.js";import"./VToolbar-4Hyomzsc.js";import"./VBtn-CWo0kh8N.js";import"./_plugin-vue_export-helper-DlAUqK2U.js";import"./marquee_text_sync-D4Cb9OFR.js";import"./MediaItemThumb-qBrtbw2Q.js";import"./VDialog-jEFtM9ke.js";import"./layout-Bgw3llWv.js";import"./Container-DiM3aZEa.js";import"./index-kQIztB-E.js";import"./VContainer-t8f0pxyy.js";/* empty css              */import"./ListItem-DLPNteOT.js";import"./Button-DpLLjLX9.js";import"./NowPlayingBadge.vue_vue_type_style_index_0_lang-C9phX4G4.js";import"./VInput-CzWaDhLk.js";import"./PanelviewItemCompact-Dn5F-Rok.js";import"./VSpacer-Cg98NNsv.js";import"./VTextField-CudJeW4H.js";import"./VInfiniteScroll-C0KSwa81.js";import"./VRow-B06TmOJY.js";import"./VVirtualScroll-ktNB5s8w.js";import"./VAlert-Dikxe4B7.js";const X=_({__name:"PodcastDetails",props:{itemId:{},provider:{}},setup(l){const t=l,i=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&&(i.value=!0)});k(o)});const u=async function(o){return await a.getPodcastEpisodes(t.itemId,t.provider)};return(o,s)=>(r(),w(D,null,[E(f,{item:e.value},null,8,["item"]),e.value?(r(),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":i.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?(r(),p(v,{key:1,"item-details":e.value},null,8,["item-details"])):n("",!0)],64))}});export{X as default};
