-
Notifications
You must be signed in to change notification settings - Fork 4.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
Try: Show background and increased opacity on disabled switcher #13721
Conversation
This one goes out to all the @chrivanpatten's in the crowd! Well, specifically, it is in response to this conversation we had here: #11669 (comment) The problem: we always show the Block Switcher interface, even if no transformations are available. When no transformations are available, the buttonis _disabled_, which usually means it needs to have very contrast. However in this case, the block switcher also works as a block type indicator, which makes it valuable to be able to see the icon in question. This PR tries to marry the two challenges and shows the button as disabled adding a light gray background, but still increasing the opacity. Thoughts?
I personally don't understand that this is a disabled button :( |
It needs to be disabled when there is no action available to make sure it's skipped when using keyboard navigation, right? |
Added "needs design feedback" label to get some additional thoughts. |
On my laptop screen, I can barely tell that the button has a light gray background; if my screen is tilted a bit too much in one direction, it just looks white. |
I like this approach. I do think it's not 100% clear that this is disabled, but that could be partially because the gray is so light. Perhaps we darken slightly to As you note, this area serves two purposes:
The current, low opacity approach is designed primarily to address 2. It actually hurts 1 because it makes the indicator harder to see. This new approach keeps 1 working well, and also addresses 2 as a secondary concern. That makes sense to me. |
Great feedback, everyone. I tried darkening the background color, that helps. I also tried to make the icon itself monochrome, which I forgot from the conversation we had on the initial thread. I think that helps a lot: When will the YouTube icon be red, then, you ask? Glad you asked. It still has its colors in the Block Library: What do you think? |
@jasmussen That's better for me 👍 Thanks for the updates |
Awesome, thanks. I'm wondering why the tests fail? |
@jasmussen Probably unrelated (related to animations), I'll look at those separately. |
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!
One small note is that the placeholder and the disabled switcher colors are not exactly identical ($dark-opacity-light-200
vs. $light-gray-200
) in my browser at least. This nags at me just a bit, but that may just be me being too nitpicky. Inspecting these shows that they're only a couple hex values off, so it's probably not a huge deal.
Thank you Kjell. Going to merge this one. I've been thinking that we should revisit the placeholder pattern separately in a holistic way to see how we can improve it. I think there's some simplification we can do here that might make the gray unnecessary. |
* Try: Show background and increased opacity on disabled switcher This one goes out to all the @chrivanpatten's in the crowd! Well, specifically, it is in response to this conversation we had here: #11669 (comment) The problem: we always show the Block Switcher interface, even if no transformations are available. When no transformations are available, the buttonis _disabled_, which usually means it needs to have very contrast. However in this case, the block switcher also works as a block type indicator, which makes it valuable to be able to see the icon in question. This PR tries to marry the two challenges and shows the button as disabled adding a light gray background, but still increasing the opacity. Thoughts? * Try darker gray and monochrome icon.
* Try: Show background and increased opacity on disabled switcher This one goes out to all the @chrivanpatten's in the crowd! Well, specifically, it is in response to this conversation we had here: #11669 (comment) The problem: we always show the Block Switcher interface, even if no transformations are available. When no transformations are available, the buttonis _disabled_, which usually means it needs to have very contrast. However in this case, the block switcher also works as a block type indicator, which makes it valuable to be able to see the icon in question. This PR tries to marry the two challenges and shows the button as disabled adding a light gray background, but still increasing the opacity. Thoughts? * Try darker gray and monochrome icon.
This one goes out to all the @chrivanpatten's in the crowd!
Well, specifically, it is in response to this conversation we had here: #11669 (comment)
The problem: we always show the Block Switcher interface, even if no transformations are available. When no transformations are available, the buttonis disabled, which usually means it needs to have very contrast.
However in this case, the block switcher also works as a block type indicator, which makes it valuable to be able to see the icon in question.
This PR tries to marry the two challenges and shows the button as disabled adding a light gray background, but still increasing the opacity.
Thoughts?
Before:
After: