-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c7b866f
commit 655d7e0
Showing
5 changed files
with
93 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,63 @@ | ||
import 'package:dog_gromming_website/ui/styles/insets.dart'; | ||
import 'package:dog_gromming_website/ui/styles/sizes.dart'; | ||
import 'package:dog_gromming_website/ui/styles/spacing.dart'; | ||
import 'package:dog_gromming_website/ui/widgets/components/box_spacer.dart'; | ||
import 'package:dog_gromming_website/ui/widgets/components/cards/outlined_card.dart'; | ||
import 'package:dog_gromming_website/ui/widgets/components/logo.dart'; | ||
import 'package:easy_localization/easy_localization.dart'; | ||
import 'package:flutter/material.dart'; | ||
import 'package:flutter/widgets.dart'; | ||
|
||
class AboutScreen extends StatelessWidget { | ||
const AboutScreen({super.key}); | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Text('menu.about'.tr()); | ||
final cards = <Widget>[ | ||
OutlinedCard( | ||
description: 'about.company.description'.tr(), | ||
titleWidget: Logo.text( | ||
semanticLabel: 'about.company.semantic_label'.tr(), | ||
height: 24, | ||
), | ||
), | ||
OutlinedCard( | ||
title: 'about.owner.title'.tr(), | ||
description: 'about.owner.description'.tr(), | ||
), | ||
]; | ||
return Padding( | ||
padding: Insets.a16, | ||
child: LayoutBuilder( | ||
builder: (context, constraints) { | ||
return Sizes.s.width > constraints.maxWidth | ||
? GridView.extent( | ||
maxCrossAxisExtent: 550, | ||
crossAxisSpacing: Spacing.sp16, | ||
mainAxisSpacing: Spacing.sp16, | ||
children: cards, | ||
) | ||
: Row( | ||
crossAxisAlignment: CrossAxisAlignment.start, | ||
children: [ | ||
Flexible( | ||
child: FractionallySizedBox( | ||
heightFactor: | ||
Sizes.xs.width < constraints.maxHeight ? 0.5 : 1, | ||
child: cards.first, | ||
), | ||
), | ||
BoxSpacer.h24(), | ||
Flexible( | ||
child: FractionallySizedBox( | ||
heightFactor: | ||
Sizes.xs.width < constraints.maxHeight ? 0.5 : 1, | ||
child: cards.last, | ||
), | ||
), | ||
], | ||
); | ||
}, | ||
), | ||
); | ||
} | ||
} |