@@ -51,8 +51,6 @@
diff --git a/src/components/PlaylistView/ArtistsList.vue b/src/components/PlaylistView/ArtistsList.vue
index b912ece..4f422ec 100644
--- a/src/components/PlaylistView/ArtistsList.vue
+++ b/src/components/PlaylistView/ArtistsList.vue
@@ -28,6 +28,8 @@ defineProps<{
display: flex;
justify-content: space-between;
padding-left: $medium;
+ align-items: center;
+ margin-bottom: $small;
.see-all {
font-size: $medium;
diff --git a/src/components/nav/NavBar.vue b/src/components/nav/NavBar.vue
index b9ee919..fea7f3c 100644
--- a/src/components/nav/NavBar.vue
+++ b/src/components/nav/NavBar.vue
@@ -4,10 +4,6 @@
-
([]);
diff --git a/src/components/nav/Titles/APTitle.vue b/src/components/nav/Titles/APTitle.vue
deleted file mode 100644
index 79827d0..0000000
--- a/src/components/nav/Titles/APTitle.vue
+++ /dev/null
@@ -1,86 +0,0 @@
-
-
-
-
-
- {{ things.text }}
-
-
-
-
-
-
-
-
-
diff --git a/src/composables/favoriteHandler.ts b/src/composables/favoriteHandler.ts
index a0df540..bff1b97 100644
--- a/src/composables/favoriteHandler.ts
+++ b/src/composables/favoriteHandler.ts
@@ -1,31 +1,25 @@
-import { Ref } from "vue";
import { favType } from "./enums";
import { addFavorite, removeFavorite } from "./fetch/favorite";
/**
* Handles the favorite state of an item.
- * @param flag The ref to track the is_favorite state
+ * @param setter The ref to track the is_favorite state
* @param type The type of item
* @param itemhash The hash of the item
*/
export default async function favoriteHandler(
- flag: Ref,
+ flag: boolean | undefined,
type: favType,
- itemhash: string
+ itemhash: string,
+ setter: () => void,
+ remover: () => void
) {
- if (flag.value) {
+ if (flag) {
const removed = await removeFavorite(type, itemhash);
-
- if (removed) {
- flag.value = false;
- }
-
+ if (removed) remover();
return;
}
const added = await addFavorite(type, itemhash);
-
- if (added) {
- flag.value = true;
- }
+ if (added) setter();
}
diff --git a/src/stores/pages/album.ts b/src/stores/pages/album.ts
index 2dd9de1..dc5f598 100644
--- a/src/stores/pages/album.ts
+++ b/src/stores/pages/album.ts
@@ -64,7 +64,6 @@ export default defineStore("album", {
this.srcTracks.forEach((t, index) => {
t.master_index = index;
- console.log(t.disc, t.track);
});
},
async fetchArtistAlbums() {
@@ -84,6 +83,12 @@ export default defineStore("album", {
resetAlbumArtists() {
this.albumArtists = [];
},
+ makeFavorite() {
+ this.info.is_favorite = true;
+ },
+ removeFavorite() {
+ this.info.is_favorite = false;
+ },
},
getters: {
discs(): Disc {
diff --git a/src/stores/pages/artist.ts b/src/stores/pages/artist.ts
index 9323089..587f0d2 100644
--- a/src/stores/pages/artist.ts
+++ b/src/stores/pages/artist.ts
@@ -50,5 +50,11 @@ export default defineStore("artistPage", {
this.eps = [];
this.singles = [];
},
+ makeFavorite() {
+ this.info.is_favorite = true;
+ },
+ removeFavorite() {
+ this.info.is_favorite = false;
+ },
},
});
diff --git a/src/views/AlbumView/index.vue b/src/views/AlbumView/index.vue
index 98108cb..d1a6c2f 100644
--- a/src/views/AlbumView/index.vue
+++ b/src/views/AlbumView/index.vue
@@ -94,6 +94,7 @@ function getArtistAlbumComponents(): ScrollerItem[] {
albums: ar.albums,
title: `More from ${artistname}`,
albumType: discographyAlbumTypes.all,
+ route: `/artists/${artisthash}/discography`
},
size: 20 * 16,
};
@@ -104,9 +105,6 @@ const scrollerItems = computed(() => {
const header: ScrollerItem = {
id: "album-header",
component: Header,
- props: {
- album: album.info,
- },
size: 19 * 16,
};