Skip to content
This repository was archived by the owner on Jul 11, 2023. It is now read-only.

Commit b4f1389

Browse files
committed
Use Jekyll native Sass/SCSS preprocessor
- Move .scss files to default `_sass` folder - Configure Sass/SCSS in `_config.yml` - Run .scss files through Autoprefixer - Remove unnecessary npm scripts for building CSS - Close mmistakes#333
1 parent 27439c6 commit b4f1389

File tree

111 files changed

+127
-85
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

111 files changed

+127
-85
lines changed

_config.yml

+6
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,12 @@ kramdown:
145145
enable_coderay: false
146146

147147

148+
# Sass/SCSS
149+
sass:
150+
sass_dir: _sass
151+
style: compressed # http://sass-lang.com/documentation/file.SASS_REFERENCE.html#output_style
152+
153+
148154
# Outputting
149155
permalink: /:categories/:title/
150156
paginate: 5 # amount of posts to show

assets/_scss/_animations.scss _sass/_animations.scss

+9
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,15 @@
22
ANIMATIONS
33
========================================================================== */
44

5+
@-webkit-keyframes intro {
6+
0% {
7+
opacity: 0;
8+
}
9+
100% {
10+
opacity: 1;
11+
}
12+
}
13+
514
@keyframes intro {
615
0% {
716
opacity: 0;

assets/_scss/_archive.scss _sass/_archive.scss

+3-3
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
}
4242
}
4343

