diff --git a/lib/drawer/view/crossword_drawer.dart b/lib/drawer/view/crossword_drawer.dart index 5adf15d2..c0a0a54e 100644 --- a/lib/drawer/view/crossword_drawer.dart +++ b/lib/drawer/view/crossword_drawer.dart @@ -42,14 +42,12 @@ class CrosswordDrawer extends StatelessWidget { constraints: BoxConstraints( maxWidth: switch (layout) { IoLayoutData.small => 375, - IoLayoutData.large => 375, + IoLayoutData.large => 500, }, ), - child: SingleChildScrollView( - child: HowToPlayContent( - mascot: mascot, - onDonePressed: () => Navigator.pop(context), - ), + child: HowToPlayContent( + mascot: mascot, + onDonePressed: () => Navigator.pop(context), ), ), ), diff --git a/lib/how_to_play/widgets/how_to_play_content.dart b/lib/how_to_play/widgets/how_to_play_content.dart index b9361188..133c17ed 100644 --- a/lib/how_to_play/widgets/how_to_play_content.dart +++ b/lib/how_to_play/widgets/how_to_play_content.dart @@ -198,9 +198,10 @@ class HowToPlayStep extends StatelessWidget { final String image; - static const double smallTextHeight = 88; + static const double smallTextHeight = 136; + + static const double largeTextHeight = 104; - static const double largeTextHeight = 66; @override Widget build(BuildContext context) { final layout = IoLayout.of(context); @@ -210,9 +211,12 @@ class HowToPlayStep extends StatelessWidget { mainAxisSize: MainAxisSize.min, crossAxisAlignment: CrossAxisAlignment.start, children: [ - Text( - title, - style: Theme.of(context).io.textStyles.h2, + FittedBox( + fit: BoxFit.fitWidth, + child: Text( + title, + style: Theme.of(context).io.textStyles.h2, + ), ), const SizedBox(height: 24), Container( @@ -234,6 +238,7 @@ class HowToPlayStep extends StatelessWidget { child: Text( message, style: Theme.of(context).io.textStyles.body3, + textAlign: TextAlign.justify, ), ), ], diff --git a/test/how_to_play/view/how_to_play_page_test.dart b/test/how_to_play/view/how_to_play_page_test.dart index 73457782..d745ed19 100644 --- a/test/how_to_play/view/how_to_play_page_test.dart +++ b/test/how_to_play/view/how_to_play_page_test.dart @@ -317,7 +317,7 @@ void main() { assetsStatus: AssetsLoadingStatus.success, ), ); - await tester.pumpApp(widget); + await tester.pumpApp(widget, layout: IoLayoutData.large); await tester.tap(find.text(l10n.doneButtonLabel)); @@ -335,7 +335,11 @@ void main() { assetsStatus: AssetsLoadingStatus.success, ), ); - await tester.pumpApp(widget, user: User(id: 'userId')); + await tester.pumpApp( + widget, + user: User(id: 'userId'), + layout: IoLayoutData.large, + ); await tester.tap(find.text(l10n.doneButtonLabel));