import{I as p}from"./ItemsListing-CqOkN5bP.js";import{I as c,_ as f}from"./ProviderDetails.vue_vue_type_script_setup_true_lang-BaDwFhok.js";import{d as y,i as k,ad as b,c as w,b as h,e as s,q as m,a as n,u as I,m as o,o as l}from"./index-BLuBzgcR.js";import"./Container-BVutxj42.js";import"./index-CBho6rsP.js";import"./VContainer-DOe7JF0h.js";/* empty css              */import"./_plugin-vue_export-helper-DlAUqK2U.js";import"./Toolbar-RSDUeNZR.js";import"./VToolbar-BFOvSQM-.js";import"./VBtn-i8gedOhv.js";import"./Button-BEhYIX-0.js";import"./ListItem-D3UfOTqB.js";import"./NowPlayingBadge.vue_vue_type_style_index_0_lang-Dwz4QKKd.js";import"./VInput-S8c2HXsf.js";import"./MediaItemThumb-4FqrTjbr.js";import"./PanelviewItemCompact-Czo8xJLH.js";import"./VSpacer-FdmIBMIx.js";import"./VTextField-BRzkPyuL.js";import"./VInfiniteScroll-XtiIpwbc.js";import"./layout-Dtt5lK8k.js";import"./VRow-Dw7kUaJt.js";import"./VVirtualScroll-JP5E3DQw.js";import"./VAlert-Du-laR0E.js";import"./marquee_text_sync-CbqHGytl.js";import"./VDialog-CUNnqGJy.js";const U=y({__name:"TrackDetails",props:{itemId:{},provider:{},album:{}},setup(r){const a=r,e=k(),u=async function(){e.value=await o.getTrack(a.itemId,a.provider,a.album)};b(()=>a.itemId,t=>{t&&u()},{immediate:!0});const d=async function(t){return await o.getTrackVersions(e.value.item_id,e.value.provider)},v=async function(t){return await o.getTrackAlbums(a.itemId,a.provider,t.libraryOnly)};return(t,i)=>(l(),w("section",null,[h(c,{item:e.value,"active-provider":r.provider},null,8,["item","active-provider"]),e.value?(l(),s(p,{key:0,itemtype:"trackalbums","parent-item":e.value,"show-provider":!0,"show-favorites-only-filter":!1,"show-library-only-filter":e.value.provider=="library"&&I(o).hasStreamingProviders.value,"show-track-number":!1,"show-refresh-button":!1,"load-items":v,"sort-keys":["name","sort_name","year","year_desc"],title:t.$t("appears_on"),path:r.provider+r.itemId,"allow-collapse":!0},null,8,["parent-item","show-library-only-filter","title","path"])):m("",!0),i[0]||(i[0]=n("br",null,null,-1)),e.value?(l(),s(p,{key:1,itemtype:"trackversions","parent-item":e.value,"show-provider":!0,"show-favorites-only-filter":!1,"show-track-number":!1,"load-items":d,"show-refresh-button":!1,"sort-keys":["name","sort_name","duration"],title:t.$t("other_versions"),"hide-on-empty":!0,path:r.provider+r.itemId,"allow-collapse":!0},null,8,["parent-item","title","path"])):m("",!0),i[1]||(i[1]=n("br",null,null,-1)),e.value?(l(),s(f,{key:2,"item-details":e.value},null,8,["item-details"])):m("",!0),i[2]||(i[2]=n("br",null,null,-1))]))}});export{U as default};
