-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Closed
Labels
P3Issues that are less important to the Flutter projectIssues that are less important to the Flutter projectc: new featureNothing broken; request for a new capabilityNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to FlutterA detailed proposal for a change to Flutterf: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.
Description
Use case
I would like to request a feature on the Slider widget where you can configure it to be "slide only", so that users can only change the value by tap-and-drag. If users just tap anywhere without dragging, it's no-op.
It's similar to the progress bar on YouTube app, you tap anywhere on the progress bar it won't change the video position - you have to slide. Here's a recording to YouTube's sliding behavior: https://drive.google.com/file/d/1kYEIxFB02E-avJCYsk5KWUPtANqzP_C_/view?usp=share_link
Proposal
/// Option 1: A boolean parameter
Slider(
slideOnly: true
);
/// Option 2: An enum for interaction style
Slider(
interactionStyle: SliderInteractionStyle.DRAG_ONLY;
);
enum SliderInteractionStyle {
DEFAULT,
DRAG_ONLY,
// ...
}mono0926
Metadata
Metadata
Assignees
Labels
P3Issues that are less important to the Flutter projectIssues that are less important to the Flutter projectc: new featureNothing broken; request for a new capabilityNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to FlutterA detailed proposal for a change to Flutterf: material designflutter/packages/flutter/material repository.flutter/packages/flutter/material repository.frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.