Skip to content

Instantly share code, notes, and snippets.

@jessestu
Created March 19, 2019 17:16
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 jessestu/29e4842674a17c8f69e8dfb71801ab59 to your computer and use it in GitHub Desktop.
Save jessestu/29e4842674a17c8f69e8dfb71801ab59 to your computer and use it in GitHub Desktop.

Please go to My Site → Customize → CSS (or Additional CSS), then add all of the following code to the bottom of that window.


/* This CSS styles the captions on https://xiaolabucla.org/people/
* 11343122-hc (jw)
*/
/* Formats the text */
.page-id-79 figcaption {
  color: #5b776b;       /* Colors */
  font-size: 16px;      /* Size */
  text-align: center;   /* Centers */
}

/* Makes bolded text show as bold */
.page-id-79 figcaption b,
.page-id-79 figcaption strong {
  font-weight: bold;
}

/* Removes background color */
.page-id-79 figure.wp-caption {
  background-color: transparent;
}

/* Places caption at top */
.page-id-79 figure.wp-caption {
  display: flex;
  flex-direction: column;
}
.page-id-79 figure.wp-caption img {
  order: 2;
}
.page-id-79 figure.wp-caption figcaption {
  order: 1;
}

Tip: keep the /* comment */ in the code to later know what this code does.

Example of where to add the CSS

If this image fails to load, please see it at: http://cld.wthms.co/av2gwv

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment