feat: sparse-map pagination for library browse

This commit is contained in:
edde746
2026-02-25 18:14:48 +01:00
parent 6188d21c3d
commit 728c4854a5
5 changed files with 317 additions and 131 deletions
+2 -2
View File
@@ -524,7 +524,7 @@ class _LibrariesScreenState extends State<LibrariesScreen>
) async {
while (_hasMoreItems && requestId == _requestId) {
try {
final items = await client.getLibraryContent(
final result = await client.getLibraryContent(
library.key,
start: _currentPage * _pageSize,
size: _pageSize,
@@ -533,7 +533,7 @@ class _LibrariesScreenState extends State<LibrariesScreen>
);
// Tag items with server info for multi-server support
final taggedItems = items
final taggedItems = result.items
.map((item) => item.copyWith(serverId: library.serverId, serverName: library.serverName))
.toList();