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

Try: Allow vertical inserter in the nav block. #28833

Merged
merged 1 commit into from
Mar 12, 2021
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
2 changes: 1 addition & 1 deletion packages/block-library/src/navigation-link/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
display: flex;
align-items: center;
position: relative;
margin: 0;
margin: 0 0.5em 0 0;

.wp-block-navigation-link__container:empty {
display: none;
Expand Down
8 changes: 8 additions & 0 deletions packages/block-library/src/navigation/editor.scss
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,16 @@
}

// Unset horizontal and vertical margin rules from editor normalization stylesheet.
// Both margin-left: auto; and margin-right: auto; from .wp-block, and also
// margin: revert; from .editor-styles-wrapper ul li.
.block-editor-block-list__block {
margin: 0;

// This CSS provides a little spacing between blocks.
// It matches a rule in style.scss exactly, but needs higher specificity due to the unsetting of inherited styles above.
&.wp-block-navigation-link {
margin: 0 0.5em 0 0;
}
}
}

Expand Down
1 change: 0 additions & 1 deletion packages/block-library/src/navigation/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
list-style: none;

// Overrides generic ".entry-content li" styles on the front end.
margin: 0;
padding: 0;
}
}
Expand Down