flutter - 在底部导航栏上添加行
问题描述
我想在底部导航栏上添加这种类型的线我想要this type of blue lines when navigate or tap to another tab
这是我的代码
BottomNavigationBar( //Bottom navigation bar
onTap: onTabTapped,
showSelectedLabels: true,
currentIndex: _currentIndex,
items: [
BottomNavigationBarItem( //Items of BottomNavigation Bar
icon: Image.asset(
unSelectedTabs[0],
width: iconSize,
height: iconSize,
),
title:
Text("Home", style: TextStyle(color: _currentIndex == 0 ? AppTheme.mainThemeColor() : AppTheme.hintTextColor())),
activeIcon: Image.asset(
selectedTabs[0],
width: iconSize,
height: iconSize,
),
),
.........
other childItem
请帮助找出这个
解决方案
这个包应该可以帮助你实现这一点。您可能只需要根据需要对其进行自定义。
推荐阅读
- ansible - Ansible:仅在上一个任务成功并创建输出时才触发任务
- vba - 使用带有 introp 的 CefSharp 嵌入 Microsoft Access 表单
- javascript - 什么是 .cshtml 文件中的“this”关键字以及如何在 .js 文件中使用 .cshtml 代码
- sockets - tmux 服务器不使用 /tmp/tmux-
/默认,不能列出也不能附加会话 - python - 使用 GeoPy 时的打印问题
- c# - C#如何在mvc restapi的url中将List作为参数发送?
- java - 如何让 for 循环打印总的东西而不是每个单独的组件?
- c# - HttpClient and long running Windows Services - What is the potential for thread deadlock and how to circumvent it
- javascript - 通过 API 上传图片到 imgur - Javascript
- reactjs - 如何在反应中使用 react-jsonschema-form?