Skip to content

Commit

Permalink
fix: add safe area to main bottom navigation bar
Browse files Browse the repository at this point in the history
  • Loading branch information
ice-ajax committed Dec 31, 2024
1 parent 1fc4ffd commit f766f4b
Showing 1 changed file with 16 additions and 17 deletions.
33 changes: 16 additions & 17 deletions lib/app/router/main_tabs/main_tab_navigation.dart
Original file line number Diff line number Diff line change
Expand Up @@ -93,25 +93,24 @@ class _BottomNavBarContent extends StatelessWidget {
),
],
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: TabItem.values.map((tabItem) {
final isSelected = currentTab == tabItem;
return Expanded(
child: GestureDetector(
behavior: HitTestBehavior.opaque,
onTap: () => onTabPressed(tabItem),
child: Container(
padding: EdgeInsets.only(
top: 9.0.s,
bottom: MediaQuery.of(context).padding.bottom > 0 ? 23.0.s : 9.0.s,
child: SafeArea(
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: TabItem.values.map((tabItem) {
final isSelected = currentTab == tabItem;
return Expanded(
child: GestureDetector(
behavior: HitTestBehavior.opaque,
onTap: () => onTabPressed(tabItem),
child: Container(
padding: EdgeInsets.symmetric(vertical: 9.0.s),
color: context.theme.appColors.secondaryBackground,
child: tabItem.getIcon(isSelected: isSelected),
),
color: context.theme.appColors.secondaryBackground,
child: tabItem.getIcon(isSelected: isSelected),
),
),
);
}).toList(),
);
}).toList(),
),
),
),
if (conversationsEditMode && currentTab == TabItem.chat) const ConversationEditBottomBar(),
Expand Down

0 comments on commit f766f4b

Please sign in to comment.