added border radius to overlays

This commit is contained in:
Vadim 2022-10-29 14:06:39 +03:00
parent 3c1f803e25
commit 2300c828b1
2 changed files with 105 additions and 93 deletions

View file

@ -18,12 +18,17 @@ class MeteringBottomControls extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return ColoredBox( return ClipRRect(
borderRadius: const BorderRadius.only(
topLeft: Radius.circular(Dimens.borderRadiusL),
topRight: Radius.circular(Dimens.borderRadiusL),
),
child: ColoredBox(
color: Theme.of(context).colorScheme.surface, color: Theme.of(context).colorScheme.surface,
child: SafeArea( child: SafeArea(
top: false, top: false,
child: Padding( child: Padding(
padding: const EdgeInsets.all(Dimens.paddingM), padding: const EdgeInsets.symmetric(vertical: Dimens.paddingM),
child: Row( child: Row(
mainAxisAlignment: MainAxisAlignment.spaceEvenly, mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: [ children: [
@ -42,6 +47,7 @@ class MeteringBottomControls extends StatelessWidget {
), ),
), ),
), ),
),
); );
} }
} }

View file

@ -22,7 +22,12 @@ class MeteringTopBar extends StatelessWidget {
Widget build(BuildContext context) { Widget build(BuildContext context) {
final columnWidth = final columnWidth =
(MediaQuery.of(context).size.width - Dimens.paddingM * 2 - Dimens.grid16 * (_columnsCount - 1)) / 3; (MediaQuery.of(context).size.width - Dimens.paddingM * 2 - Dimens.grid16 * (_columnsCount - 1)) / 3;
return ColoredBox( return ClipRRect(
borderRadius: const BorderRadius.only(
bottomLeft: Radius.circular(Dimens.borderRadiusL),
bottomRight: Radius.circular(Dimens.borderRadiusL),
),
child: ColoredBox(
color: Theme.of(context).colorScheme.surface, color: Theme.of(context).colorScheme.surface,
child: Padding( child: Padding(
padding: const EdgeInsets.all(Dimens.paddingM), padding: const EdgeInsets.all(Dimens.paddingM),
@ -104,6 +109,7 @@ class MeteringTopBar extends StatelessWidget {
), ),
), ),
), ),
),
); );
} }
} }