Remove position: sticky polyfill

This commit is contained in:
Michael Rose 2016-03-16 16:47:28 -04:00
parent 1ce8926272
commit 6ab127f293
8 changed files with 20 additions and 47 deletions

View file

@ -6,6 +6,8 @@
margin-bottom: 2em; margin-bottom: 2em;
@include breakpoint($medium) { @include breakpoint($medium) {
@include span(10 of 12 last); @include span(10 of 12 last);
}
@include breakpoint($large) {
@include suffix(3 of 12); @include suffix(3 of 12);
} }
} }

View file

@ -3,6 +3,7 @@
========================================================================== */ ========================================================================== */
#main { #main {
position: relative;
@include container; @include container;
@include clearfix; @include clearfix;
margin-top: 2em; margin-top: 2em;
@ -13,6 +14,8 @@
.page { .page {
@include breakpoint($medium) { @include breakpoint($medium) {
@include span(10 of 12 last); @include span(10 of 12 last);
}
@include breakpoint($large) {
padding-right: $right-sidebar-width; padding-right: $right-sidebar-width;
} }
} }
@ -23,7 +26,6 @@
} }
.page__content { .page__content {
position: relative;
p, li { p, li {
font-size: 16px; font-size: 16px;
} }

View file

@ -8,15 +8,12 @@
color: $gray; color: $gray;
text-transform: uppercase; text-transform: uppercase;
letter-spacing: 1px; letter-spacing: 1px;
background-color: #fff; @include breakpoint($large) {
&.sticky { position: absolute;
@include breakpoint($large) { top: 0;
position: fixed; right: calc(50% - 512px + 2em); // 50% - 1/2 of wrapper's max-width + wrapper padding
top: 0; width: $right-sidebar-width;
right: calc(50% - 512px + 2em); // 50% - 1/2 of wrapper's max-width + wrapper padding padding-left: 2em;
width: $right-sidebar-width;
padding-left: 2em;
}
} }
} }
@ -36,6 +33,7 @@
padding: 0; padding: 0;
width: 100%; width: 100%;
list-style: none; list-style: none;
background-color: #fff;
border: 1px solid $border-color; border: 1px solid $border-color;
border-top: none; border-top: none;
border-bottom-right-radius: $border-radius; border-bottom-right-radius: $border-radius;

View file

@ -152,26 +152,6 @@ body:hover .visually-hidden button {
} }
/*
Sticky, fixed to top content
========================================================================== */
.sticky {
> * {
display: none;
}
@include breakpoint($small) {
@include clearfix();
position: -webkit-sticky;
position: sticky;
top: 3em;
> * {
display: block;
}
}
}
/* /*
Wells Wells
========================================================================== */ ========================================================================== */

View file

@ -92,10 +92,10 @@ $susy: (
gutter-position: after, gutter-position: after,
container: $large, container: $large,
global-box-sizing: border-box, global-box-sizing: border-box,
debug: ( // debug: (
image: show, // image: show,
color: blue, // color: blue,
output: overlay, // output: overlay,
toggle: top right, // toggle: top right,
), // ),
); );

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long