@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
body: Column(
children: <Widget>[
Container(
width: 200,
height: 200,
decoration: new BoxDecoration(
gradient: new LinearGradient(
colors: [Color(0xFF11F4B5), Color(0xFFCA436B)],
begin: FractionalOffset.centerLeft,
end: FractionalOffset.centerRight,
stops: [0.0, 1.0],
tileMode: TileMode.clamp)),
),
SizedBox(
height: 20,
),
Container(
width: 200,
height: 200,
decoration: new BoxDecoration(
gradient: new LinearGradient(
colors: [Color(0xFF1cb5e1), Color(0xFF000046),Color(0xFF000000)],
begin: FractionalOffset.topLeft,
end: FractionalOffset.bottomRight,
stops: [0.0, 1.0],
tileMode: TileMode.mirror)),
),
],
)),
);
}
просто проверьте, работает ли это, изменение цвета даст вам желаемый результат