show modal barrier when displaying sheet

This commit is contained in:
Fabian Freund
2024-06-26 14:54:06 +02:00
parent 8ea00bfb0d
commit 5aad8446bb
@@ -334,10 +334,13 @@ class KagiScreen extends HookConsumerWidget {
return true;
}
},
child: SafeArea(
child: Stack(
children: [
SafeArea(
child: AnimatedIndexedStack(
duration: const Duration(milliseconds: 250),
transitionBuilder: (child, animation, secondaryAnimation) =>
transitionBuilder:
(child, animation, secondaryAnimation) =>
SharedAxisTransition(
animation: animation,
secondaryAnimation: secondaryAnimation,
@@ -360,6 +363,13 @@ class KagiScreen extends HookConsumerWidget {
children: [const LandingContent(), ...webViews.values],
),
),
if (displayedSheet != null)
ModalBarrier(
color: Theme.of(context).dialogTheme.barrierColor ??
Colors.black54,
),
],
),
);
},
),