-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Migration guide for new Material 3 Slider
shapes
#11093
base: main
Are you sure you want to change the base?
Conversation
Slider
shapes
Visit the preview URL for this PR (updated for commit 61c185f): https://flutter-docs-prod--pr11093-slider-shapes-guide-r3oa68rq.web.app |
## Migration guide | ||
|
||
You automatically get the new `Slider` shapes and color mappings. | ||
To use the previous `Slider` shapes and color mappings, set the following |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is going through the theme the only option? Can folks configure directly on Slider
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Theme only. There are too many slider components parameters so looks like they weren't passed to Slider directly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, working with some customer that are affected by this, some of them don't like having to insert a theme to maintain backwards compatibility.
How many properties would be exposed on Slider in order to achieve backwards compatibility?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pretty much all of them, otherwise they would be inconsistent.
If necessary, what about if introduce single customization parameter in the Slider widget that take all of the Slider components and customizes the Slider. Something like TextStyle, AnimationStyle, we could've SliderStyle?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is also a really good idea!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you feel like that is better than a bunch of new constructors, let's give it a try and see how it looks. I trust your assessment of the two options. :)
4f50bb6
to
61c185f
Compare
Related to flutter/flutter#152237
Presubmit checklist