diff --git a/lib/src/localization/app_localizations.dart b/lib/src/localization/app_localizations.dart index c3a351e..2112a3d 100644 --- a/lib/src/localization/app_localizations.dart +++ b/lib/src/localization/app_localizations.dart @@ -63,7 +63,7 @@ import 'app_localizations_ru.dart'; /// property. abstract class AppLocalizations { AppLocalizations(String locale) - : localeName = intl.Intl.canonicalizedLocale(locale.toString()); + : localeName = intl.Intl.canonicalizedLocale(locale.toString()); final String localeName; @@ -86,16 +86,16 @@ abstract class AppLocalizations { /// of delegates is preferred or required. static const List> localizationsDelegates = >[ - delegate, - GlobalMaterialLocalizations.delegate, - GlobalCupertinoLocalizations.delegate, - GlobalWidgetsLocalizations.delegate, - ]; + delegate, + GlobalMaterialLocalizations.delegate, + GlobalCupertinoLocalizations.delegate, + GlobalWidgetsLocalizations.delegate, + ]; /// A list of this localizations delegate's supported locales. static const List supportedLocales = [ Locale('en'), - Locale('ru'), + Locale('ru') ]; /// The title of the application @@ -132,9 +132,8 @@ AppLocalizations lookupAppLocalizations(Locale locale) { } throw FlutterError( - 'AppLocalizations.delegate failed to load unsupported locale "$locale". This is likely ' - 'an issue with the localizations generation tool. Please file an issue ' - 'on GitHub with a reproducible sample app and the gen-l10n configuration ' - 'that was used.', - ); + 'AppLocalizations.delegate failed to load unsupported locale "$locale". This is likely ' + 'an issue with the localizations generation tool. Please file an issue ' + 'on GitHub with a reproducible sample app and the gen-l10n configuration ' + 'that was used.'); } diff --git a/lib/src/screens/foreground_switch_screen/paste_code_screen.dart b/lib/src/screens/foreground_switch_screen/paste_code_screen.dart index f9f91af..38d0974 100644 --- a/lib/src/screens/foreground_switch_screen/paste_code_screen.dart +++ b/lib/src/screens/foreground_switch_screen/paste_code_screen.dart @@ -20,31 +20,33 @@ class _PasteCodeScreenState extends State { @override Widget build(BuildContext context) { - return Column( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - Padding( - padding: const EdgeInsets.symmetric(horizontal: 57.0), - child: WaveText( - 'Copy your friend’s code and paste it to the text input below:', - type: WaveTextType.caption, - maxLines: 3, - textAlign: TextAlign.center, + return SafeArea( + child: Column( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Padding( + padding: const EdgeInsets.symmetric(horizontal: 57.0), + child: WaveText( + 'Copy your friend’s code and paste it to the text input below:', + type: WaveTextType.caption, + maxLines: 3, + textAlign: TextAlign.center, + ), ), - ), - SizedBox(height: 27), - Padding( - padding: const EdgeInsets.symmetric(horizontal: 40.0), - child: TextField( - controller: _codeController, + SizedBox(height: 27), + Padding( + padding: const EdgeInsets.symmetric(horizontal: 40.0), + child: TextField( + controller: _codeController, + ), ), - ), - SizedBox(height: 135), - WaveSimpleButton( - label: 'Connect', - onPressed: _onAcceptOfferPressed, - ), - ], + SizedBox(height: 135), + WaveSimpleButton( + label: 'Connect', + onPressed: _onAcceptOfferPressed, + ), + ], + ), ); } diff --git a/lib/src/widgets/animated_container_wrapper.dart b/lib/src/widgets/animated_container_wrapper.dart index 3e2f43c..483ee3a 100644 --- a/lib/src/widgets/animated_container_wrapper.dart +++ b/lib/src/widgets/animated_container_wrapper.dart @@ -7,7 +7,8 @@ class AnimatedContainerWrapper extends StatefulWidget { super.key, this.purpleTitle, required this.child, - required this.isAnimated, required this.topPadding, + required this.isAnimated, + required this.topPadding, }); final String? purpleTitle; diff --git a/lib/src/widgets/dynamic_container_wrapper.dart b/lib/src/widgets/dynamic_container_wrapper.dart index 50f3e4f..e90fb3d 100644 --- a/lib/src/widgets/dynamic_container_wrapper.dart +++ b/lib/src/widgets/dynamic_container_wrapper.dart @@ -54,6 +54,7 @@ class _DynamicContainerWrapperState extends State @override Widget build(BuildContext context) { final topPadding = widget.topPadding; + final bottomInset = MediaQuery.of(context).padding.bottom; return LayoutBuilder( builder: (context, constraints) { @@ -68,6 +69,16 @@ class _DynamicContainerWrapperState extends State return Stack( children: [ + if (widget.isNavBarShowed) + Positioned( + left: 0, + right: 0, + bottom: 0, + child: ColoredBox( + color: MdColors.navBarContainerColor, + child: SizedBox(height: bottomInset), + ), + ), // Подложка контента Padding( padding: const EdgeInsets.symmetric(horizontal: 20.0), @@ -77,7 +88,7 @@ class _DynamicContainerWrapperState extends State height: widget.isNavBarShowed ? !isChatTab ? h - 95 - : h + : h - (95 + bottomInset) : h, decoration: BoxDecoration( borderRadius: BorderRadius.only(