Archived topic
First featured post
3 replies · Started by Victor Millan on May 17, 2019
Hello, I would like to ask you something.
I'm using the Marketer theme using the blog as the home page. I would like that in the home, the first blog post, look something different, as highlighted.
How could I do so that the imegen of the first post of the blog would be centered instead of on one side like the others?
And secondly, is there any way that the size of your typography of this first post is also bigger?
There are no default options for this, but maybe with a bit of CSS that you have already tried ...
Thanks for your work.
Hi there,
You have the option to use 2 columns which then you can make the first post featured:
https://docs.generatepress.com/article/using-columns-in-the-blog/
Featured post for one columns is a bit tricky but you can try some CSS like this:
.blog article:first-of-type .inside-article {
display: flex;
flex-direction: column;
align-items: center;
}
And to make the title and excerpt font bigger, this CSS should do:
.blog article:first-of-type .inside-article h2.entry-title {
font-size: 30px;
}
.blog article:first-of-type .inside-article .entry-summary {
font-size: 25px;
}
Adding CSS: https://docs.generatepress.com/article/adding-css/
Let me know :)
It has worked!
Only one detail remains, if you can help me. The featured image of the first article is still with the same dimensions, and it is small. Can you pass me some CSS code to adjust it to the width of the new format or in which I can change its dimensions?
Really, thank you very much for your work, it's incredible.
Victor
Try this:
@media (min-width: 769px) {
.blog article:first-of-type .post-image-aligned-left .post-image img {
max-width: 600px;
}
}