44-
// remove border
44+
/* remove border*/
4545
.page__content {
4646

4747
.archive__item-title {
@@ -129,8 +129,8 @@
129129
}
130130

131131
@include breakpoint($medium) {
132-
margin-left: 0; // reset before mixin does its thing
133-
margin-right: 0; // reset before mixin does its thing
132+
margin-left: 0; /* reset before mixin does its thing*/
133+
margin-right: 0; /* reset before mixin does its thing*/
134134
@include gallery(2.5 of 10);
135135

136136
.archive__item-teaser {

assets/_scss/_base.scss _sass/_base.scss

+10-4
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ tt, code, kbd, samp, pre {
129129
}
130130

131131
pre {
132-
overflow-x: auto; // add scrollbars to wide code blocks
132+
overflow-x: auto; /* add scrollbars to wide code blocks*/
133133
}
134134

135135
p > code,
@@ -147,7 +147,7 @@ td > code {
147147

148148
&:before, &:after {
149149
letter-spacing: -0.2em;
150-
content: "\00a0"; // non-breaking space
150+
content: "\00a0"; /* non-breaking space*/
151151
}
152152
}
153153

@@ -179,9 +179,12 @@ li ol {
179179
/* Figures and images */
180180

181181
figure {
182+
display: -webkit-box;
182183
display: flex;
183-
justify-content: space-between;
184-
align-items: flex-start;
184+
-webkit-box-pack: justify;
185+
justify-content: space-between;
186+
-webkit-box-align: start;
187+
align-items: flex-start;
185188
flex-wrap: wrap;
186189
margin: 2em 0;
187190

@@ -194,6 +197,7 @@ figure {
194197
img {
195198
width: 100%;
196199
border-radius: $border-radius;
200+
-webkit-transition: $global-transition;
197201
transition: $global-transition;
198202
}
199203

@@ -240,6 +244,7 @@ figcaption {
240244
color: inherit;
241245
text-decoration: none;
242246
border-bottom: 1px solid $light-gray;
247+
-webkit-transition: $global-transition;
243248
transition: $global-transition;
244249

245250
&:hover {
@@ -305,5 +310,6 @@ nav {
305310
========================================================================== */
306311

307312
b, i, strong, em, blockquote, p, q, span, figure, img, h1, h2, header, input, a, tr, td, form button, input[type="submit"], .btn, .highlight, .archive__item-teaser {
313+
-webkit-transition: $global-transition;
308314
transition: $global-transition;
309315
}

assets/_scss/_buttons.scss _sass/_buttons.scss

+3-4
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
}
3232

3333
.icon + .hidden {
34-
margin-left: -0.5em; // override for hidden text
34+
margin-left: -0.5em; /* override for hidden text*/
3535
}
3636

3737
/* fills width of parent container */
@@ -49,7 +49,7 @@
4949

5050
&--inverse {
5151
color: $gray !important;
52-
border: 1px solid $light-gray !important; // override
52+
border: 1px solid $light-gray !important; /* override*/
5353
background-color: #fff;
5454

5555
&:hover {
@@ -61,7 +61,7 @@
6161
/* light outline */
6262

6363
&--light-outline {
64-
border: 1px solid #fff !important; // override
64+
border: 1px solid #fff !important; /* override*/
6565
background-color: transparent;
6666
}
6767

@@ -111,7 +111,6 @@
111111
pointer-events: none;
112112
cursor: not-allowed;
113113
filter: alpha(opacity=65);
114-
-webkit-box-shadow: none;
115114
box-shadow: none;
116115
opacity: 0.65;
117116
}

assets/_scss/_footer.scss _sass/_footer.scss

+4-2
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,10 @@
1414
/* sticky footer fix end */
1515
margin-top: 3em;
1616
color: mix(#fff, $gray, 25%);
17-
animation: intro 0.3s both;
18-
animation-delay: 0.45s;
17+
-webkit-animation: intro 0.3s both;
18+
animation: intro 0.3s both;
19+
-webkit-animation-delay: 0.45s;
20+
animation-delay: 0.45s;
1921
background-color: $lighter-gray;
2022
border-top: 1px solid $light-gray;
2123

File renamed without changes.

assets/_scss/_masthead.scss _sass/_masthead.scss

+4-2
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,10 @@
55
.masthead {
66
position: relative;
77
border-bottom: 1px solid $border-color;
8-
animation: intro 0.3s both;
9-
animation-delay: 0.15s;
8+
-webkit-animation: intro 0.3s both;
9+
animation: intro 0.3s both;
10+
-webkit-animation-delay: 0.15s;
11+
animation-delay: 0.15s;
1012
z-index: 20;
1113

1214
&__inner-wrap {

assets/_scss/_mixins.scss _sass/_mixins.scss

+20-17
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
========================================================================== */
44

55
%tab-focus {
6-
// Default
6+
/* Default*/
77
outline: thin dotted $warning-color;
8-
// Webkit
8+
/* Webkit*/
99
outline: 5px auto $warning-color;
1010
outline-offset: -2px;
1111
}
@@ -23,21 +23,24 @@
2323
Bourbon clearfix
2424
========================================================================== */
2525

26-
// Provides an easy way to include a clearfix for containing floats.
27-
//
28-
// @link http://cssmojo.com/latest_new_clearfix_so_far/
29-
//
30-
// @example scss - Usage
31-
// .element {
32-
// @include clearfix;
33-
// }
34-
//
35-
// @example css - CSS Output
36-
// .element::after {
37-
// clear: both;
38-
// content: "";
39-
// display: table;
40-
// }
26+
/*
27+
* Provides an easy way to include a clearfix for containing floats.
28+
* link http://cssmojo.com/latest_new_clearfix_so_far/
29+
*
30+
* example scss - Usage
31+
*
32+
* .element {
33+
* @include clearfix;
34+
* }
35+
*
36+
* example css - CSS Output
37+
*
38+
* .element::after {
39+
* clear: both;
40+
* content: "";
41+
* display: table;
42+
* }
43+
*/
4144

4245
@mixin clearfix {
4346
clear: both;

assets/_scss/_navigation.scss _sass/_navigation.scss

+12-5
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,10 @@
1414
padding-left: 2em;
1515
padding-right: 2em;
1616
font-family: $sans-serif;
17-
animation: intro 0.3s both;
18-
animation-delay: 0.30s;
17+
-webkit-animation: intro 0.3s both;
18+
animation: intro 0.3s both;
19+
-webkit-animation-delay: 0.30s;
20+
animation-delay: 0.30s;
1921

2022
@include breakpoint($large) {
2123
padding-left: 1em;
@@ -232,12 +234,17 @@
232234
height: 4px;
233235
background: mix(#fff, $primary-color, 50%);
234236
width: 100%;
237+
-webkit-transition: $global-transition;
235238
transition: $global-transition;
236-
transform: scaleX(0); // hide
239+
-webkit-transform: scaleX(0);
240+
-ms-transform: scaleX(0);
241+
transform: scaleX(0); /* hide*/
237242
}
238243

239244
&:hover:before {
240-
transform: scaleX(1); // reveal
245+
-webkit-transform: scaleX(1);
246+
-ms-transform: scaleX(1);
247+
transform: scaleX(1); /* reveal*/
241248
}
242249
}
243250
}
@@ -414,7 +421,7 @@
414421
font-weight: normal;
415422
}
416423

417-
// hide sub sub links on small screens
424+
/* hide sub sub links on small screens*/
418425
li > ul li {
419426
display: none;
420427

assets/_scss/_notices.scss _sass/_notices.scss

+7-7
Original file line numberDiff line numberDiff line change
@@ -11,34 +11,34 @@
1111
*/
1212

1313
@mixin notice($notice-color) {
14-
margin: 2em 0 !important; // override
14+
margin: 2em 0 !important; /* override*/
1515
padding: 1em;
1616
font-family: $global-font-family;
1717
font-size: $type-size-6 !important;
18-
text-indent: initial; // override
18+
text-indent: initial; /* override*/
1919
background-color: mix(#fff, $notice-color, 90%);
2020
border-radius: $border-radius;
2121
box-shadow: 0 1px 1px rgba($notice-color, 0.25);
2222

2323
h4 {
24-
margin-top: 0 !important; // override
24+
margin-top: 0 !important; /* override*/
2525
margin-bottom: 0.75em;
2626
}
2727

2828
@at-root .page__content #{&} h4 {
29-
// using at-root to override .page-content h4 font size
29+
/* using at-root to override .page-content h4 font size*/
3030
margin-bottom: 0;
3131
font-size: 1em;
3232
}
3333

3434
p {
3535
&:last-child {
36-
margin-bottom: 0 !important; // override
36+
margin-bottom: 0 !important; /* override*/
3737
}
3838
}
3939

4040
h4 + p {
41-
// remove space above paragraphs that appear directly after notice headline
41+
/* remove space above paragraphs that appear directly after notice headline*/
4242
margin-top: 0;
4343
padding-top: 0;
4444
}
@@ -57,7 +57,7 @@
5757

5858
ul {
5959
&:last-child {
60-
margin-bottom: 0; // override
60+
margin-bottom: 0; /* override*/
6161
}
6262
}
6363
}

assets/_scss/_page.scss _sass/_page.scss

+13-7
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,10 @@
88
margin-top: 2em;
99
padding-left: 1em;
1010
padding-right: 1em;
11-
animation: intro 0.3s both;
12-
animation-delay: 0.35s;
11+
-webkit-animation: intro 0.3s both;
12+
animation: intro 0.3s both;
13+
-webkit-animation-delay: 0.35s;
14+
animation-delay: 0.35s;
1315

1416
@include breakpoint($x-large) {
1517
max-width: $x-large;
@@ -63,7 +65,7 @@
6365
p {
6466
margin: 0 0 $indent-var;
6567

66-
// sibling indentation
68+
/* sibling indentation*/
6769
@if $paragraph-indent == true {
6870
& + p {
6971
text-indent: $indent-var;
@@ -111,8 +113,10 @@
111113
position: relative;
112114
margin-bottom: 2em;
113115
@include clearfix;
114-
animation: intro 0.3s both;
115-
animation-delay: 0.25s;
116+
-webkit-animation: intro 0.3s both;
117+
animation: intro 0.3s both;
118+
-webkit-animation-delay: 0.25s;
119+
animation-delay: 0.25s;
116120

117121
&--overlay {
118122
position: relative;
@@ -122,8 +126,10 @@
122126
background-size: cover;
123127
background-repeat: no-repeat;
124128
background-position: center;
125-
animation: intro 0.3s both;
126-
animation-delay: 0.25s;
129+
-webkit-animation: intro 0.3s both;
130+
animation: intro 0.3s both;
131+
-webkit-animation-delay: 0.25s;
132+
animation-delay: 0.25s;
127133

128134
a {
129135
color: #fff;
File renamed without changes.

0 commit comments

Comments
 (0)