Skip to content
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 issue with margin on blocks with no toolbars #753

Merged
merged 1 commit into from
May 10, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions editor/assets/stylesheets/_variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ $text-editor-max-width: 760px;
/* Editor */
$text-editor-max-width: 760px;
$visual-editor-max-width: 700px;
$block-controls-height: 46px;

/* Blocks */
$block-padding: 14px;
Expand Down
3 changes: 2 additions & 1 deletion editor/modes/visual-editor/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,9 @@
display: flex;
position: sticky;
z-index: 1;
margin-top: -46px - $item-spacing; // 46 is toolbar height
margin-top: -$block-controls-height - $item-spacing;
margin-bottom: $item-spacing + 20px; // 20px is the offset from the bottom of the selected block where it stops sticking
height: $block-controls-height;

top: $header-height + $admin-bar-height-big + $item-spacing;

Expand Down