web bugs fixed

This commit is contained in:
MohammadTaha Basiri 2022-03-10 14:34:29 +03:30
parent cd5b17f60d
commit c47fbac5fe
2 changed files with 7 additions and 3 deletions

View File

@ -170,7 +170,11 @@ class RouteGenerator {
final shortestSide = MediaQuery.of(context).size.shortestSide; final shortestSide = MediaQuery.of(context).size.shortestSide;
final bool useMobileLayout = shortestSide < 600; final bool useMobileLayout = shortestSide < 600;
if (kIsWeb && !useMobileLayout) { if (kIsWeb && !useMobileLayout) {
return Center(child: AspectRatio(aspectRatio: 9 / 16, child: page)); return Container(
color: Theme.of(context).colorScheme.background,
alignment: Alignment.center,
child: AspectRatio(aspectRatio: 9 / 16, child: page),
);
} }
return Container( return Container(
color: Theme.of(context).colorScheme.surface, color: Theme.of(context).colorScheme.surface,

View File

@ -66,10 +66,10 @@ class CategoryItem extends StatelessWidget {
isVisible: !isColapsed, isVisible: !isColapsed,
child: Container( child: Container(
width: !_useWebMobileLayout(context) width: !_useWebMobileLayout(context)
? _width(context) / 1.75 ? _width(context) / 2
: ds.width / 5, : ds.width / 5,
height: !_useWebMobileLayout(context) height: !_useWebMobileLayout(context)
? _width(context) / 1.75 ? _width(context) / 2
: ds.width / 5, : ds.width / 5,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Theme.of(context).colorScheme.surface, color: Theme.of(context).colorScheme.surface,