import{_ as d}from"./ArtistIcon.vue_vue_type_script_setup_true_lang-BTe3Pg5C.js";import{I as p}from"./ItemsListing-BhojFO3C.js";import{s,a as o,E as m}from"./index-ByIRZxAe.js";import{d as c,r as a,o as f,a0 as v,D as _,e as y}from"./lucide-F1B1VpI-.js";import"./Container-DnmqEBzf.js";import"./index-kQIztB-E.js";import"./vuetify-BRgYuWPG.js";import"./Toolbar-DIp8eCDU.js";import"./userPreferences-Bu5gMiKh.js";import"./vue-router-BpTQq1WE.js";import"./Button-9Ou4QCZy.js";import"./ListItem-oNWk925d.js";import"./NowPlayingBadge.vue_vue_type_style_index_0_lang-CzKuoqNh.js";import"./MediaItemThumb-BeA2xE_0.js";import"./ProviderIcon.vue_vue_type_style_index_0_lang-B65iU32Z.js";import"./vue-i18n-fACdQrNQ.js";import"./PanelviewItemCompact-BMq7Iucl.js";import"./color-CcshWhNz.js";import"./qrcode-0NlyE7mq.js";import"./marked-i_gIkIP3.js";import"./vueuse-D-YfxAQp.js";/* empty css            */import"./swiper-Bthg8aDK.js";const G=c({name:"Artists",__name:"LibraryArtists",setup(b){const r=a(!1),e=a(s.libraryArtistsCount),l=["name","name_desc","sort_name","sort_name_desc","timestamp_added","timestamp_added_desc","last_played","last_played_desc","play_count","play_count_desc"],n=async function(t){return r.value=!1,u(t),await o.getLibraryArtists(t.favoritesOnly||void 0,t.search,t.limit,t.offset,t.sortBy,t.albumArtistsFilter,t.provider&&t.provider.length>0?t.provider:void 0,t.genreIds)},u=async function(t){if(!t.favoritesOnly&&!t.albumArtistsFilter&&!t.provider){e.value=s.libraryArtistsCount;return}if(t.provider&&t.provider.length>0){e.value=void 0;return}e.value=await o.getLibraryArtistsCount(t.favoritesOnly||!1,t.albumArtistsFilter||!1)};return f(()=>{const t=o.subscribe(m.MEDIA_ITEM_ADDED,i=>{i.object_id?.startsWith("library://artist")&&(r.value=!0)});v(t)}),(t,i)=>(y(),_(p,{itemtype:"artists",path:"libraryartists","show-provider":!1,"show-favorites-only-filter":!0,"load-paged-data":n,"show-album-artists-only-filter":!0,"update-available":r.value,title:t.$t("artists"),"allow-key-hooks":!0,"show-search-button":!0,"show-genre-filter":!0,"sort-keys":l,icon:d,"restore-state":!0,total:e.value,"show-provider-filter":!0},null,8,["update-available","title","total"]))}});export{G as default};
