Jump to content

Extending Blog Posts with Hidden Side Bar

Recommended Posts

Posted

Site URL: https://www.jayproffitt.com/mbb

I have created custom sidebar content for my blog/podcast page. I'm now hosting an additional podcast on my website, and I've been able to successfully hide the sidebar using a code injection. After this, the blog post content still won't extend into the area of the page where the sidebar should be, leaving a blank area on the right side of the page. I've managed a work-around by spacing the left side of each blog post and hiding post titles. Ideally, I'd like to have the right space usable again. Is this possible using a code injection as well?

Posted (edited)

Let's give this a go. Add the following to wherever your other blog CSS is.

/* begin blog hidden sidebar reclaim space */

  .collection-type-blog #page {
  
    display : flex;
    
    }
    
  .collection-type-blog.blog-sidebar-display-right .article-list,
  .collection-type-blog.blog-sidebar-display-right .article-wrapper
  
    {
    
      margin-right : auto;
      width : 100%;
      
      }
      
  .collection-type-blog.blog-sidebar-display-right #sidebar {
  
    position : unset;
    margin-left : 50px;
    
    }
    
  /* end blog hidden sidebar reclaim space */

Let us know how it goes.

Edited by creedon

Find my contributions useful? Please like, upvote, mark my answer as the best ( solution ), and see my profile. Thanks for your support! I am a Squarespace ( and other technological things ) consultant open for new projects.

  • 3 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.