How To Make Twenty Seventeen Full Width Of The Screen (Both Content And Sidebar Areas)

Posted on 19 December 2016 in Twenty Seventeen Theme Customisation
Comments: 42

The default Twenty Seventeen content area and sidebar use less than the full width of the screen, especially on a laptop or computer screen. The total width of these combined areas can use the full width.

The default width of the content area and sidebar.

The content area and sidebar made full width of the screen.

The full-width appearance should work throughout the site (e.g. single pages, single post & blog archives).

Where and how to make the width the content and sidebar areasĀ full screen:

In WordPress Admin > Appearance > Edit CSS.

Enter the CSS code below.

  • The two lines of code created the full-width effect for both mobile and computer screens.

The CSS code:

.wrap {
	/* margin-left: auto; */
	/* margin-right: auto; */
	max-width: 100%;
	/* padding-left: 2em; */
	/* padding-right: 2em; */
}
 
@media screen and (min-width: 48em) {
	.wrap {
		max-width: 100%;
		/* padding-left: 3em; */
		/* padding-right: 3em; */
	}
}
 
.page.page-one-column:not(.twentyseventeen-front-page) #primary {
	/*margin-left: auto;*/
	/*margin-right: auto;*/
	max-width: 100%;
}

@media screen and (min-width: 30em) {
	.page-one-column .panel-content .wrap
	{
		max-width: 100%;
	}
}
Share this:

Tags


Leave a Reply

Your email address will not be published. Required fields are marked *

  1. Hello, it's great! I've changed my page but I would like to change the footer like before, smaller. Could you help me? Thanks

        1. Hello

          Try putting #content before the first two .wrap tags so the first part of the code becomes:

          #content .wrap {
          /* margin-left: auto; */
          /* margin-right: auto; */
          max-width: 100%;
          /* padding-left: 2em; */
          /* padding-right: 2em; */
          }

          @media screen and (min-width: 48em) {
          #content .wrap {
          max-width: 100%;
          /* padding-left: 3em; */
          /* padding-right: 3em; */
          }
          }

  2. Hello Bharat! Your blog it's awesome. Thanks in advance.
    I was wondering how can I make the Images I upload to meet the Edges of the page?
    Thanks!

  3. it works but is there any way of doing the same with the menu because it feels weird for me having different margins for the menu and the content

  4. I try to set the 100% values to 80%, because want more width, but not 100%. When I put 80% value, it only works on some pages. It seems like it leaves 10% margin/padding on the left, and 20% margin/padding on the right.

      1. Its working here too, now. I replaced the whole CSS again. Think I messed up something when I copied and pasted here and there.

  5. This is fantastic! I've run into an issue. Making the site full screen messed up how my blog posts look. As I'm working in a staging site and reworking all my old posts anyway, I didn't think it would be a problem to fix them. However, when I go to a post to rework it - the visual is still for default and not what appears when I preview it. Suggestions?

  6. Hello
    Would really love to get this to work, but it somehow only resizes the wrap and the navigation. I can see my site header (logo and site name) indeed moves to the left. Yet, the actual content of the page remains in a very narrow column. The above hack does not seem to resize the content area of the page. Am I doing something wrong?.. Thanks for any help

      1. Hello Christophe.
        The code was working when in two column mode (set in WP-ADMIN > Appearance > Customizer > Theme Options) but not in one column mode. I have now updated the code to work also in one column mode. Thank you for pointing that out.

        1. Thanks for your reply Bharat,
          I am indeed using the 1 column option. Sorry to ask, but are you sure you have updated the code ? Maybe I missed something, but it seems to be the same as previously ?... Still does not work for PAGES. Too bad. If you can assist in any way, this would be great...

          1. Thanks Bharat. We are getting closer. It works fine for the pages. However it still does not seem to work for the HOMEPAGE (I use the static page option, with the blocks). I guess this page uses a specific class...
            I shall try to review when I have a chance....

          2. Hi Bharat, seems to be working. Thanks !!
            Let me play around bit with this code, as it looks good on mobiles (phone & ipad), but 100% seems a bit large on large monitors. I guess I need to play around with the "@media screen and (min-width: XXem)" and the "max-width: XXXpx !important;" to target only the required screen dimensions... Thanks for your great help.

      1. Yes, I saw that, but as I say I'm a bit rubbish at the whole coding thing. In my Admin screen I either have the Appearance -> editor (which brings up a whole load of CSS or the Additional CSS box in the customise screen. When I try pasting it into the Editor nothing happens, that is why I think I'm pasting it in the wrong place within the editor. Is that possible? Many thanks and I'm loving your site!

    1. Hello Manja, the code for the numbered navigation links are contained within the main content area block over various theme template files. I tried moving them out but that then disturbs the layout of the footer. This will require quite a bit of custom coding and I believe it is best to leave the navigation as it is under the main content area as if the sidebar content was higher than the main content area then the navigation links would be quite low on the page and that is why the code seems to be as it is.

  7. When we display a page on the "front page" how do we remove the page title that seems to sit in its own column taking up valuable screen space!

    1. Hello Scott, in WP-ADMIN > Appearance > Customise >Theme Options there is a setting to make the general layout to use one column or two column. This is a site-wide setting. To do it specifically on one page such as the home page this would require some custom coding that you can get done by a freelancer on a site like upwork.com

{"email":"Email address invalid","url":"Website address invalid","required":"Required field missing"}
Do NOT follow this link or you will be banned from the site!