leonids 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.gitignore +6 -0
- data/README.md +36 -0
- data/_includes/disqus.html +12 -0
- data/_includes/footer.html +3 -0
- data/_includes/head.html +21 -0
- data/_includes/js.html +14 -0
- data/_includes/nav.html +33 -0
- data/_includes/read_time.html +8 -0
- data/_includes/sidebar.html +27 -0
- data/_includes/social-links.html +40 -0
- data/_layouts/default.html +22 -0
- data/_layouts/page.html +21 -0
- data/_layouts/post.html +67 -0
- data/_layouts/post_listing.html +62 -0
- data/_sass/components/_buttons.scss +92 -0
- data/_sass/components/_global.scss +122 -0
- data/_sass/components/_grid.scss +125 -0
- data/_sass/components/_helpers.scss +194 -0
- data/_sass/components/_mixins.scss +280 -0
- data/_sass/components/_normalize.scss +427 -0
- data/_sass/components/_syntax-highlighting.scss +124 -0
- data/_sass/components/_typography.scss +98 -0
- data/_sass/components/_variables.scss +79 -0
- data/_sass/pages/_archive.scss +47 -0
- data/_sass/pages/_layout.scss +91 -0
- data/_sass/pages/_post.scss +248 -0
- data/_sass/pages/_tags.scss +58 -0
- data/categories/index.html +18 -0
- data/css/font-awesome.min.css +4 -0
- data/css/main.scss +27 -0
- data/favicon.ico +0 -0
- data/favicon.png +0 -0
- data/fonts/FontAwesome.otf +0 -0
- data/fonts/fontawesome-webfont.eot +0 -0
- data/fonts/fontawesome-webfont.svg +640 -0
- data/fonts/fontawesome-webfont.ttf +0 -0
- data/fonts/fontawesome-webfont.woff +0 -0
- data/fonts/fontawesome-webfont.woff2 +0 -0
- data/img/avatar.jpg +0 -0
- data/img/leonids-logo.png +0 -0
- data/index.html +4 -0
- data/js/jquery-2.1.4.min.js +4 -0
- data/js/main.js +2 -0
- data/leonids.gemspec +22 -0
- data/screenshot.png +0 -0
- metadata +146 -0
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Global setting
|
|
3
|
+
*/
|
|
4
|
+
*,
|
|
5
|
+
*:before,
|
|
6
|
+
*:after {
|
|
7
|
+
@include box-sizing;
|
|
8
|
+
}
|
|
9
|
+
.notice {
|
|
10
|
+
border: 1px solid lighten($text-color, 45%);
|
|
11
|
+
border-radius: 0.4em;
|
|
12
|
+
padding: 0.5em 1em;
|
|
13
|
+
}
|
|
14
|
+
img {
|
|
15
|
+
height: auto;
|
|
16
|
+
max-width: 100%;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
// Tables
|
|
20
|
+
table,
|
|
21
|
+
th,
|
|
22
|
+
td {
|
|
23
|
+
border: none;
|
|
24
|
+
}
|
|
25
|
+
.table {
|
|
26
|
+
display: table;
|
|
27
|
+
}
|
|
28
|
+
.table-cell {
|
|
29
|
+
display: table-cell;
|
|
30
|
+
}
|
|
31
|
+
.table-top {
|
|
32
|
+
vertical-align: top;
|
|
33
|
+
}
|
|
34
|
+
.table-middle {
|
|
35
|
+
vertical-align: middle;
|
|
36
|
+
}
|
|
37
|
+
.table-bottom {
|
|
38
|
+
vertical-align: bottom;
|
|
39
|
+
}
|
|
40
|
+
table {
|
|
41
|
+
width: 100%;
|
|
42
|
+
display: table;
|
|
43
|
+
&.bordered > thead > tr,
|
|
44
|
+
&.bordered > tbody > tr {
|
|
45
|
+
border-bottom: 1px solid $table-border-color;
|
|
46
|
+
}
|
|
47
|
+
&.striped > tbody {
|
|
48
|
+
> tr:nth-child(odd) {
|
|
49
|
+
background-color: $table-striped-color;
|
|
50
|
+
}
|
|
51
|
+
> tr > td {
|
|
52
|
+
border-radius: 0;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
&.highlight > tbody > tr {
|
|
56
|
+
@include transition(background-color .25s ease);
|
|
57
|
+
&:hover {
|
|
58
|
+
background-color: $table-striped-color;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
&.centered {
|
|
62
|
+
thead tr th,
|
|
63
|
+
tbody tr td,
|
|
64
|
+
tfoot tr td {
|
|
65
|
+
text-align: center;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
thead {
|
|
70
|
+
border-bottom: 1px solid $table-border-color;
|
|
71
|
+
}
|
|
72
|
+
td,
|
|
73
|
+
th {
|
|
74
|
+
padding: 15px 5px;
|
|
75
|
+
display: table-cell;
|
|
76
|
+
text-align: left;
|
|
77
|
+
vertical-align: middle;
|
|
78
|
+
border-radius: 2px;
|
|
79
|
+
}
|
|
80
|
+
tfoot {
|
|
81
|
+
border-top: 1px solid $table-border-color;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
// Global transition
|
|
85
|
+
b,
|
|
86
|
+
i,
|
|
87
|
+
strong,
|
|
88
|
+
em,
|
|
89
|
+
blockquote,
|
|
90
|
+
p,
|
|
91
|
+
q,
|
|
92
|
+
span,
|
|
93
|
+
figure,
|
|
94
|
+
img,
|
|
95
|
+
h1,
|
|
96
|
+
h2,
|
|
97
|
+
header,
|
|
98
|
+
input,
|
|
99
|
+
a {
|
|
100
|
+
@include transition(all .1s ease);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
// Footer
|
|
104
|
+
footer {
|
|
105
|
+
text-align: center;
|
|
106
|
+
padding: 3em 0;
|
|
107
|
+
.heart-icon {
|
|
108
|
+
color: $danger;
|
|
109
|
+
text-shadow: 0 0 5px $white, 0 0 10px $danger;
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
.related-articles {
|
|
113
|
+
margin-top: 2em;
|
|
114
|
+
h4 {
|
|
115
|
+
font-family: $font-family-base;
|
|
116
|
+
}
|
|
117
|
+
ul {
|
|
118
|
+
margin: 0;
|
|
119
|
+
padding: 0;
|
|
120
|
+
list-style: none;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Grid
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
// Container
|
|
6
|
+
.container {
|
|
7
|
+
margin: 0 auto;
|
|
8
|
+
max-width: 1280px;
|
|
9
|
+
width: 90%;
|
|
10
|
+
}
|
|
11
|
+
@include media-query($medium-screen) {
|
|
12
|
+
.container {
|
|
13
|
+
width: 85%;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
@include media-query($large-screen) {
|
|
17
|
+
.container {
|
|
18
|
+
width: 70%;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
.container .row {
|
|
22
|
+
margin-left: (-1 * $gutter-width / 2);
|
|
23
|
+
margin-right: (-1 * $gutter-width / 2);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
// Section
|
|
27
|
+
.section {
|
|
28
|
+
padding-top: 1rem;
|
|
29
|
+
padding-bottom: 1rem;
|
|
30
|
+
|
|
31
|
+
&.no-pad {
|
|
32
|
+
padding: 0;
|
|
33
|
+
}
|
|
34
|
+
&.no-pad-bot {
|
|
35
|
+
padding-bottom: 0;
|
|
36
|
+
}
|
|
37
|
+
&.no-pad-top {
|
|
38
|
+
padding-top: 0;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
// Row and colum
|
|
43
|
+
.row {
|
|
44
|
+
margin-left: auto;
|
|
45
|
+
margin-right: auto;
|
|
46
|
+
|
|
47
|
+
// Clear floating children
|
|
48
|
+
&:after {
|
|
49
|
+
content: "";
|
|
50
|
+
display: table;
|
|
51
|
+
clear: both;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.col {
|
|
55
|
+
float: left;
|
|
56
|
+
@include box-sizing(border-box);
|
|
57
|
+
display:block;
|
|
58
|
+
vertical-align:top;
|
|
59
|
+
width:100%;
|
|
60
|
+
|
|
61
|
+
$i: 1;
|
|
62
|
+
@while $i <= $num-cols {
|
|
63
|
+
$perc: unquote((100 / ($num-cols / $i)) + "%");
|
|
64
|
+
&.s#{$i} {
|
|
65
|
+
width: $perc;
|
|
66
|
+
margin-left: 0;
|
|
67
|
+
}
|
|
68
|
+
$i: $i + 1;
|
|
69
|
+
}
|
|
70
|
+
$i: 1;
|
|
71
|
+
@while $i <= $num-cols {
|
|
72
|
+
$perc: unquote((100 / ($num-cols / $i)) + "%");
|
|
73
|
+
&.offset-s#{$i} {
|
|
74
|
+
margin-left: $perc;
|
|
75
|
+
}
|
|
76
|
+
$i: $i + 1;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
@include media-query($small-screen) {
|
|
81
|
+
|
|
82
|
+
$i: 1;
|
|
83
|
+
@while $i <= $num-cols {
|
|
84
|
+
$perc: unquote((100 / ($num-cols / $i)) + "%");
|
|
85
|
+
&.m#{$i} {
|
|
86
|
+
width: $perc;
|
|
87
|
+
margin-left: 0;
|
|
88
|
+
}
|
|
89
|
+
$i: $i + 1;
|
|
90
|
+
}
|
|
91
|
+
$i: 1;
|
|
92
|
+
@while $i <= $num-cols {
|
|
93
|
+
$perc: unquote((100 / ($num-cols / $i)) + "%");
|
|
94
|
+
&.offset-m#{$i} {
|
|
95
|
+
margin-left: $perc;
|
|
96
|
+
}
|
|
97
|
+
$i: $i + 1;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
@include media-query($medium-screen) {
|
|
103
|
+
|
|
104
|
+
$i: 1;
|
|
105
|
+
@while $i <= $num-cols {
|
|
106
|
+
$perc: unquote((100 / ($num-cols / $i)) + "%");
|
|
107
|
+
&.l#{$i} {
|
|
108
|
+
width: $perc;
|
|
109
|
+
margin-left: 0;
|
|
110
|
+
}
|
|
111
|
+
$i: $i + 1;
|
|
112
|
+
}
|
|
113
|
+
$i: 1;
|
|
114
|
+
@while $i <= $num-cols {
|
|
115
|
+
$perc: unquote((100 / ($num-cols / $i)) + "%");
|
|
116
|
+
&.offset-l#{$i} {
|
|
117
|
+
margin-left: $perc;
|
|
118
|
+
}
|
|
119
|
+
$i: $i + 1;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
}
|
|
125
|
+
}
|
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Helpers
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
// Displays
|
|
6
|
+
.block { display: block }
|
|
7
|
+
.inline-block { display: inline-block }
|
|
8
|
+
|
|
9
|
+
.hidden-md {
|
|
10
|
+
display: none;
|
|
11
|
+
@include media-query($medium-screen) {
|
|
12
|
+
display: inline-block;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.radius-box {
|
|
17
|
+
border-radius: 10px;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.radius-ls {
|
|
21
|
+
border-bottom-left-radius: 3px;
|
|
22
|
+
border-top-left-radius: 3px;
|
|
23
|
+
}
|
|
24
|
+
.radius-rs {
|
|
25
|
+
border-bottom-right-radius: 3px;
|
|
26
|
+
border-top-right-radius: 3px;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.radius-l1 {
|
|
30
|
+
border-bottom-left-radius: 10px;
|
|
31
|
+
border-top-left-radius: 10px;
|
|
32
|
+
}
|
|
33
|
+
.radius-r1 {
|
|
34
|
+
border-bottom-right-radius: 10px;
|
|
35
|
+
border-top-right-radius: 10px;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
// Margin helpers
|
|
39
|
+
.m0 { margin: 0 }
|
|
40
|
+
.mt0 { margin-top: 0 }
|
|
41
|
+
.mr0 { margin-right: 0 }
|
|
42
|
+
.mb0 { margin-bottom: 0 }
|
|
43
|
+
.ml0 { margin-left: 0 }
|
|
44
|
+
|
|
45
|
+
.ms { margin: .25em }
|
|
46
|
+
.mts { margin-top: .25em }
|
|
47
|
+
.mbs { margin-bottom: .25em }
|
|
48
|
+
.mrs { margin-right: .25em }
|
|
49
|
+
.mls { margin-left: .25em }
|
|
50
|
+
|
|
51
|
+
.mm { margin: .5em }
|
|
52
|
+
.mtm { margin-top: .5em }
|
|
53
|
+
.mbm { margin-bottom: .5em }
|
|
54
|
+
.mrm { margin-right: .5em }
|
|
55
|
+
.mlm { margin-left: .5em }
|
|
56
|
+
|
|
57
|
+
.m1 { margin: $base-space-unit }
|
|
58
|
+
.mt1 { margin-top: $base-space-unit }
|
|
59
|
+
.mb1 { margin-bottom: $base-space-unit }
|
|
60
|
+
.mr1 { margin-right: $base-space-unit }
|
|
61
|
+
.ml1 { margin-left: $base-space-unit }
|
|
62
|
+
|
|
63
|
+
.m2 { margin: $base-space-unit*2 }
|
|
64
|
+
.mt2 { margin-top: $base-space-unit*2 }
|
|
65
|
+
.mb2 { margin-bottom: $base-space-unit*2 }
|
|
66
|
+
.mr2 { margin-right: $base-space-unit*2 }
|
|
67
|
+
.ml2 { margin-left: $base-space-unit*2 }
|
|
68
|
+
|
|
69
|
+
// Padding helpers
|
|
70
|
+
.p0 { padding: 0 }
|
|
71
|
+
.pt0 { padding-top: 0 }
|
|
72
|
+
.pr0 { padding-right: 0 }
|
|
73
|
+
.pb0 { padding-bottom: 0 }
|
|
74
|
+
.pl0 { padding-left: 0 }
|
|
75
|
+
|
|
76
|
+
.ps { padding: .25em }
|
|
77
|
+
.pts { padding-top: .25em }
|
|
78
|
+
.pbs { padding-bottom: .25em }
|
|
79
|
+
.prs { padding-right: .25em }
|
|
80
|
+
.pls { padding-left: .25em }
|
|
81
|
+
|
|
82
|
+
.pm { padding: .5em }
|
|
83
|
+
.ptm { padding-top: .5em }
|
|
84
|
+
.pbm { padding-bottom: .5em }
|
|
85
|
+
.prm { padding-right: .5em }
|
|
86
|
+
.plm { padding-left: .5em }
|
|
87
|
+
|
|
88
|
+
.p1 { padding: 1em }
|
|
89
|
+
.pt1 { padding-top: 1em }
|
|
90
|
+
.pr1 { padding-right: 1em }
|
|
91
|
+
.pb1 { padding-bottom: 1em }
|
|
92
|
+
.pl1 { padding-left: 1em }
|
|
93
|
+
|
|
94
|
+
.p2 { padding: 1em*2 }
|
|
95
|
+
.pt2 { padding-top: 1em*2 }
|
|
96
|
+
.pr2 { padding-right: 1em*2 }
|
|
97
|
+
.pb2 { padding-bottom: 1em*2 }
|
|
98
|
+
.pl2 { padding-left: 1em*2 }
|
|
99
|
+
|
|
100
|
+
.pb5 { padding-bottom: 1em*5 }
|
|
101
|
+
|
|
102
|
+
// Padding small
|
|
103
|
+
.pads { padding: .25em }
|
|
104
|
+
|
|
105
|
+
// Padding medium
|
|
106
|
+
.padm { padding: .5em }
|
|
107
|
+
|
|
108
|
+
// Padding large
|
|
109
|
+
.padl { padding: 1em }
|
|
110
|
+
|
|
111
|
+
// Padding small left :: right
|
|
112
|
+
.padsx {
|
|
113
|
+
padding-left: .25em;
|
|
114
|
+
padding-right: .25em;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
// Padding medium left :: right
|
|
118
|
+
.padmx {
|
|
119
|
+
padding-left: .5em;
|
|
120
|
+
padding-right: .5em;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
// Padding large left :: right
|
|
124
|
+
.padlx {
|
|
125
|
+
padding-left: 1em;
|
|
126
|
+
padding-right: 1em;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
// Padding small top :: bottom
|
|
130
|
+
.padsy {
|
|
131
|
+
padding-top: .25em;
|
|
132
|
+
padding-bottom: .25em;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
// Padding medium top :: bottom
|
|
136
|
+
.padmy {
|
|
137
|
+
padding-top: .5em;
|
|
138
|
+
padding-bottom: .5em;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
// Padding large top :: bottom
|
|
142
|
+
.padly {
|
|
143
|
+
padding-top: 1em;
|
|
144
|
+
padding-bottom: 1em;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
// Colors helpers
|
|
148
|
+
.primary-text-color {
|
|
149
|
+
color: $primary;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
.primary-bg-color {
|
|
153
|
+
background-color: $primary;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.secondary-text-color {
|
|
157
|
+
color: $secondary;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.secondary-bg-color {
|
|
161
|
+
background-color: $secondary;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.success-text-color {
|
|
165
|
+
color: $success;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
.success-bg-color {
|
|
169
|
+
background-color: $success;
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
.danger-text-color {
|
|
173
|
+
color: $danger;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.danger-bg-color {
|
|
177
|
+
background-color: $danger;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
.info-text-color {
|
|
181
|
+
color: $info;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
.info-bg-color {
|
|
185
|
+
background-color: $info;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
.warning-text-color {
|
|
189
|
+
color: $warning;
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
.warning-bg-color {
|
|
193
|
+
background-color: $warning;
|
|
194
|
+
}
|
|
@@ -0,0 +1,280 @@
|
|
|
1
|
+
/* Utility mixins
|
|
2
|
+
========================================================================== */
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Clearfix for clearing floats like a boss h5bp.com/q
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
@mixin clearfix {
|
|
9
|
+
*zoom: 1;
|
|
10
|
+
&:before,
|
|
11
|
+
&:after {
|
|
12
|
+
display: table;
|
|
13
|
+
content: "";
|
|
14
|
+
line-height: 0;
|
|
15
|
+
}
|
|
16
|
+
&:after {
|
|
17
|
+
clear: both;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* Media query
|
|
23
|
+
*/
|
|
24
|
+
|
|
25
|
+
@mixin media-query($device) {
|
|
26
|
+
@media only screen and (min-width: $device) {
|
|
27
|
+
@content;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* Webkit-style focus
|
|
33
|
+
*/
|
|
34
|
+
|
|
35
|
+
@mixin tab-focus() {
|
|
36
|
+
/* Default */
|
|
37
|
+
outline: thin dotted #333;
|
|
38
|
+
/* Webkit */
|
|
39
|
+
outline: 5px auto -webkit-focus-ring-color;
|
|
40
|
+
outline-offset: -2px;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* Center-align a block level element
|
|
45
|
+
*/
|
|
46
|
+
|
|
47
|
+
@mixin center-block() {
|
|
48
|
+
display: block;
|
|
49
|
+
margin-left: auto;
|
|
50
|
+
margin-right: auto;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* Hide text overflow and end with ...
|
|
56
|
+
*/
|
|
57
|
+
|
|
58
|
+
@mixin text-overflow() {
|
|
59
|
+
overflow: hidden;
|
|
60
|
+
text-overflow: ellipsis;
|
|
61
|
+
white-space: nowrap;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
/* Gradient mixins
|
|
66
|
+
========================================================================== */
|
|
67
|
+
|
|
68
|
+
@mixin horizontal($startColor : $white, $endColor : $lightergrey) {
|
|
69
|
+
background-color: $endColor;
|
|
70
|
+
background-image : -webkit-gradient(linear, 0 0, 100% 0, from($startColor), to($endColor)); // Safari 4+, Chrome 2+
|
|
71
|
+
background-image : -webkit-linear-gradient(left, $startColor, $endColor); // Safari 5.1+, Chrome 10+
|
|
72
|
+
background-image : -moz-linear-gradient(left, $startColor, $endColor); // FF 3.6+
|
|
73
|
+
background-image : -ms-linear-gradient(left, $startColor, $endColor); // IE10
|
|
74
|
+
background-image : -o-linear-gradient(left, $startColor, $endColor); // Opera 11.10
|
|
75
|
+
background-image : linear-gradient(left, $startColor, $endColor); // W3C
|
|
76
|
+
background-repeat : repeat-x;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
@mixin vertical($startColor : $white, $endColor: $lightergrey) {
|
|
80
|
+
background-image : -webkit-gradient(linear, 0 0, 0 100%, from($startColor), to($endColor)); // Safari 4+, Chrome 2+
|
|
81
|
+
background-image : -webkit-linear-gradient(top, $startColor, $endColor); // Safari 5.1+, Chrome 10+
|
|
82
|
+
background-color : $endColor;
|
|
83
|
+
background-image : -moz-linear-gradient(top, $startColor, $endColor); // FF 3.6+
|
|
84
|
+
background-image : -ms-linear-gradient(top, $startColor, $endColor); // IE10
|
|
85
|
+
background-image : -o-linear-gradient(top, $startColor, $endColor); // Opera 11.10
|
|
86
|
+
background-image : linear-gradient(top, $startColor, $endColor); // W3C
|
|
87
|
+
background-repeat : repeat-x;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
@mixin directional($startColor : $white, $endColor : $lightergrey, $deg : 45deg) {
|
|
91
|
+
background-color : $endColor;
|
|
92
|
+
background-image : -moz-linear-gradient($deg, $startColor, $endColor); // FF 3.6+
|
|
93
|
+
background-image : -ms-linear-gradient($deg, $startColor, $endColor); // IE10
|
|
94
|
+
background-image : -webkit-linear-gradient($deg, $startColor, $endColor); // Safari 5.1+, Chrome 10+
|
|
95
|
+
background-image : -o-linear-gradient($deg, $startColor, $endColor); // Opera 11.10
|
|
96
|
+
background-image : linear-gradient($deg, $startColor, $endColor); // W3C
|
|
97
|
+
background-repeat : repeat-x;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
// .bordered(COLOR, COLOR, COLOR, COLOR);
|
|
101
|
+
@mixin bordered($top-color: #eee, $right-color: #eee, $bottom-color: #eee, $left-color: #eee) {
|
|
102
|
+
border-top : solid 1px $top-color;
|
|
103
|
+
border-left : solid 1px $left-color;
|
|
104
|
+
border-right : solid 1px $right-color;
|
|
105
|
+
border-bottom : solid 1px $bottom-color;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
/* Rounded corners
|
|
109
|
+
========================================================================== */
|
|
110
|
+
|
|
111
|
+
/**
|
|
112
|
+
* Round all corners
|
|
113
|
+
* example: @include rounded(4px);
|
|
114
|
+
*/
|
|
115
|
+
|
|
116
|
+
@mixin rounded($radius:4px) {
|
|
117
|
+
border-radius : $radius;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
/**
|
|
121
|
+
* Round individual corners (top right, bottom right, bottom left, top left)
|
|
122
|
+
* example: @include border-radius(4px, 0, 0, 4px);
|
|
123
|
+
*/
|
|
124
|
+
|
|
125
|
+
@mixin border-radius($topright: 0, $bottomright: 0, $bottomleft: 0, $topleft: 0) {
|
|
126
|
+
border-top-right-radius: $topright;
|
|
127
|
+
border-bottom-right-radius: $bottomright;
|
|
128
|
+
border-bottom-left-radius: $bottomleft;
|
|
129
|
+
border-top-left-radius: $topleft;
|
|
130
|
+
-webkit-background-clip: padding-box;
|
|
131
|
+
-moz-background-clip: padding;
|
|
132
|
+
background-clip: padding-box;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
/**
|
|
136
|
+
* Box shadow
|
|
137
|
+
* example: @include box-shadow(HORIZONTAL VERTICAL BLUR COLOR));
|
|
138
|
+
*/
|
|
139
|
+
|
|
140
|
+
@mixin box-shadow($shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26)) {
|
|
141
|
+
-webkit-box-shadow: $shadow;
|
|
142
|
+
-moz-box-shadow: $shadow;
|
|
143
|
+
box-shadow: $shadow;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
/**
|
|
147
|
+
* Drop shadow
|
|
148
|
+
* example: @include drop-shadow(HORIZONTAL, VERTICAL, BLUR, ALPHA);
|
|
149
|
+
*/
|
|
150
|
+
|
|
151
|
+
@mixin drop-shadow($x-axis: 0, $y-axis: 1px, $blur: 2px, $alpha: 0.1) {
|
|
152
|
+
-webkit-box-shadow: $x-axis $y-axis $blur rgba(0, 0, 0, $alpha);
|
|
153
|
+
-moz-box-shadow: $x-axis $y-axis $blur rgba(0, 0, 0, $alpha);
|
|
154
|
+
box-shadow: $x-axis $y-axis $blur rgba(0, 0, 0, $alpha);
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
/**
|
|
158
|
+
* Text shadow
|
|
159
|
+
* example: @include text-shadow(0 2px 3px rgba(0,0,0,.25));
|
|
160
|
+
*/
|
|
161
|
+
|
|
162
|
+
@mixin text-shadow($shadow: 0 2px 3px rgba(0,0,0,.25)) {
|
|
163
|
+
text-shadow: $shadow; }
|
|
164
|
+
|
|
165
|
+
/**
|
|
166
|
+
* Opacity
|
|
167
|
+
* example: @include opacity(0.5); // 50% opacity
|
|
168
|
+
*/
|
|
169
|
+
|
|
170
|
+
@mixin opacity($opacity: 0.5) {
|
|
171
|
+
opacity: $opacity;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
/* Transformations
|
|
175
|
+
========================================================================== */
|
|
176
|
+
|
|
177
|
+
/**
|
|
178
|
+
* @include rotate(VALUEdeg);
|
|
179
|
+
*/
|
|
180
|
+
|
|
181
|
+
@mixin rotate($deg) {
|
|
182
|
+
-webkit-transform: rotate($deg);
|
|
183
|
+
-moz-transform: rotate($deg);
|
|
184
|
+
-ms-transform: rotate($deg);
|
|
185
|
+
-o-transform: rotate($deg);
|
|
186
|
+
transform: rotate($deg);
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
/**
|
|
190
|
+
* @include scale(VALUE);
|
|
191
|
+
*/
|
|
192
|
+
|
|
193
|
+
@mixin scale($ratio) {
|
|
194
|
+
-webkit-transform: scale($ratio);
|
|
195
|
+
-moz-transform: scale($ratio);
|
|
196
|
+
-ms-transform: scale($ratio);
|
|
197
|
+
-o-transform: scale($ratio);
|
|
198
|
+
transform: scale($ratio);
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
/**
|
|
202
|
+
* @include skew(VALUE, VALUE);
|
|
203
|
+
*/
|
|
204
|
+
|
|
205
|
+
@mixin skew($x: 0, $y: 0) {
|
|
206
|
+
-webkit-transform: skew($x, $y);
|
|
207
|
+
-moz-transform: skew($x, $y);
|
|
208
|
+
-ms-transform: skew($x, $y);
|
|
209
|
+
-o-transform: skew($x, $y);
|
|
210
|
+
transform: skew($x, $y);
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
/**
|
|
214
|
+
* @include transition(PROPERTY DURATION DELAY(OPTIONAL) TIMING-FINCTION);
|
|
215
|
+
*/
|
|
216
|
+
|
|
217
|
+
@mixin transition($transition) {
|
|
218
|
+
-webkit-transition: $transition;
|
|
219
|
+
-moz-transition: $transition;
|
|
220
|
+
-ms-transition: $transition;
|
|
221
|
+
-o-transition: $transition;
|
|
222
|
+
transition: $transition;
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
/**
|
|
226
|
+
* @include translate(VALUE, VALUE);
|
|
227
|
+
*/
|
|
228
|
+
|
|
229
|
+
@mixin translate($x: 0, $y: 0) {
|
|
230
|
+
-webkit-transform: translate($x, $y);
|
|
231
|
+
-moz-transform: translate($x, $y);
|
|
232
|
+
-ms-transform: translate($x, $y);
|
|
233
|
+
-o-transform: translate($x, $y);
|
|
234
|
+
transform: translate($x, $y);
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
@mixin translate3d($x: 0, $y: 0, $z: 0) {
|
|
238
|
+
-webkit-transform: translate($x, $y, $z);
|
|
239
|
+
-moz-transform: translate($x, $y, $z);
|
|
240
|
+
-ms-transform: translate($x, $y, $z);
|
|
241
|
+
-o-transform: translate($x, $y, $z);
|
|
242
|
+
transform: translate($x, $y, $z);
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
@mixin animation($name, $duration: 300ms, $delay: 0, $ease: ease) {
|
|
246
|
+
-webkit-animation: $name $duration $delay $ease;
|
|
247
|
+
-moz-animation: $name $duration $delay $ease;
|
|
248
|
+
-ms-animation: $name $duration $delay $ease;
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
/**
|
|
253
|
+
* Box-sizing
|
|
254
|
+
* example: @include box-sizing(VALUE); //(border-box, padding-box, content-box)
|
|
255
|
+
*/
|
|
256
|
+
|
|
257
|
+
@mixin box-sizing($boxsize: border-box) {
|
|
258
|
+
-webkit-box-sizing: $boxsize;
|
|
259
|
+
-moz-box-sizing: $boxsize;
|
|
260
|
+
-ms-box-sizing: $boxsize;
|
|
261
|
+
box-sizing: $boxsize;
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
|
|
265
|
+
/**
|
|
266
|
+
* Hide from visual and speaking browsers
|
|
267
|
+
*/
|
|
268
|
+
|
|
269
|
+
@mixin hidden {
|
|
270
|
+
display: none;
|
|
271
|
+
visibility: hidden;
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
/**
|
|
275
|
+
* Hide but maintain layout
|
|
276
|
+
*/
|
|
277
|
+
|
|
278
|
+
@mixin invisible() {
|
|
279
|
+
visibility: hidden;
|
|
280
|
+
}
|