-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
Fix: The pressed state of menu items uses a very dark BG color #47036
Fix: The pressed state of menu items uses a very dark BG color #47036
Conversation
What do we do for our standard buttons? My idea is to just use the same behavior we use for our standard buttons. I tried using a button in Settings > Troubleshoot and it feels like it doesn't get a pressed BG. |
@shawnborton - For buttons in Settings > Troubleshoot we use One thing to consider is that the menu item has a custom active state color but the standard buttons have not. this is why we use a lighter focus color for the hover state of the menu item compared to the hover state of standard buttons. Do we want to not use a custom color for the menu item pressed state (keep the hover color) and only apply 80% opacity for the pressed state? |
I'd be curious to see a version where it uses just our colors.border for the active state (the same thing we use for when the rows are in LHN navs for things like Settings or the Workspace editor), as well as where it uses the same active BG as buttons. Can we get a side-by-side comparison of those two? |
@shawnborton - Here are videos for both cases: Using Screen.Recording.2024-08-08.at.12.38.05.PM.movUsing Screen.Recording.2024-08-08.at.12.40.19.PM.mov |
I like the first one better, but I generally like the idea of just being consistent with buttons which means me lean towards the second one. Do we know how the super dark style was ever introduced in the first place though? It feels so strange and like it was recently added. I'm mostly just curious for my own sake. |
I think I agree here. Honestly both are better than the super dark thing we have going on now so I'm not against either, but I like the idea of leaning into patterns we already have established for buttons. |
We're not using a custom pressed BG color for selection list items and we're only using a reduced opacity. So I think the first option in #47036 (comment) is more consistent? Screen.Recording.2024-08-08.at.5.31.47.PM.mov |
Oh interesting... that does seem to make sense to. I guess you could ague either one is consistent with something. Or we make list items consistent with buttons. Let's see if the design team has any strong feelings. |
No strong feelings from me! I think either works—do you have a strong preference for one vs. the other? |
I think I lean towards 2 so we start establishing a consistent BG color to use for press? |
Sounds good to me as well |
@rayane-djouah Does the PR need to be updated to meet design team's decisions? |
Yes, will update today |
What's the latest on this one? |
PR ready for review |
This comment has been minimized.
This comment has been minimized.
Hmm when I test this, it seems like the BG color changes quickly and then it quickly changes again even though I had my mouse pressed the entire time. Any ideas? CleanShot.2024-08-19.at.10.54.16.mp4 |
How can we fix that? Can we make them use the same animation or something so they change at the same time? |
…very-dark-BG-color
Hmm, they technically are changing at the same time, so I'm not sure why this is happening. @eh2077, any ideas? |
…ms-uses-a-very-dark-BG-color
Thanks for the ping. The issue seems subtle. I'll have to take some time to investigate it and get back to here later. |
@rayane-djouah If the opacity only needs to be applied to the background color, then maybe we can try rgb(). If not, are you able to reproduce the issue with a minimal demo? So we can understand the issue better |
What's the latest on this one? Let's try to get this one over the finish line! |
Sorry for the delay; I was focusing on critical / high-priority issues. @shawnborton - I'm having trouble understanding the expected result from this bug report. Could you please clarify a bit more or share a mockup/prototype video of the expected result? That would be very helpful. |
Yeah - basically it feels like the background color of the menuItem changes to the darker color quickly, and then we see the animated change in opacity. So you get a bit of like a double effect where the color changes and then the opacity changes. It would feel smoother if that could all happen at once so you don't get that slight flashing effect. Let me know if that is helpful! |
Updated! Screen.Recording.2024-09-15.at.1.14.34.PM.movcc @shawnborton |
That seems pretty good to me! |
🧪🧪 Use the links below to test this adhoc build on Android, iOS, Desktop, and Web. Happy testing! 🧪🧪 |
Okay let's get this into final review + merge @eh2077 |
Reviewer Checklist
Screenshots/VideosAndroid: Native0-android.mp4Android: mWeb Chrome0-mobile-chrome.mp4iOS: Native0-ios.mp4iOS: mWeb Safari0-ios.mp4MacOS: Chrome / Safari0-web.mp4MacOS: Desktop0-desktop.mp4 |
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.
LGTM! Just a minor comment
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.
LGTM!
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/arosiclair in version: 9.0.36-1 🚀
|
🚀 Deployed to production by https://github.com/grgia in version: 9.0.36-2 🚀
|
Details
Fixed Issues
$ #46928
PROPOSAL: #46928 (comment)
Tests
Offline tests
N/A
QA Steps
Same as tests
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodSTYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label and/or tagged@Expensify/design
so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
Screen.Recording.2024-08-18.at.7.11.47.PM.mov
Android: mWeb Chrome
Screen.Recording.2024-08-18.at.7.10.08.PM.mov
iOS: Native
Simulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2024-08-18.at.19.09.53.mp4
iOS: mWeb Safari
Simulator.Screen.Recording.-.iPhone.15.Pro.Max.-.2024-08-18.at.19.07.29.mp4
MacOS: Chrome / Safari
Screen.Recording.2024-08-18.at.6.57.26.PM.mov
MacOS: Desktop
Screen.Recording.2024-08-18.at.7.08.22.PM.mov