Fixes pageview close button moving with pages

This commit is contained in:
Marty Fuhry 2024-01-31 09:56:17 -05:00
parent 0c36eb1f8b
commit bfab33f9d4
No known key found for this signature in database
GPG Key ID: E2AB6392D894D900

View File

@ -222,7 +222,9 @@ class MemoryPage extends HookConsumerWidget {
}, },
), ),
Expanded( Expanded(
child: PageView.builder( child: Stack(
children: [
PageView.builder(
physics: const BouncingScrollPhysics( physics: const BouncingScrollPhysics(
parent: AlwaysScrollableScrollPhysics(), parent: AlwaysScrollableScrollPhysics(),
), ),
@ -232,9 +234,7 @@ class MemoryPage extends HookConsumerWidget {
itemCount: memories[mIndex].assets.length, itemCount: memories[mIndex].assets.length,
itemBuilder: (context, index) { itemBuilder: (context, index) {
final asset = memories[mIndex].assets[index]; final asset = memories[mIndex].assets[index];
return Stack( return Container(
children: [
Container(
color: Colors.black, color: Colors.black,
child: MemoryCard( child: MemoryCard(
asset: asset, asset: asset,
@ -242,6 +242,8 @@ class MemoryPage extends HookConsumerWidget {
title: memories[mIndex].title, title: memories[mIndex].title,
showTitle: index == 0, showTitle: index == 0,
), ),
);
},
), ),
Positioned( Positioned(
top: 8, top: 8,
@ -267,8 +269,6 @@ class MemoryPage extends HookConsumerWidget {
), ),
), ),
], ],
);
},
), ),
), ),
MemoryBottomInfo(memory: memories[mIndex]), MemoryBottomInfo(memory: memories[mIndex]),