feat: UI 2.0 and other Improvements (#357)

Co-authored-by: PartyDonut <PartyDonut@users.noreply.github.com>
This commit is contained in:
PartyDonut 2025-06-01 10:37:19 +02:00 committed by GitHub
parent 9ca06eaa37
commit e7b5bb40ff
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
169 changed files with 4584 additions and 3626 deletions

View file

@ -32,8 +32,8 @@ class ViewsNotifier extends StateNotifier<ViewsModel> {
late final JellyService api = ref.read(jellyApiProvider);
Future<void> fetchViews() async {
if (state.loading) return;
Future<ViewsModel?> fetchViews() async {
if (state.loading) return null;
final showAllCollections = ref.read(clientSettingsProvider.select((value) => value.showAllCollectionTypes));
final response = await api.usersUserIdViewsGet(
includeExternalContent: showAllCollections,
@ -64,6 +64,7 @@ class ViewsNotifier extends StateNotifier<ViewsModel> {
ItemFields.mediasources,
ItemFields.candelete,
ItemFields.candownload,
ItemFields.primaryimageaspectratio,
],
);
return e.copyWith(recentlyAdded: recents.body?.map((e) => ItemBaseModel.fromBaseDto(e, ref)).toList());
@ -76,6 +77,7 @@ class ViewsNotifier extends StateNotifier<ViewsModel> {
.where((element) => !(ref.read(userProvider)?.latestItemsExcludes.contains(element.id) ?? true))
.toList(),
loading: false);
return state;
}
void clear() {