add collections tab for book libraries

This commit is contained in:
dkanada
2026-05-22 00:11:24 +09:00
parent a47f663575
commit c75d0b3390
2 changed files with 15 additions and 1 deletions
@@ -70,6 +70,11 @@ export const LibraryRoutes: LibraryRoute[] = [
},
{
index: 5,
label: 'Collections',
view: LibraryTab.Collections
},
{
index: 6,
label: 'Favorites',
view: LibraryTab.Favorites
}
+10 -1
View File
@@ -38,6 +38,14 @@ const genresTabContent: LibraryTabContent = {
itemType: [BaseItemKind.AudioBook, BaseItemKind.Book]
};
const collectionsTabContent: LibraryTabContent = {
viewType: LibraryTab.Collections,
collectionType: CollectionType.Books,
itemType: [BaseItemKind.BoxSet],
isBtnNewCollectionEnabled: true,
noItemsMessage: 'MessageNoCollectionsAvailable'
};
const favoritesTabContent: LibraryTabContent = {
viewType: LibraryTab.Favorites,
collectionType: CollectionType.Books,
@@ -50,7 +58,8 @@ const booksTabMapping: LibraryTabMapping = {
2: authorsTabContent,
3: suggestionsTabContent,
4: genresTabContent,
5: favoritesTabContent
5: collectionsTabContent,
6: favoritesTabContent
};
const Books: FC = () => {