-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Notices: Editor notice margins appear conflicted with theme background color #18762
Comments
Yup, it's from a margin-bottom of If we move the notices into the |
Here's with setting And here's the same, but with two notices:Info notices:Error notices: |
@richtabor I'll of course defer to your judgment (and any other designers who might weigh in), but from my perspective, your proposed border seems nicer to me even than the original design was going for with the margins. There's a nice consistency with borders used elsewhere in the UI (with that in mind, should it be the exact color of other borders, if not already?). Seems to me like an easy way to fix the issue 👍 |
100%, totally agree.
Yea, we can try - it's worth exploring. There may be a bit of clash with a gray border against the notices (as they hold a background color), which is why I went transparent. For reference, the |
Huh, I clearly needed to brush up on my understanding of how borders and backgrounds interact (CodePen), since I was under the impression it wouldn't matter if the border was outside of the content/background area. But yes, I can see now why a semi-transparent black would likely clash less than a static gray border. |
Can you clarify, since your first comment mentioned using a |
Oh sorry about that! I was referring to the For clarification:
|
Thanks for clarifying. In #18871, I went with |
Describe the bug
If a theme defines an editor background color, the existence of a notice in the editor will create an undesirable gap of white.
To reproduce
Steps to reproduce the behavior:
wp.data.dispatch( 'core/notices' ).createInfoNotice( 'Hello World!' )
Expected behavior
Any space between notices and the editable content should be seamless (inherit background color).
Desktop (please complete the following information):
Additional context
Originally observed at #18732 (comment)
My first intuition was to remove the margin from the last notice in the set. However, there are two issues with this:
Possible solutions:
.editor-styles-wrapper
element (the element which receives the theme styling)The text was updated successfully, but these errors were encountered: