TimeSpinner constructor

const TimeSpinner({
  1. required void onChangedSelectedTime(
    1. TimeOfDay? selected
    ),
  2. Key? key,
  3. TimeOfDay? initTime,
  4. bool is24HourFormat = false,
  5. double spinnerHeight = 120,
  6. double spinnerWidth = 60,
  7. double elementsSpace = 8,
  8. double digitHeight = 40,
  9. Color spinnerBgColor = const Color(0xFFF5F5F5),
  10. TextStyle selectedTextStyle = const TextStyle(fontSize: 24, fontWeight: FontWeight.bold, color: Colors.blue),
  11. TextStyle nonSelectedTextStyle = const TextStyle(fontSize: 18, color: Color(0xFFBDBDBD)),
  12. List<int>? hrValues,
  13. List<int>? minValues,
  14. List<int> discardedHrValues = const [],
  15. List<int> discardedMinValues = const [],
  16. BorderRadiusGeometry? borderRadius,
  17. BoxBorder? spinnerBorder,
  18. Function? onKeyboardEditing,
  19. bool showNoSelectionDots = true,
  20. AmPmButtonStyle? amPmButtonStyle,
  21. bool isInfiniteScroll = true,
})

Implementation

const TimeSpinner({
  required this.onChangedSelectedTime,
  super.key,
  this.initTime,
  this.is24HourFormat = false,
  this.spinnerHeight = 120,
  this.spinnerWidth = 60,
  this.elementsSpace = 8,
  this.digitHeight = 40,
  this.spinnerBgColor = const Color(0xFFF5F5F5),
  this.selectedTextStyle = const TextStyle(
    fontSize: 24,
    fontWeight: FontWeight.bold,
    color: Colors.blue,
  ),
  this.nonSelectedTextStyle = const TextStyle(
    fontSize: 18,
    color: Color(0xFFBDBDBD),
  ),
  this.hrValues,
  this.minValues,
  this.discardedHrValues = const [],
  this.discardedMinValues = const [],
  this.borderRadius,
  this.spinnerBorder,
  this.onKeyboardEditing,
  this.showNoSelectionDots = true,
  this.amPmButtonStyle,
  this.isInfiniteScroll = true,
});