Styling the on page caption
Permalink Browser Info Environment
I just tried this today and am really glad I found this simple add-on. I don't know how I missed it all this time!
I'm not the sharpest pin in the pack so I thhought I'd ask this query here in case others come after me with the same question.. is there a way to set the style for captions of images on pages that is separate from the standard page text e.g. drop a point size, increase line spacing etc?
I can see there are css file for each of the styles but not the caption. I guess I could create a custome style and manually apply it to every block, but I just thought I'd check in case brighter folk could suggest where to place some code to do this automagically to every placed image using this great block.
I'm not the sharpest pin in the pack so I thhought I'd ask this query here in case others come after me with the same question.. is there a way to set the style for captions of images on pages that is separate from the standard page text e.g. drop a point size, increase line spacing etc?
I can see there are css file for each of the styles but not the caption. I guess I could create a custome style and manually apply it to every block, but I just thought I'd check in case brighter folk could suggest where to place some code to do this automagically to every placed image using this great block.
Type: | Discussion |
---|---|
Status: | New |
I did briefly mention how to do this in the documentation for the block:
http://www.concrete5.org/marketplace/addons/lightboxed-image/docume...
But it's a bit vague on where to put the styling.
If you have built your own theme, then you should just be able to edit the stylesheet for it to include a rule for .lightboxed-image-caption-content
If you are using 5.5, when you go into the dashboard, and find the list of available themes, there should be a 'customise' button against your theme. In there, where you can pick colours and what-not, there is an 'Add your CSS' button. Using that you could paste in some css, e.g.
When I tried to do this with the Greek Yogurt theme though, there was already some custom code in there. Adding the rule didn't work straight away. I had to add a closing braket first, underneath the existing content, like this:
I also had to do quite a few refreshes to get the styling to work.
For 5.4.x it's perhaps a little trickier. I think doing a normal view.php/view.css override will break things. Perhaps follow the linked instructions above for overriding a lightbox theme, and just tack on your css for the caption onto the end of a colorbox.css file.
(Someone else might have a better suggestion, I'm used to creating my own themes)