fix(mobile): stack count reset when navigating to library (#4647)

Co-authored-by: shalong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
This commit is contained in:
shenlong
2023-10-26 14:19:06 +00:00
committed by GitHub
parent cb0e37e76e
commit b49b10141e
9 changed files with 52 additions and 23 deletions

View File

@@ -83,7 +83,7 @@ class GalleryViewerPage extends HookConsumerWidget {
navStack.length > 2 &&
navStack.elementAt(navStack.length - 2).name == TrashRoute.name;
final stackIndex = useState(-1);
final stack = showStack && currentAsset.stackCount > 0
final stack = showStack && currentAsset.stackChildrenCount > 0
? ref.watch(assetStackStateProvider(currentAsset))
: <Asset>[];
final stackElements = showStack ? [currentAsset, ...stack] : <Asset>[];