power_switch_button 0.0.6 copy "power_switch_button: ^0.0.6" to clipboard
power_switch_button: ^0.0.6 copied to clipboard

PowerSwitchButton is a customizable Flutter switch widget with adjustable size, stroke width, dash width, and dash space for a stylish toggle switch.

0.0.6 Current #

  • Added initialValue parameter to allow users to set the initial state of the switch button. This addresses the issue where users couldn't set the button to reflect the actual state of the device they're controlling. The parameter defaults to false for backward compatibility.

0.0.5 Aug 7, 2024 #

  • Added an intermediate loading state feature. When the button is pressed and initially off, it shows a loading state with a rotating outer dash circle until the next status is provided (success or failure). If successful, the button moves to the next state (on or off); if failure, it returns to the previous state.

0.0.4 Aug 5, 2024 #

  • customIcon: An optional custom icon to display in the switch.
  • label: An optional label text to display inside the switch.
  • disabled: A boolean to disable the switch (default is false).
  • onGradient: An optional gradient for the 'on' state.
  • offGradient: An optional gradient for the 'off' state.
  • shape: The shape of the switch button (default is Shape.CIRCLE).
  • borderRadius: The border radius for the square shape (optional).
  • animationDuration: The duration of the toggle animation (default is 300ms).
  • animationCurve: The curve of the toggle animation (default is Curves.easeInOut).

0.0.3 Aug 2, 2024 #

  • Optimise code

0.0.2 Aug 2, 2024 #

  • Added icon color change option as well.

0.0.1 Aug 1, 2024 #

  • Release of version one of power switch button library.
9
likes
150
points
8
downloads

Publisher

unverified uploader

Weekly Downloads

PowerSwitchButton is a customizable Flutter switch widget with adjustable size, stroke width, dash width, and dash space for a stylish toggle switch.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

cupertino_icons, flutter

More

Packages that depend on power_switch_button