Skip to content

Commit

Permalink
Merge pull request #863 from alphagov/fix-main-wrapper-ie11
Browse files Browse the repository at this point in the history
Set display:block on `main` wrapper
  • Loading branch information
Jani Kraner authored Jul 3, 2018
2 parents 7a977b1 + 2f9b437 commit 6979369
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@

🔧 Fixes:

- Apply `display:block` to `.govuk-main-wrapper`

In IE11 `main` element is set to `display:inline` so padding
and margins aren't applied.
([PR #863](https://github.com/alphagov/govuk-frontend/pull/863)))

- Line-heights are now converted from pixels to relative 'unit-less' values
in order to prevent issues when resizing text in the browser.
([PR #837](https://github.com/alphagov/govuk-frontend/pull/837) and
Expand Down
4 changes: 4 additions & 0 deletions src/objects/_main-wrapper.scss
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@
@mixin govuk-main-wrapper {
@include govuk-responsive-padding(6, "top");
@include govuk-responsive-padding(6, "bottom");
// In IE11 the `main` element can be used, but is not recognized –
// meaning it's not defined in IE's default style sheet,
// so it uses CSS initial value, which is inline.
display: block;
}

// Use govuk-main-wrapper--l when you page does not have Breadcrumbs, phase banners or back links
Expand Down

0 comments on commit 6979369

Please sign in to comment.