From b9d36190caff41764a2d724f605c2f89d3cfc4f8 Mon Sep 17 00:00:00 2001 From: mso7nueh Date: Fri, 15 Nov 2024 15:55:50 +0300 Subject: [PATCH] fix(feed): image constrains --- .../presentation/pages/blog_post_create_screen.dart | 13 ++++++++----- .../widgets/bottom_navigation_bar_widget.dart | 2 +- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/lib/features/blog_post_create/presentation/pages/blog_post_create_screen.dart b/lib/features/blog_post_create/presentation/pages/blog_post_create_screen.dart index d76b7bd4..74a83a25 100644 --- a/lib/features/blog_post_create/presentation/pages/blog_post_create_screen.dart +++ b/lib/features/blog_post_create/presentation/pages/blog_post_create_screen.dart @@ -168,11 +168,14 @@ class _BlogPostCreateScreenState extends State { width: shrinkImage ? 52 : MediaQuery.of(context).size.width - 32, curve: Curves.easeIn, duration: Duration(milliseconds: 150), - child: ClipRRect( - borderRadius: BorderRadius.circular(16), - child: Image( - image: FileImage( - File(state.image!.path), + child: ConstrainedBox( + constraints: BoxConstraints( + maxWidth: MediaQuery.of(context).size.width - 32, + ), + child: ClipRRect( + borderRadius: BorderRadius.circular(16), + child: Image( + image: FileImage(File(state.image!.path)), ), ), ), diff --git a/lib/features/bottom_navigation_bar/presentation/widgets/bottom_navigation_bar_widget.dart b/lib/features/bottom_navigation_bar/presentation/widgets/bottom_navigation_bar_widget.dart index ce8a8bca..787fe3c4 100644 --- a/lib/features/bottom_navigation_bar/presentation/widgets/bottom_navigation_bar_widget.dart +++ b/lib/features/bottom_navigation_bar/presentation/widgets/bottom_navigation_bar_widget.dart @@ -63,7 +63,7 @@ class _BottomNavigationBarWidgetState extends State { return Scaffold( body: widget.child, bottomNavigationBar: SizedBox( - height: 58, + height: 80, child: BottomNavigationBar( type: BottomNavigationBarType.fixed, onTap: _onItemTapped,