如何像这样更改Flutter中单个选项卡背景
更改flutter中单个选项卡的背景颜色
TabBar(
isScrollable: true,
unselectedLabelStyle: TextStyle(color: Colors.black),
unselectedLabelColor: Colors.black,
indicator:BoxDecoration(
borderRadius: BorderRadius.circular(15),
color: Colors.black),
tabs: [
Tab(
child: Container(
color: Color(0xffebe7e2),
child: Text(
"All",
textAlign: TextAlign.center,
),
),
),
],
),
1条答案
按热度按时间4uqofj5v1#
您可以在容器装饰上提供选项卡项外观,如