Skip to content

Instantly share code, notes, and snippets.

@saltnpixels
Created June 2, 2021 18:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save saltnpixels/6c8011ed6bb19715e2428e3690cd302f to your computer and use it in GitHub Desktop.
Save saltnpixels/6c8011ed6bb19715e2428e3690cd302f to your computer and use it in GitHub Desktop.
Centered Content for WP Blocks
.entry-content,
.article-footer,
.after-article {
padding-left: var(--spacing-20);
padding-right: var(--spacing-20);
&::after {
clear: both;
content: "";
}
& > * {
margin-left: auto;
margin-right: auto;
max-width: var(--width-default);
width: 100%;
}
& > .alignwide {
max-width: var(--width-wide);
}
& > .alignfull {
max-width: var(--width-full);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment