custom_switch_widget 0.0.1 copy "custom_switch_widget: ^0.0.1" to clipboard
custom_switch_widget: ^0.0.1 copied to clipboard

custom_switch_widget

CustomSwitchWidget #

dependencies:
  ...
  custom_switch_widget: ^0.0.1
copied to clipboard
final CustomSwitchController _controller = CustomSwitchController();

CustomSwitchWidget(
  controller: _controller, 
  onChange: (value) {},
)
copied to clipboard
  • Enable switch
_controller.enable();
copied to clipboard
  • Disable switch
_controller.disable();
copied to clipboard
Fields Description
controller Channel sending the changes to be made
activeColor color the widget when enable
inactiveColor color the widget when disable
pointColor color the point widget
width Helps set the width of the widget. NOTE: only up to 50 px is allowed (width >= 30 && width <= 50)
height Helps set the height of the widget. NOTE: only up to 50 px is allowed (width >= 20 && width <= 50)
borderRadius Sets the edges of the widget
onChange Detects call touch for state change
1
likes
130
points
26
downloads

Publisher

verified publisheredvaldomartins.dev

Weekly Downloads

2024.07.08 - 2025.01.20

custom_switch_widget

Repository (GitHub)

Documentation

API reference

License

Apache-2.0 (license)

Dependencies

flutter

More

Packages that depend on custom_switch_widget