-
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
Standardize block styles cursor on hover #31188
Standardize block styles cursor on hover #31188
Conversation
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.
I've tested this PR, and it looks fine for me.
Hi! Thank you for testing! do we have to wait for an other reviewer? Or do I have any tasks to do? |
Yes, I'd say let's wait for another one. |
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.
Hi
Changing the cursor style here would affect the editors and not only the block styles panel.
I think it would be better to limit the change and increase the specificity of the cursor style that is used in the block styles panel, so that the .editor-styles-wrapper cursor style does not override it.
(Also I am not able to build the files, please refresh it so that it is up to date with changes to trunk)
Hi, So if we want to specify the whole thing a bit more, I would have to override this cursor: text; rule (just for the block styles). Are you ok with that? if so, I would do that right now. I will rebase my branch and add the newest commits of the trunk to it. |
d242298
to
f04a6de
Compare
I am not sure we understood each other. My suggestion is to only change the cursor for this component: |
I got that. I just thought it made sense to set the value to inherit in all places and have it be inherited by its parent elements. Thanks for your suggestion. I have adjusted the whole thing now. However, as I mentioned earlier, I had to define a new rule. We don't get this line: https://github.com/WordPress/gutenberg/blob/trunk/packages/block-editor/src/components/block-styles/style.scss#L11 |
@jasmussen I checked it again. Nothing is overwritten by my fix. Neither for the Block Patterns, Reusable Blocks and the normal blocks. I have also implemented Carolina's recommendation (see last commit) so that it only applies to the Block Styles. So it should be safe. |
Awesome! I will let Carolina give the green light when she has a moment. Thanks for the work! |
I have a problem with my local environment where git rejects the checkout of this PR, I will need someone else to do a final test and merge. |
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.
a80ccc4
to
0c85bb1
Compare
I have rebased the branch and now are all Checks green. Can we merge this :) ? |
Thank you! |
Description
I have unified the cursor of the block styles when hovering. Previously, a text cursor was displayed no matter what content was in there. This leads to confusion in my opinion. Gutenberg also uses pointer cursor for several interactive elements.
How has this been tested?
Builded the newest version of gutenberg with my changes and tested it in several browsers.
Screenshots
Before:
After:
Types of changes
Checklist:
*.native.js
files for terms that need renaming or removal).