mirror of
https://github.com/KevinMidboe/immich.git
synced 2025-10-29 17:40:28 +00:00
fix(mobile): images rendered twice due to rebuild (#4060)
* fix(mobile): images rendered twice due to rebuild * fix bottom sheet triggered multiple times
This commit is contained in:
committed by
GitHub
parent
d023d5b6b4
commit
bd226e9e2c
@@ -64,9 +64,8 @@ class GalleryViewerPage extends HookConsumerWidget {
|
||||
final authToken = 'Bearer ${Store.get(StoreKey.accessToken)}';
|
||||
final currentIndex = useState(initialIndex);
|
||||
final currentAsset = loadAsset(currentIndex.value);
|
||||
final watchedAsset = ref.watch(assetDetailProvider(currentAsset));
|
||||
|
||||
Asset asset() => watchedAsset.value ?? currentAsset;
|
||||
Asset asset() => currentAsset;
|
||||
|
||||
useEffect(
|
||||
() {
|
||||
@@ -194,7 +193,7 @@ class GalleryViewerPage extends HookConsumerWidget {
|
||||
padding: EdgeInsets.only(
|
||||
bottom: MediaQuery.of(context).viewInsets.bottom,
|
||||
),
|
||||
child: ExifBottomSheet(asset: asset()),
|
||||
child: ExifBottomSheet(asset: currentAsset),
|
||||
);
|
||||
},
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user