SSwitcher constructor

const SSwitcher({
  1. Key? key,
  2. required String valueText,
  3. String? title,
  4. TextStyle? titleStyle,
  5. String? titleTooltip,
  6. Widget? customPrefix,
  7. VoidCallback? onDecrement,
  8. VoidCallback? onIncrement,
  9. bool enableDecrement = true,
  10. bool enableIncrement = true,
  11. String? suffixText,
  12. TextStyle? suffixTextStyle,
  13. Widget? customSuffix,
  14. Decoration? containerDecoration,
  15. EdgeInsetsGeometry containerPadding = const EdgeInsets.symmetric(horizontal: 10, vertical: 8),
  16. Decoration? valueContainerDecoration,
  17. EdgeInsetsGeometry valueContainerPadding = const EdgeInsets.symmetric(horizontal: 10, vertical: 4),
  18. EdgeInsetsGeometry valueContainerMargin = const EdgeInsets.symmetric(horizontal: 8),
  19. double valueMinWidth = 26,
  20. IconData decrementIcon = Icons.remove_circle_outline_rounded,
  21. IconData incrementIcon = Icons.add_circle_outline_rounded,
  22. double iconSize = 18,
  23. Color? iconColor,
  24. TextStyle? valueTextStyle,
})

Implementation

const SSwitcher({
  super.key,
  required this.valueText,
  this.title,
  this.titleStyle,
  this.titleTooltip,
  this.customPrefix,
  this.onDecrement,
  this.onIncrement,
  this.enableDecrement = true,
  this.enableIncrement = true,
  this.suffixText,
  this.suffixTextStyle,
  this.customSuffix,
  this.containerDecoration,
  this.containerPadding =
      const EdgeInsets.symmetric(horizontal: 10, vertical: 8),
  this.valueContainerDecoration,
  this.valueContainerPadding =
      const EdgeInsets.symmetric(horizontal: 10, vertical: 4),
  this.valueContainerMargin = const EdgeInsets.symmetric(horizontal: 8),
  this.valueMinWidth = 26,
  this.decrementIcon = Icons.remove_circle_outline_rounded,
  this.incrementIcon = Icons.add_circle_outline_rounded,
  this.iconSize = 18,
  this.iconColor,
  this.valueTextStyle,
});