GradientButton constructor

const GradientButton({
  1. Key? key,
  2. required VoidCallback onPressed,
  3. required String buttonText,
  4. List<Color> colors = const [Color(0xfff44336), Color(0xffff9800)],
  5. List<Color> darkColors = const [Color(0xff293545), Color(0xFF3B485F)],
  6. List<double> stops = const [0.0, 1.0],
  7. TextStyle textStyle = const TextStyle(color: Colors.white, fontWeight: FontWeight.bold),
  8. double radius = 18.0,
})

Implementation

const GradientButton({
  super.key,
  required this.onPressed,
  required this.buttonText,
  this.colors = const [Color(0xfff44336), Color(0xffff9800)],
  this.darkColors = const [Color(0xff293545), Color(0xFF3B485F)],
  this.stops = const [0.0, 1.0],
  this.textStyle =
      const TextStyle(color: Colors.white, fontWeight: FontWeight.bold),
  this.radius = 18.0,
});