SimpleYearPickerWidget constructor

const SimpleYearPickerWidget({
  1. Key? key,
  2. required DateTime yearDateTime,
  3. required dynamic onChangedCallback(
    1. int
    ),
  4. int firstYear = 1900,
  5. int lastYear = 2100,
  6. Decoration? decoration,
  7. bool looping = true,
  8. EdgeInsetsGeometry padding = EdgeInsets.zero,
  9. double width = 400,
  10. double height = 350,
  11. double? yearWidth,
  12. double yearHeight = 250,
  13. Decoration? pickerDecoration,
  14. Color pickerBackgroundColor = Colors.white,
  15. double itemHeight = 60,
  16. Alignment textAlignment = Alignment.center,
  17. TextStyle? textStyle,
  18. double buttonHeight = 60,
  19. double todayButtonWidth = 200,
  20. Color todayButtonColor = Colors.white,
  21. Decoration? todayButtonDecoration,
  22. String todayButtonText = 'TODAY',
  23. TextStyle? todayButtonTextStyle = const TextStyle(color: Colors.black),
  24. double doneButtonWidth = 200,
  25. Color doneButtonColor = Colors.white,
  26. Decoration? doneButtonDecoration,
  27. String doneButtonText = 'DONE',
  28. TextStyle? doneButtonTextStyle = const TextStyle(color: Colors.black),
})

Implementation

const SimpleYearPickerWidget({
  super.key,
  required this.yearDateTime,
  required this.onChangedCallback,
  this.firstYear = 1900,
  this.lastYear = 2100,
  this.decoration,
  this.looping = true,
  this.padding = EdgeInsets.zero,
  this.width = 400,
  this.height = 350,
  this.yearWidth,
  this.yearHeight = 250,
  this.pickerDecoration,
  this.pickerBackgroundColor = Colors.white,
  this.itemHeight = 60,
  this.textAlignment = Alignment.center,
  this.textStyle,
  this.buttonHeight = 60,
  this.todayButtonWidth = 200,
  this.todayButtonColor = Colors.white,
  this.todayButtonDecoration,
  this.todayButtonText = 'TODAY',
  this.todayButtonTextStyle = const TextStyle(color: Colors.black),
  this.doneButtonWidth = 200,
  this.doneButtonColor = Colors.white,
  this.doneButtonDecoration,
  this.doneButtonText = 'DONE',
  this.doneButtonTextStyle = const TextStyle(color: Colors.black),
});