小编alX*_*X-U的帖子

如何更改 Flutter 中 BottomNavigationBarItem 中标签的颜色?

我正在应用程序的菜单中放置一些底部导航栏项目,我希望它们有一些标签。我贴了标签,但我真的不知道如何更改它们的基色。就像我希望他们都是白色的。

\n

这是其中之一的代码:

\n
bottomNavigationBar: BottomNavigationBar(\n      unselectedLabelStyle: const TextStyle(color: Colors.white, fontSize: 14),\n      backgroundColor: const Color(0xFF084A76),\n      fixedColor: Colors.white,\n      items: [\n        BottomNavigationBarItem(\n            icon: InkWell(\n              onTap: () async {\n                //Borramos un lote\n                deleteLote();\n              },\n              child: Container(\n                height: 47,\n                width: 50,\n                decoration: const BoxDecoration(\n                    shape: BoxShape.circle, color: Colors.black38),\n                child: const Icon(\n                  Icons.delete,\n                  size: 32,\n                  color: Colors.white,\n                ),\n              ),\n            ),\n            label: \'Borrar Lote\'),\n        BottomNavigationBarItem(\n            icon: InkWell(\n              onTap: () async {\n                //A\xc3\xb1adimos un lote\n                addLote();\n              },\n              child: Container(\n                height: 47,\n                width: 50,\n                decoration: const BoxDecoration(\n                    shape: …
Run Code Online (Sandbox Code Playgroud)

dart flutter

7
推荐指数
2
解决办法
2万
查看次数

标签 统计

dart ×1

flutter ×1