1

Change default Magento 2 theme to use a boxed layout instead of full width?

I'd like to change my Magento 2 theme to use a boxed layout instead of a full layout. I've already started customizing the theme by creating a directory in:

app/design/frontend/<Company_Name>/<Theme_name>/

And been customizing various areas using:

app/design/frontend/<Company_Name>/<Theme_name>/Magento_Catalog/

app/design/frontend/<Company_Name>/<Theme_name>/Magento_Theme/

app/design/frontend/<Company_Name>/<Theme_name>/Magento_Theme/web/css/source/_module.less

Etc, etc.

But, I've found that the site's layout itself is using a full width layout and I'd like to change that to a boxed layout. The theme's theme.xml is using the Magento/blank theme as a parent, also. <parent>Magento/blank</parent>

So basically just starting from scratch and wondering how I'd customize this theme to use a boxed layout.

Thank you.

2
  • 1
    When i'm inspecting both the luma and blank theme, they both have a max width set on the main container with .page-main {max-width: 1280px;}, so i'm not 100% sure what you mean when you say full width and boxed. Are you looking to have the header and the footer also be inside this container? – circlesix Feb 28 '18 at 22:58
  • @circlesix Odd, what I'm seeing is that the .page-wrapper is using a display:flex element, and a flex-direction:column element as well, then the page is broken down into page-header, nav-sections, page-main, and page-footer. The custom theme I'm using uses Magento/blank as the parent. – James Mar 2 '18 at 15:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.