Skip to content

Commit

Permalink
Styling fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ellatrix committed Jan 27, 2020
1 parent 046a187 commit 478ce5e
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 10 deletions.
2 changes: 1 addition & 1 deletion packages/block-library/src/column/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ function ColumnEdit( {
templateLock={ false }
renderAppender={ (
hasChildBlocks ?
undefined :
false :
() => <InnerBlocks.ButtonBlockAppender />
) }
tagName={ Block.div }
Expand Down
5 changes: 3 additions & 2 deletions packages/block-library/src/columns/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ const ColumnsEdit = ( props ) => {
);
}

return (
return <Block.div>
<__experimentalBlockPatternPicker
icon={ get( blockType, [ 'icon', 'src' ] ) }
label={ get( blockType, [ 'title' ] ) }
Expand All @@ -229,7 +229,8 @@ const ColumnsEdit = ( props ) => {
}
} }
allowSkip
/> );
/>
</Block.div>;
};

export default ColumnsEdit;
18 changes: 11 additions & 7 deletions packages/block-library/src/columns/editor.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,18 @@

// Ideally this shouldn't be necessary. There should be no default margins in
// the editor.


.editor-styles-wrapper .block-editor-block-list__block.wp-block-column,
.editor-styles-wrapper .block-editor-block-list__block.wp-block-columns {
margin-top: -$default-block-margin;
margin-bottom: -$default-block-margin;
}

.editor-styles-wrapper .block-editor-block-list__block.wp-block-column {
margin-top: 0;
margin-bottom: 0;
}

// This is the style used on the front-end, which ideally should be loaded in
// the editor too.
.wp-block-column > *:first-child {
margin-top: 0 !important;
}

.wp-block-column > *:last-child {
margin-bottom: 0 !important;
}

0 comments on commit 478ce5e

Please sign in to comment.