有没有办法在使用showModalBottomSheet
时更改覆盖背景色?
现在的 colored颜色 总是灰色,但是我想使用不同的 colored颜色 ,比如绿色,如下所示.
以下是演示中使用的代码供参考
showModalBottomSheet<void>(context: context, builder: (BuildContext context) {
return Container(
child: Padding(
padding: const EdgeInsets.all(32.0),
child: Text('This is the modal bottom sheet. Tap anywhere to dismiss.',
textAlign: TextAlign.center,
style: TextStyle(
color: Theme.of(context).accentColor,
fontSize: 24.0
)
)
)
);
});