Archived topic
font and color of caption
13 replies · Started by Dina on January 31, 2018
Hi, how can I modify the font, colour and size of my caption?
The titles are dark grey as a default but my bakground is black, so they can't be read.
Thanks
Hi there,
The font family inherits from Typography > Body.
You can change the color with this CSS:
.wp-caption .wp-caption-text {
color: #ffffff;
}
Let me know if you are wanting different font family for the caption.
It doesn't work!
Can you link me to the page?
Sure. I'm using wp media folder, if you can see there are three displays, in the last one the titles are grey
It says "Sorry, you are not allowed to preview drafts."
Your captions are being styled by a plugin you're using:
.wpmf-gallery-caption .title {
color: #393939;
font-family: Raleway;
font-size: 13px;
font-weight: 700;
letter-spacing: 2px;
}
You can copy that CSS and make any necessary changes to it :)
Thank you Tom! I've texted the plugin team too anyway, in fact I wasn't sure if it depends on GP or the plugin. I'll try to paste this one and let you know. Maybe with the plugin there's an easier way. I don't understand much about it.Thanks!
No problem! :)
If you copy the CSS above and paste it in using one of these methods, you'll be able to adjust the font size and color: https://docs.generatepress.com/article/adding-css/
Hi Tom, I've used both Simple and additional css but nothing happens.
WP's replied "You can open 'plugins/wp-media-folder/assets/css/display-gallery/style-display-gallery.css' file , line 245 to change color and font-size" but I don't know how to open the folder, and on the dashboard I can't see the assets!
That's not very good advice - any changes you make in there will be lost if you update the plugin.
Instead, make this custom CSS more specific than theirs:
body .wpmf-gallery-caption .title {
color: #393939;
font-family: Raleway;
font-size: 13px;
font-weight: 700;
letter-spacing: 2px;
}
Great, it works now!
Thank you!! :)
You're welcome :)