import{I as c}from"./ItemsListing-nJ4gZwpG.js";import{I as f,_ as v}from"./ProviderDetails.vue_vue_type_script_setup_true_lang-CUmuLiJs.js";import{x as y,r as h,w as I,y as a,D as w,n as V,z as m,K as p,B as g,I as s,ay as k}from"./index-B55Az6uZ.js";import"./ItemContextMenu.vue_vue_type_style_index_0_scoped_3a9a25e3_lang-bhWnvEZi.js";import"./ProviderIcon.vue_vue_type_script_setup_true_lang-DmwHlomN.js";import"./VListItem-CTt5-rrr.js";import"./VChip-USL2zd6t.js";import"./VList-BbG08zRJ.js";import"./VCardText-6y4Yo2hg.js";import"./VCard-Ba6kturx.js";import"./VMenu-BJOay2FN.js";import"./_plugin-vue_export-helper-DlAUqK2U.js";import"./eventbus-CGRXT3Tn.js";import"./ListItem-BIOYzg71.js";import"./VCheckbox-BXkbvEGB.js";import"./VCheckboxBtn-gndQvl0N.js";import"./VTooltip-B2xVdDYJ.js";import"./VSpacer-Bt_rBx5Q.js";/* empty css              */import"./PanelviewItemCompact-BTMAfeVs.js";import"./Container-DwLI_eNo.js";import"./VContainer-Bwbf98oq.js";import"./Toolbar-CnjrHAL9.js";import"./VToolbar-Cw0gv67a.js";import"./VTextField-DVCLCsz9.js";import"./VInfiniteScroll-08LzEGPu.js";import"./layout-CXuYJmUE.js";import"./VRow-DsoK3S8F.js";import"./VVirtualScroll-Ds3B_Lds.js";import"./VAlert-DmQ6rEG3.js";import"./marquee_text_sync-D_EPQvtP.js";import"./VDialog-B4Ltljs_.js";const te=y({__name:"RadioDetails",props:{itemId:{},provider:{}},setup(n){const t=n,e=h(),l=async function(){e.value=await s.getRadio(t.itemId,t.provider)};I(()=>t.itemId,i=>{i&&l()},{immediate:!0});const d=async function(i){const r=[];if(t.provider=="library"){const o=await s.getRadioVersions(t.itemId,t.provider);r.push(...o)}for(const o of k(e.value)){const u=await s.getRadioVersions(o.item_id,o.provider_instance);r.push(...u)}return r};return(i,r)=>(a(),w("section",null,[V(f,{item:e.value},null,8,["item"]),e.value?(a(),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:i.$t("other_versions"),"hide-on-empty":!0,checksum:i.provider+i.itemId},null,8,["parent-item","title","checksum"])):p("",!0),r[0]||(r[0]=g("br",null,null,-1)),e.value?(a(),m(v,{key:1,"item-details":e.value},null,8,["item-details"])):p("",!0)]))}});export{te as default};
