Make WordPress Core

Opened 2 years ago

Last modified 8 days ago

#56181 new defect (bug)

Video alignment off - items aligned left when they should align center

Reported by: justinclemente's profile justinclemente Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version:
Component: General Keywords: close
Focuses: Cc:

Description

All video elements at our website (ncchagerstown.org) are aligning left when they should align center. Any help is greatly appreciated!

Change History (2)

#1 @sabernhardt
2 years ago

  • Keywords close added

Thanks for the report! Welcome to WordPress Trac!

This might have fit better in the support forums. I could not figure out how you have these margins added at the end of the global styles:

.wp-block-audio{margin: 0 0 1em 0;}
.wp-block-table > table{margin: 0 0 1em 0;}
.wp-block-video{margin: 0 0 1em 0;}
.wp-block-embed{margin: 0 0 1em 0;}

Your theme is apparently Twenty Twenty (or a child theme based on it).

As a quick fix, to override the styles above for any of these blocks that you choose to center, you could go to the Customizer and find Additional CSS. Then paste the following and click Publish:

figure.aligncenter {
  margin-left: auto;
  margin-right: auto;
}

Or if you always want these blocks centered, without choosing the alignment from the block toolbar, you could use this:

.wp-block-audio,
.wp-block-video,
.wp-block-embed {
  margin-left: auto;
  margin-right: auto;
}

#2 @tw2113
8 days ago

@justinclemente Is this still an issue? or can the ticket be considered closable?

Note: See TracTickets for help on using tickets.