Skip to content

Commit

Permalink
Fix application of gutter size CSS var (#28759)
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronrobertshaw authored and Glen Davies committed Feb 24, 2021
1 parent e563197 commit 8bd2ca4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/block-library/src/gallery/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ function GalleryEdit( props ) {
className: classnames( className, 'has-nested-images' ),
style: {
'--gallery-block--gutter-size':
gutterSize !== undefined && `${ gutterSize }px`,
gutterSize !== undefined ? `${ gutterSize }px` : undefined,
},
} );

Expand Down
2 changes: 1 addition & 1 deletion packages/block-library/src/gallery/save.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export default function save( { attributes } ) {

const style = {
'--gallery-block--gutter-size':
gutterSize !== undefined && `${ gutterSize }px`,
gutterSize !== undefined ? `${ gutterSize }px` : undefined,
};

return (
Expand Down

0 comments on commit 8bd2ca4

Please sign in to comment.