Repository navigation
Slider remains active after interaction on web and desktop #129016
Copy link
Copy link
Closed
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work lista: desktopRunning on desktopRunning on desktopc: regressionIt was better in the past than it is nowIt was better in the past than it is nowfound in release: 3.10Found to occur in 3.10Found to occur in 3.10found in release: 3.12Found to occur in 3.12Found to occur in 3.12frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onp: material_uimaterial_ui package in flutter/packagesmaterial_ui package in flutter/packagesplatform-webWeb applications specificallyWeb applications specificallyr: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer version
Description
Is there an existing issue for this?
- I have searched the existing issues
- I have read the guide to filing a bug
Steps to reproduce
- Go to https://api.flutter.dev/flutter/material/Slider-class.html
- Drag the slider in the example
Expected results
The slider should go back to its original design.
Actual results
The slider remains active.
Code sample
import 'package:flutter/material.dart';
/// Flutter code sample for [Slider].
void main() => runApp(const SliderApp());
class SliderApp extends StatelessWidget {
const SliderApp({super.key});
@override
Widget build(BuildContext context) {
return const MaterialApp(
home: SliderExample(),
);
}
}
class SliderExample extends StatefulWidget {
const SliderExample({super.key});
@override
State<SliderExample> createState() => _SliderExampleState();
}
class _SliderExampleState extends State<SliderExample> {
double _currentSliderValue = 20;
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(title: const Text('Slider')),
body: Slider(
value: _currentSliderValue,
max: 100,
divisions: 5,
label: _currentSliderValue.round().toString(),
onChanged: (double value) {
setState(() {
_currentSliderValue = value;
});
},
),
);
}
}
Screenshots or Video
Screen.Recording.2023-06-16.at.17.37.52.mov
Logs
No response
Flutter Doctor output
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
P2Important issues not at the top of the work listImportant issues not at the top of the work lista: desktopRunning on desktopRunning on desktopc: regressionIt was better in the past than it is nowIt was better in the past than it is nowfound in release: 3.10Found to occur in 3.10Found to occur in 3.10found in release: 3.12Found to occur in 3.12Found to occur in 3.12frameworkflutter/packages/flutter repository. See also f: labels.flutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onThe issue has been confirmed reproducible and is ready to work onp: material_uimaterial_ui package in flutter/packagesmaterial_ui package in flutter/packagesplatform-webWeb applications specificallyWeb applications specificallyr: fixedIssue is closed as already fixed in a newer versionIssue is closed as already fixed in a newer version
Type
Projects
- StatusShow more project fieldsDone (PR merged)
Activity
[-]Slider remains active after interacto[/-][+]Slider remains active after interaction[/+][-]Slider remains active after interaction[/-][+]Slider remains active after interaction on web[/+]darshankawar commentedon Jun 19, 2023
Thanks for the report @Kal-Elx
I verified this using latest master and stable versions and on mobile, web and desktop platforms and observed that the reported behavior occurs on web and desktop.
The value goes away upon dragging and clicking, but the focus still remains. The said behavior doesn't occur on mobile:
129016_m.mov
I also verified using RangeSlider on affected platforms (web and desktop) and this widget works properly on them, ie, the value as well as focus goes away after clicking and dragging.
This issue was probably fixed as part of #123313, but still seems to be occuring, although that issue was for label not being disappearing, but here the focus is not disappearing after click and drag. Also, a duplicate was closed in favor of the fixed issue.
Based on this comment, the issue seemed to have fixed on desktop too, but based on above verification, it is still occuring, so I'll label this as regression.
Linking this umbrella issue for reference: #125329
stable, master flutter doctor -v
[-]Slider remains active after interaction on web[/-][+]Slider remains active after interaction on web and desktop[/+]Fix `Slider` overlay remains when unfocused (#129115)
github-actions commentedon Jul 10, 2023
This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of
flutter doctor -vand a minimal reproduction of the issue.Fix `Slider` overlay remains when unfocused (#129115)