Skip to content

Commit

Permalink
Allow left/right/center alignments when a layout is defined (#32810)
Browse files Browse the repository at this point in the history
  • Loading branch information
youknowriad committed Jun 21, 2021
1 parent 5660364 commit 5fb3301
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion packages/block-library/src/group/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ function GroupEdit( { attributes, setAttributes, clientId } ) {
if ( themeSupportsLayout ) {
const alignments =
contentSize || wideSize
? [ 'wide', 'full' ]
? [ 'wide', 'full', 'left', 'center', 'right' ]
: [ 'left', 'center', 'right' ];
return {
type: 'default',
Expand Down
2 changes: 1 addition & 1 deletion packages/block-library/src/post-content/edit.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ function EditableContent( { layout, context = {} } ) {
if ( themeSupportsLayout ) {
const alignments =
contentSize || wideSize
? [ 'wide', 'full' ]
? [ 'wide', 'full', 'left', 'center', 'right' ]
: [ 'left', 'center', 'right' ];
return {
type: 'default',
Expand Down
2 changes: 1 addition & 1 deletion packages/block-library/src/query/edit/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export function QueryContent( { attributes, setAttributes } ) {
if ( themeSupportsLayout ) {
const alignments =
contentSize || wideSize
? [ 'wide', 'full' ]
? [ 'wide', 'full', 'left', 'center', 'right' ]
: [ 'left', 'center', 'right' ];
return {
type: 'default',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export default function TemplatePartInnerBlocks( {
if ( themeSupportsLayout ) {
const alignments =
contentSize || wideSize
? [ 'wide', 'full' ]
? [ 'wide', 'full', 'left', 'center', 'right' ]
: [ 'left', 'center', 'right' ];
return {
type: 'default',
Expand Down
2 changes: 1 addition & 1 deletion packages/edit-post/src/components/visual-editor/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ export default function VisualEditor( { styles } ) {
if ( themeSupportsLayout ) {
const alignments =
contentSize || wideSize
? [ 'wide', 'full' ]
? [ 'wide', 'full', 'left', 'center', 'right' ]
: [ 'left', 'center', 'right' ];
return {
type: 'default',
Expand Down

0 comments on commit 5fb3301

Please sign in to comment.