-
nathonas
I’m trying to make the font size of the WordPress Popular Posts widget smaller (I know this isn’t your guys’ plugin, but maybe you can help). I tried adding the CSS in additional CSS in customize but it’s not working for some reason. Here’s the code I’m using, which SHOULD work:
.wpp-post-title {
font-size: 15px !important;
}I also tried:
.wpp-tiles li {
font-size: 15px !important;
}Any idea what could be wrong? I’ve spent hours trying to figure it out.
-
David
Hi there,
the font size has been set on the
a
tag.eg.
ul.wpp-tiles li .wpp-post-data .wpp-post-title { font-size: 15px; }
Try adding that to the top of your Customiser CSS and then clear any caches on the site.
-
nathonas
I added the code and cleared cache, doesn’t seem to work. It also doesn’t show the text sizing down in the customizer preview.
-
David
Aah. the Plugin is using Javascript to output its HTML into the shadow dom. So I dont think its possible.
You could try this but its unlikely to work
edit the Sidebar and immediately after that Popular posts
Add the a HTML Block and add the CSS there inside somestyle
tags eg..<style> ul.wpp-tiles li .wpp-post-data .wpp-post-title { font-size: 15px; } </style>
This will add the CSS immediately after the HTML has been added.
-
nathonas
Thanks David, do you mean like this? https://imgur.com/a/Rh4JpfV
Doesn’t seem to work
-
David
Yeah, but I kinda knew it wouldn’t work due to the way that plugin is injecting its HTML.
You would need to check with the plugin developer as it needs to be changed in their code. Or find a different plugin -
nathonas
Gotcha, thanks for the help
-
David
You’re welcome
- You must be logged in to reply to this topic.