Skip to content
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

The opacity slider thumb padding broke/changed after upgrading to Flutter 3.27.0 #90

Open
rydmike opened this issue Dec 13, 2024 · 5 comments
Labels
Flutter SDK bug There is a bug and it is caused by an issue in the Flutter SDK Flutter SDK change help wanted Extra attention is needed
Milestone

Comments

@rydmike
Copy link
Owner

rydmike commented Dec 13, 2024

Before Flutter 3.27.0

Before upgrading to Flutter 3.27.0, the opacity slider in FlexColorPicer behaved like this, when using different track height and thumb sizes:

Screen.Recording.2024-12-13.at.20.52.38.mov

This can be tested and verified with the web demo build made with Flutter version 3.24.3, published here:

https://rydmike.com/flexcolorpicker3-6-0/

After Flutter 3.27.0 upgrade

With Flutter 3.27.0 there is new extra padding around the opacity slider.

Screen.Recording.2024-12-13.at.20.56.27.mov

Suggested and tried fixes

The following fix was tried together with @TahaTesser

Remove thumbRadius compensation in shapeRect

Screenshot 2024-12-13 at 21 17 59

This removes half of the extra padding, but not all as desired and needed to match the past custom design.

FIX ATTEMPT CORRECT DESIGN
Screenshot 2024-12-13 at 21 20 04 Screenshot 2024-12-13 at 21 22 55

The fix did not work and it also made the thumb no longer track the mouse and jump when it is pushed:

Screen.Recording.2024-12-13.at.21.22.12.mov

EDIT: This jump on push also happens without the above FIX attempt when using Flutter 3.27.0. It does not happen on the Flutter 3.24.3 build.


Fix PRs welcome!

Please submit any fix PRs to https://github.com/rydmike/flex_color_picker

@rydmike rydmike added help wanted Extra attention is needed good first issue Good for newcomers Flutter SDK change Flutter SDK bug There is a bug and it is caused by an issue in the Flutter SDK labels Dec 13, 2024
@rydmike rydmike added this to the 3.7.1 milestone Dec 13, 2024
@rydmike rydmike removed the good first issue Good for newcomers label Dec 13, 2024
@TahaTesser
Copy link

Investigating this. Maybe related to flutter/flutter#161210

@rydmike
Copy link
Owner Author

rydmike commented Jan 17, 2025

Thanks @TahaTesser your Flutter PR flutter/flutter#161814 should fix this too. I can verify when it has been merged in Flutter master.

@TahaTesser
Copy link

Thanks @TahaTesser your Flutter PR flutter/flutter#161814 should fix this too. I can verify when it has been merged in Flutter master.

Here you go!

Image

@rydmike
Copy link
Owner Author

rydmike commented Jan 20, 2025

Awesome @TahaTesser and good to verify with this case too. The PR has not been merged yet, but soon enough I guess.

Are you going to request a CP for this fix too?

@TahaTesser
Copy link

Are you going to request a CP for this fix too?

Don't think so. This is not easily reproducible, it needs certain conditions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Flutter SDK bug There is a bug and it is caused by an issue in the Flutter SDK Flutter SDK change help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants