import{I as c}from"./ItemsListing-BGUL9QyB.js";import{I as f,_ as v}from"./ProviderDetails.vue_vue_type_script_setup_true_lang-Bf7qdK33.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-CFvoaD7J.js";import"./ItemContextMenu.vue_vue_type_style_index_0_scoped_4409cede_lang-41DbVClm.js";import"./ProviderIcon.vue_vue_type_script_setup_true_lang-Ji67J6Pu.js";import"./VListItem-CSPID7yq.js";import"./VChip-Ccz1-bmn.js";import"./VList-fGk9SRdf.js";import"./VCardText-CpOuj25H.js";import"./VCard-DxLPF-Ra.js";import"./VMenu-9pSrU4Fo.js";import"./_plugin-vue_export-helper-DlAUqK2U.js";import"./eventbus-CGRXT3Tn.js";import"./ListItem-nYGtvGaY.js";import"./VCheckbox-B5r7QKHZ.js";import"./VCheckboxBtn-CRgZyCzV.js";import"./VTooltip-DC73AT2B.js";import"./VSpacer-UYEiyhN7.js";/* empty css              */import"./PanelviewItemCompact-BQIsDE0n.js";import"./Container-BDz3QMuX.js";import"./VContainer-CzfHAKpA.js";import"./Toolbar-DNen7a-V.js";import"./VToolbar-Da4d1W_R.js";import"./VTextField-DF4u_eMy.js";import"./VInfiniteScroll-D1yVLjQf.js";import"./layout-BeGdxe2Y.js";import"./VRow-BC1No8oB.js";import"./VVirtualScroll-BDBVEoUv.js";import"./VAlert-CIiIOQza.js";import"./marquee_text_sync-k18A2BIX.js";import"./VDialog-CdvGeqlS.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};
