-
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
Post editor: Add some top margin. #35717
Conversation
@@ -44,7 +44,8 @@ | |||
margin-right: auto; | |||
} | |||
|
|||
margin-top: var(--wp--style--block-gap); | |||
// Add extra margin at the top, to push down the Title area in the post editor. | |||
margin-top: max(var(--wp--style--block-gap, #{ $grid-unit-10 * 8 }), #{ $grid-unit-10 * 8 }); |
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.
This creative rule exists to thread the needle between themes that have a block gap defined, themes that don't, and themes that have a block gap higher than 64px, letting that shine through.
Two alternatives:
- Don't worry about themes with post title margins higher than 64px, and just bake it to
margin-top: $grid-unit-10 * 8;
- Use rems, such as
margin-top: 4rem;
Happy to change to either. Thoughts?
Size Change: +1 B (0%) Total Size: 1.07 MB
ℹ️ View Unchanged
|
I don't have opinion here, I wonder whether using |
Let me try rems, just to see how that feels. This does sort of straddle the line between UI and theme, though. |
Description
Followup to #35426. The top margin in the post editor above the title can be a bit small:
The post editor, unlike the Site Editor, should cater just a little bit more to the writing experience, and pushing the site title down just a bit feels worth it:
Also tested this with tt and tt1:
And tt1 blocks:
How has this been tested?
Create a new post and observe the post title in the post editor pushed down to a comfortable place.
Checklist:
*.native.js
files for terms that need renaming or removal).