RadiantButton constructor

const RadiantButton({
  1. Key? key,
  2. required AppTheme theme,
  3. required String text,
  4. void onPressed()?,
  5. double? minWidth,
  6. Alignment begin = Alignment.topCenter,
  7. Alignment end = Alignment.bottomCenter,
  8. EdgeInsets padding = const EdgeInsets.symmetric(vertical: 8, horizontal: 24),
  9. double borderRadius = 40,
  10. TextStyle? textStyle = const TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 20),
})

Implementation

const RadiantButton({
  super.key,
  required this.theme,
  required this.text,
  this.onPressed,
  this.minWidth,
  this.begin = Alignment.topCenter,
  this.end = Alignment.bottomCenter,
  this.padding = const EdgeInsets.symmetric(vertical: 8, horizontal: 24),
  this.borderRadius = 40,
  this.textStyle = const TextStyle(
    color: Colors.white, // Ensure text is visible on gradient
    fontWeight: FontWeight.bold,
    fontSize: 20,
  ),
});