Changing width of sidebar and main content section

  • Unknown's avatar

    Hi,

    How can I change the width of the sidebar so that it takes up less room? Also, I’d like to reduce the padding of the main content section so that I have more text per line in the articles.

    Merci!
    C.

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar

    Hi there,

    Try this to reduce the width of the sidebar:

    @media only screen and (min-width: 899px) {
    	.has_sidebar .site-main {
    		margin-right: 20%;
    	}
    
    	.has_sidebar .site-main:before {
    		right: 20%;
    	}
    
    	.has_sidebar .sidebar {
    		width: 20%;
    	}
    }

    The original width was 30%, so you might want to adjust the numbers till it suits your needs.

    This will also make your main content wider, but if you still want to reduce the padding, add this too to your CSS:

    @media only screen and (min-width: 899px) {
    	.has_sidebar .site-main {
    		padding-right: 0.875em;
    	}
    }

    Good luck!

    Regards,

    Michael

  • Unknown's avatar

    Hey Michael!

    Thanks for this! The sidebar changes worked great. But when applying the code for the main content area, I see that what I really need is to widen the txt portion only (a bit on the each side) and not the featured image. Is there a way to single that out?

    Merci!
    C.

  • Unknown's avatar

    Michael, you still around?
    C.

  • The topic ‘Changing width of sidebar and main content section’ is closed to new replies.