sliding_action_button
1.0.0, released 4 months ago by an unverified publisher
A customizable Flutter slide-to-confirm button widget to reduce accidental triggers.
What it does
Provides a customizable slide-to-confirm button widget. It requires users to drag a thumb across a track to complete an action, helping prevent accidental taps on irreversible features.
AI-written summary of version 1.0.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You want to prevent accidental triggers on destructive or irreversible actions like deleting or paying.
- You need a slide-to-confirm mechanism with circle or square shapes, gradients, and async loaders.
Skip it when
- You just need a standard button or a generic touch interaction without a sliding mechanism.
Strengths
- Supports async loader states and completion controllers.
- Highly customizable with shapes, colors, gradients, and haptic feedback.
Weaknesses
- Limited to sliding action button use cases.
- Relies entirely on custom widget rendering rather than standard platform elements.
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 0
SlideToActionButton(
initialSlidingActionLabel: 'Slide to confirm',
finalSlidingActionLabel: '✓ Confirmed',
enabledTrackDecoration: SlideTrackDecoration.fromColor(Colors.orange),
disabledTrackDecoration: SlideTrackDecoration.fromColor(Colors.grey),
thumbIcon: const Icon(Icons.check, color: Colors.orange),
onSlideActionCompleted: () {
debugPrint('Action confirmed');
},
)Alternatives
Packages that do the same job and could replace sliding_action_button.
- material_new_shapes
Provides Material 3 shape definitions (e.g., RoundedPolygon, Cubic) for Flutter UI.
48Compare - slider_button
A customizable slider button widget for activating or deactivating events.
57Compare - rounded_loading_button_plus
Animated button with loading, success and error states for Flutter.
50Compare - progress_state_button
A customizable progress button widget with multiple states for Flutter.
50Compare