-
rrodda75
Hi there,
I am trying to increase the white space between my posts and the right sidebar and cannot work out how to do it!
I am using a single container and have my right sidebar fixed to 300px.Can you let me know what setting i can use to increase this spacing? I can’t use the separating space in the container layout settings, as that also then changes the spacing on the blog and category pages.
Do I need to use a layout or block element – will that work or just shrink the entire size of the page including the sidebar?
Also, can you let me know how I can prevent the sidebar showing at the bottom of posts for mobile?
Thanks,
Rachel -
Hi there,
I am trying to increase the white space between my posts and the right sidebar and cannot work out how to do it!
This CSS should work:
.one-container.right-sidebar .site-main { margin-right: 50px; }
Also, can you let me know how I can prevent the sidebar showing at the bottom of posts for mobile?
Not sure if I fully understand. Do you mean to hide the sidebar on mobile in single posts only?
If so this CSS should work:@media (max-width: 768px) { .single .sidebar { display: none; } }
Learn how to add CSS: https://docs.generatepress.com/article/adding-css/
Let me know 🙂
-
rrodda75
Perfect – thanks Leo – this worked.
On a side note, is custom Css the most efficient way to design the blog post layout, as I have now got quite a collection of custom CSS entries targeting specific designs for my blog posts.
Is it more efficient to set up a custom post layout using elements and blocks?
Cheers,
Rachel -
That’s a tough question to answer as it depends on what you are trying to achieve.
For this specific case, CSS is the most efficient method.
-
rrodda75
Thanks Leo.
-
No problem 🙂
- You must be logged in to reply to this topic.