Stepper widget's background color is transparent at the Vertical type. When change type like StepperType.horizontal, stepper has white-grey background color. How could I change that background color at the horizontal axis?
Here is my sample code:
Container(
width: _width,
child: Stepper(
type: StepperType.horizontal,
steps: [
Step(
title: Text("First"),
content: Text("This is our first example."),
),
Step(
title: Text("Second"),
content: Text("This is our second example."),
),
],
),
),
To change the background color of stepper widget wrap it into Theme and give it a color in Canvas color.
Container(
width: _width,
child: Theme(
data: ThemeData(canvasColor: Colors.lightBlue),
child: Stepper(
type: StepperType.horizontal,
steps: [
Step(
title: Text("First"),
content: Text("This is our first example."),
),
Step(
title: Text("Second"),
content: Text("This is our second example."),
),
],
),
),
),
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With