我想删除所选项目后面的蓝色椭圆。如何执行此操作?
NavigationBarItem(
selected = selected,
onClick = onClick,
icon = if (selected) selectedIcon else icon,
modifier = modifier,
enabled = enabled,
label = label,
alwaysShowLabel = alwaysShowLabel,
colors = NavigationBarItemDefaults.colors(
selectedIconColor = AppDefaults.navigationSelectedItemColor(),
unselectedIconColor = AppDefaults.navigationContentColor(),
selectedTextColor = AppDefaults.navigationSelectedItemColor(),
unselectedTextColor = AppDefaults.navigationContentColor(),
indicatorColor = AppDefaults.navigationIndicatorColor()
)
)
1条答案
按热度按时间flseospp1#
指示器的颜色由
NavigationBarItem
中的**indicatorColor
**属性定义。要删除它,您必须应用与
NavigationBar
相同的containerColor
。如果使用默认值(
containerColor
=surface
颜色),则必须计算应用于containerColor
的不同高程处的表面色调颜色。类似于:
在其他情况下只使用相同的颜色: