import{_ as l}from"./ItemsListing.vue_vue_type_style_index_0_lang-cfe67ae4.js";import{_ as d,a as v}from"./ProviderDetails.vue_vue_type_script_setup_true_lang-6ac061a5.js";import{v as f,r as y,w as _,y as i,E as b,l as h,z as a,x as k,I as o,B as m,L as s,ap as w}from"./index-5804982a.js";import"./ListviewItem-8b7ae6a6.js";import"./VBadge-3d00ada8.js";import"./Container-d5ee1f41.js";import"./forwardRefs-03519353.js";import"./VMenu-18f2572a.js";/* empty css              */import"./VInput-fe7a35fc.js";import"./VSlideGroup-711de993.js";import"./VCard-cc8044ef.js";import"./VCardText-963b2439.js";import"./VTooltip-5622a67d.js";import"./PanelviewItem.vue_vue_type_style_index_0_lang-04756f0a.js";import"./contextmenu-95007cdc.js";import"./Alert-38a1b933.js";import"./VAlert-8600f5db.js";import"./VToolbar-ce6590ba.js";import"./VTextField-b58cde95.js";import"./VVirtualScroll-72995e2a.js";import"./layout-b05dbcdd.js";import"./VDialog-c56f60de.js";const g=m("br",null,null,-1),A=m("br",null,null,-1),R=f({__name:"AlbumDetails",props:{itemId:{},provider:{}},setup(n){const r=n,e=y(),p=async function(){e.value=await s.getAlbum(r.itemId,r.provider)};_(()=>r.itemId,t=>{t&&p()},{immediate:!0});const u=async function(t){return await s.getAlbumTracks(r.itemId,r.provider,t.libraryOnly)},c=async function(t){return await s.getAlbumVersions(e.value.item_id,e.value.provider)};return(t,I)=>(i(),b("section",null,[h(d,{item:e.value,"active-provider":t.provider},null,8,["item","active-provider"]),e.value?(i(),a(l,{key:0,itemtype:"albumtracks","parent-item":e.value,"show-provider":!0,"show-favorites-only-filter":!0,"show-library-only-filter":e.value.provider=="library"&&k(w)(e.value).length>0,"show-refresh-button":!1,"load-items":u,"sort-keys":["track_number","name","duration"],title:t.$t("tracks")},null,8,["parent-item","show-library-only-filter","title"])):o("",!0),g,e.value?(i(),a(l,{key:1,itemtype:"albumversions","parent-item":e.value,"show-provider":!0,"show-favorites-only-filter":!1,"show-refresh-button":!1,"load-items":c,"sort-keys":["provider","name","year"],title:t.$t("other_versions"),"hide-on-empty":!0},null,8,["parent-item","title"])):o("",!0),A,e.value?(i(),a(v,{key:2,"item-details":e.value},null,8,["item-details"])):o("",!0)]))}});export{R as default};
