Skip to content

Commit

Permalink
Replace background-attachment: fixed in docs (#5777)
Browse files Browse the repository at this point in the history
Fixed backgrounds have performance issues on large displays.
  • Loading branch information
Ryan P Kilby authored and carltongibson committed Jan 30, 2018
1 parent 769bc13 commit ece4171
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions docs_theme/css/default.css
Original file line number Diff line number Diff line change
Expand Up @@ -160,9 +160,19 @@ body, .navbar .navbar-inner .container-fluid{
margin: 0 auto;
}

body{
background: url("../img/grid.png") repeat-x;
background-attachment: fixed;
/* Replacement for `body { background-attachment: fixed; }`, which
has performance issues when scrolling on large displays. */
body::before {
content: ' ';
position: fixed;
width: 100%;
height: 100%;
top: 0;
left: 0;
background-color: #f8f8f8;
background: url(../img/grid.png) repeat-x;
will-change: transform;
z-index: -1;
}


Expand Down

0 comments on commit ece4171

Please sign in to comment.