import{I as c}from"./ItemsListing-COLlw5bq.js";import{I as f,_ as v}from"./ProviderDetails.vue_vue_type_script_setup_true_lang-1QTHf_I3.js";import{aw as h,J as y,L as w,ax as I,ay as s,o as V,aG as m,az as l,E as g,aN as n,bV as k}from"./index-DhxwW1_d.js";import"./Container-D2fLqW0L.js";import"./index-kQIztB-E.js";import"./Toolbar-BfQbzcpc.js";import"./VToolbar-69Rn7taX.js";import"./Button-Dq6btUmD.js";import"./ListItem-DYjdeEgj.js";import"./userPreferences-Dy9_V1Qk.js";import"./VCheckboxBtn-DVNTnMLw.js";import"./MediaItemThumb-CBiFFPUA.js";import"./PanelviewItemCompact-KbS5CIFi.js";import"./VInfiniteScroll-Ce2Gi50Y.js";import"./VVirtualScroll-DTRxXskS.js";import"./VAlert-D-KKGAlc.js";import"./marquee_text_sync-BLGanaiv.js";import"./VDialog-CSHdlt_o.js";const j=h({__name:"RadioDetails",props:{itemId:{},provider:{}},setup(a){const t=a,e=y(),p=async function(){e.value=await n.getRadio(t.itemId,t.provider)};w(()=>t.itemId,o=>{o&&p()},{immediate:!0});const d=async function(o){const i=[];if(t.provider=="library"){const r=await n.getRadioVersions(t.itemId,t.provider);i.push(...r)}for(const r of k(e.value)){const u=await n.getRadioVersions(r.item_id,r.provider_instance);i.push(...u)}return i};return(o,i)=>(s(),I("section",null,[V(f,{item:e.value},null,8,["item"]),e.value?(s(),m(c,{key:0,itemtype:"radioversions","parent-item":e.value,"show-provider":!0,"show-favorites-only-filter":!1,"show-library":!1,"show-radio-number":!1,"show-duration":!1,"load-items":d,"sort-keys":["provider","sort_name"],title:o.$t("other_versions"),"hide-on-empty":!0,checksum:a.provider+a.itemId},null,8,["parent-item","title","checksum"])):l("",!0),i[0]||(i[0]=g("br",null,null,-1)),e.value?(s(),m(v,{key:1,"item-details":e.value},null,8,["item-details"])):l("",!0)]))}});export{j as default};
