jekyll-theme-ethereal 0.4.4 → 0.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/_includes/contact_script.html +2 -2
- data/_includes/head.html +8 -1
- data/_includes/panel_map.html +70 -96
- data/_includes/scripts.html +8 -19
- data/_includes/search.html +8 -6
- data/_layouts/default.html +4 -4
- data/_sass/large/base/_page.scss +0 -0
- data/_sass/large/base/_reset.scss +0 -0
- data/_sass/large/base/_typography.scss +11 -0
- data/_sass/large/components/_actions.scss +0 -0
- data/_sass/large/components/_button.scss +0 -0
- data/_sass/large/components/_contact-icons.scss +0 -0
- data/_sass/{components → large/components}/_cookieconsent.scss +0 -0
- data/_sass/large/components/_form.scss +0 -0
- data/_sass/large/components/_gallery.scss +0 -0
- data/_sass/large/components/_grid-icons.scss +0 -0
- data/_sass/large/components/_icon.scss +0 -0
- data/_sass/large/components/_icons.scss +0 -0
- data/_sass/large/components/_image.scss +0 -0
- data/_sass/large/components/_list.scss +0 -0
- data/_sass/large/components/_panel-banner.scss +0 -0
- data/_sass/large/components/_panel-spotlight.scss +0 -0
- data/_sass/large/components/_panel.scss +0 -0
- data/_sass/large/components/_table.scss +0 -0
- data/_sass/large/layout/_footer.scss +0 -0
- data/_sass/large/layout/_header.scss +0 -0
- data/_sass/large/layout/_page-wrapper.scss +0 -0
- data/_sass/large/layout/_wrapper.scss +0 -0
- data/_sass/large.scss +48 -0
- data/_sass/libs/_breakpoints.scss +164 -164
- data/_sass/libs/_functions.scss +32 -32
- data/_sass/libs/_mixins.scss +225 -49
- data/_sass/libs/_vars.scss +40 -40
- data/_sass/libs/_vendor.scss +331 -331
- data/_sass/main/base/_page.scss +99 -0
- data/_sass/main/base/_reset.scss +76 -0
- data/_sass/main/base/_typography.scss +193 -0
- data/_sass/main/components/_actions.scss +63 -0
- data/_sass/main/components/_button.scss +154 -0
- data/_sass/main/components/_contact-icons.scss +72 -0
- data/_sass/main/components/_cookieconsent.scss +403 -0
- data/_sass/main/components/_form.scss +253 -0
- data/_sass/main/components/_gallery.scss +167 -0
- data/_sass/main/components/_grid-icons.scss +139 -0
- data/_sass/main/components/_icon.scss +33 -0
- data/_sass/main/components/_icons.scss +28 -0
- data/_sass/main/components/_image.scss +169 -0
- data/_sass/main/components/_list.scss +56 -0
- data/_sass/main/components/_panel-banner.scss +52 -0
- data/_sass/main/components/_panel-spotlight.scss +62 -0
- data/_sass/main/components/_panel.scss +224 -0
- data/_sass/main/components/_table.scss +81 -0
- data/_sass/main/layout/_footer.scss +30 -0
- data/_sass/main/layout/_header.scss +35 -0
- data/_sass/main/layout/_page-wrapper.scss +22 -0
- data/_sass/main/layout/_wrapper.scss +85 -0
- data/_sass/main.scss +24 -118
- data/_sass/medium/base/_page.scss +0 -0
- data/_sass/medium/base/_reset.scss +0 -0
- data/_sass/medium/base/_typography.scss +0 -0
- data/_sass/medium/components/_actions.scss +0 -0
- data/_sass/medium/components/_button.scss +0 -0
- data/_sass/medium/components/_contact-icons.scss +0 -0
- data/_sass/medium/components/_cookieconsent.scss +403 -0
- data/_sass/medium/components/_form.scss +0 -0
- data/_sass/medium/components/_gallery.scss +11 -0
- data/_sass/medium/components/_grid-icons.scss +0 -0
- data/_sass/medium/components/_icon.scss +0 -0
- data/_sass/medium/components/_icons.scss +0 -0
- data/_sass/medium/components/_image.scss +0 -0
- data/_sass/medium/components/_list.scss +0 -0
- data/_sass/medium/components/_panel-banner.scss +0 -0
- data/_sass/medium/components/_panel-spotlight.scss +0 -0
- data/_sass/medium/components/_panel.scss +0 -0
- data/_sass/medium/components/_table.scss +0 -0
- data/_sass/medium/layout/_footer.scss +0 -0
- data/_sass/medium/layout/_header.scss +0 -0
- data/_sass/medium/layout/_page-wrapper.scss +0 -0
- data/_sass/medium/layout/_wrapper.scss +0 -0
- data/_sass/medium.scss +47 -0
- data/_sass/noscript.scss +12 -12
- data/_sass/short/base/_page.scss +0 -0
- data/_sass/short/base/_reset.scss +0 -0
- data/_sass/short/base/_typography.scss +0 -0
- data/_sass/short/components/_actions.scss +0 -0
- data/_sass/short/components/_button.scss +0 -0
- data/_sass/short/components/_contact-icons.scss +0 -0
- data/_sass/short/components/_cookieconsent.scss +403 -0
- data/_sass/short/components/_form.scss +1 -0
- data/_sass/short/components/_gallery.scss +0 -0
- data/_sass/short/components/_grid-icons.scss +0 -0
- data/_sass/short/components/_icon.scss +0 -0
- data/_sass/short/components/_icons.scss +0 -0
- data/_sass/short/components/_image.scss +0 -0
- data/_sass/short/components/_list.scss +0 -0
- data/_sass/short/components/_panel-banner.scss +0 -0
- data/_sass/short/components/_panel-spotlight.scss +0 -0
- data/_sass/short/components/_panel.scss +0 -0
- data/_sass/short/components/_table.scss +0 -0
- data/_sass/short/layout/_footer.scss +0 -0
- data/_sass/short/layout/_header.scss +0 -0
- data/_sass/short/layout/_page-wrapper.scss +9 -0
- data/_sass/short/layout/_wrapper.scss +0 -0
- data/_sass/short.scss +48 -0
- data/_sass/small/base/_page.scss +17 -0
- data/_sass/small/base/_reset.scss +0 -0
- data/_sass/small/base/_typography.scss +67 -0
- data/_sass/small/components/_actions.scss +0 -0
- data/_sass/small/components/_button.scss +0 -0
- data/_sass/small/components/_contact-icons.scss +0 -0
- data/_sass/small/components/_cookieconsent.scss +403 -0
- data/_sass/small/components/_form.scss +27 -0
- data/_sass/small/components/_gallery.scss +38 -0
- data/_sass/small/components/_grid-icons.scss +29 -0
- data/_sass/small/components/_icon.scss +0 -0
- data/_sass/small/components/_icons.scss +0 -0
- data/_sass/small/components/_image.scss +0 -0
- data/_sass/small/components/_list.scss +0 -0
- data/_sass/small/components/_panel-banner.scss +37 -0
- data/_sass/small/components/_panel-spotlight.scss +18 -0
- data/_sass/small/components/_panel.scss +80 -0
- data/_sass/small/components/_table.scss +0 -0
- data/_sass/small/layout/_footer.scss +34 -0
- data/_sass/small/layout/_header.scss +0 -0
- data/_sass/small/layout/_page-wrapper.scss +12 -0
- data/_sass/small/layout/_wrapper.scss +26 -0
- data/_sass/small.scss +49 -0
- data/assets/css/cookieconsent.css +404 -0
- data/assets/css/fontawesome-all.min.css +1 -1
- data/assets/css/large.scss +5 -0
- data/assets/css/mapbox-gl.panel.css +27 -0
- data/assets/css/medium.scss +5 -0
- data/assets/css/short.scss +5 -0
- data/assets/css/small.scss +5 -0
- data/assets/js/cookieconsent.style.min.js +1 -0
- data/assets/js/{mapbox-gl.js → mapbox-gl.min.js} +0 -0
- metadata +124 -25
- data/_sass/base/_page.scss +0 -117
- data/_sass/base/_reset.scss +0 -76
- data/_sass/base/_typography.scss +0 -271
- data/_sass/components/_actions.scss +0 -63
- data/_sass/components/_button.scss +0 -154
- data/_sass/components/_contact-icons.scss +0 -72
- data/_sass/components/_form.scss +0 -279
- data/_sass/components/_gallery.scss +0 -218
- data/_sass/components/_grid-icons.scss +0 -166
- data/_sass/components/_icon.scss +0 -33
- data/_sass/components/_icons.scss +0 -28
- data/_sass/components/_image.scss +0 -169
- data/_sass/components/_list.scss +0 -56
- data/_sass/components/_panel-banner.scss +0 -90
- data/_sass/components/_panel-spotlight.scss +0 -81
- data/_sass/components/_panel.scss +0 -300
- data/_sass/components/_table.scss +0 -81
- data/_sass/layout/_footer.scss +0 -49
- data/_sass/layout/_header.scss +0 -37
- data/_sass/layout/_page-wrapper.scss +0 -43
- data/_sass/layout/_wrapper.scss +0 -118
data/_sass/libs/_vendor.scss
CHANGED
@@ -2,375 +2,375 @@
|
|
2
2
|
|
3
3
|
// Vars.
|
4
4
|
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
5
|
+
/// Vendor prefixes.
|
6
|
+
/// @var {list}
|
7
|
+
$vendor-prefixes: (
|
8
|
+
'-moz-',
|
9
|
+
'-webkit-',
|
10
|
+
'-ms-',
|
11
|
+
''
|
12
|
+
);
|
13
|
+
|
14
|
+
/// Properties that should be vendorized.
|
15
|
+
/// Data via caniuse.com, github.com/postcss/autoprefixer, and developer.mozilla.org
|
16
|
+
/// @var {list}
|
17
|
+
$vendor-properties: (
|
18
|
+
|
19
|
+
// Animation.
|
20
|
+
'animation',
|
21
|
+
'animation-delay',
|
22
|
+
'animation-direction',
|
23
|
+
'animation-duration',
|
24
|
+
'animation-fill-mode',
|
25
|
+
'animation-iteration-count',
|
26
|
+
'animation-name',
|
27
|
+
'animation-play-state',
|
28
|
+
'animation-timing-function',
|
29
|
+
|
30
|
+
// Appearance.
|
31
|
+
'appearance',
|
32
|
+
|
33
|
+
// Backdrop filter.
|
34
|
+
'backdrop-filter',
|
35
|
+
|
36
|
+
// Background image options.
|
37
|
+
'background-clip',
|
38
|
+
'background-origin',
|
39
|
+
'background-size',
|
40
|
+
|
41
|
+
// Box sizing.
|
42
|
+
'box-sizing',
|
43
|
+
|
44
|
+
// Clip path.
|
45
|
+
'clip-path',
|
46
|
+
|
47
|
+
// Filter effects.
|
48
|
+
'filter',
|
49
|
+
|
50
|
+
// Flexbox.
|
51
|
+
'align-content',
|
52
|
+
'align-items',
|
53
|
+
'align-self',
|
54
|
+
'flex',
|
55
|
+
'flex-basis',
|
56
|
+
'flex-direction',
|
57
|
+
'flex-flow',
|
58
|
+
'flex-grow',
|
59
|
+
'flex-shrink',
|
60
|
+
'flex-wrap',
|
61
|
+
'justify-content',
|
62
|
+
'order',
|
63
|
+
|
64
|
+
// Font feature.
|
65
|
+
'font-feature-settings',
|
66
|
+
'font-language-override',
|
67
|
+
'font-variant-ligatures',
|
68
|
+
|
69
|
+
// Font kerning.
|
70
|
+
'font-kerning',
|
71
|
+
|
72
|
+
// Fragmented borders and backgrounds.
|
73
|
+
'box-decoration-break',
|
74
|
+
|
75
|
+
// Grid layout.
|
76
|
+
'grid-column',
|
77
|
+
'grid-column-align',
|
78
|
+
'grid-column-end',
|
79
|
+
'grid-column-start',
|
80
|
+
'grid-row',
|
81
|
+
'grid-row-align',
|
82
|
+
'grid-row-end',
|
83
|
+
'grid-row-start',
|
84
|
+
'grid-template-columns',
|
85
|
+
'grid-template-rows',
|
86
|
+
|
87
|
+
// Hyphens.
|
88
|
+
'hyphens',
|
89
|
+
'word-break',
|
90
|
+
|
91
|
+
// Masks.
|
92
|
+
'mask',
|
93
|
+
'mask-border',
|
94
|
+
'mask-border-outset',
|
95
|
+
'mask-border-repeat',
|
96
|
+
'mask-border-slice',
|
97
|
+
'mask-border-source',
|
98
|
+
'mask-border-width',
|
99
|
+
'mask-clip',
|
100
|
+
'mask-composite',
|
101
|
+
'mask-image',
|
102
|
+
'mask-origin',
|
103
|
+
'mask-position',
|
104
|
+
'mask-repeat',
|
105
|
+
'mask-size',
|
106
|
+
|
107
|
+
// Multicolumn.
|
108
|
+
'break-after',
|
109
|
+
'break-before',
|
110
|
+
'break-inside',
|
111
|
+
'column-count',
|
112
|
+
'column-fill',
|
113
|
+
'column-gap',
|
114
|
+
'column-rule',
|
115
|
+
'column-rule-color',
|
116
|
+
'column-rule-style',
|
117
|
+
'column-rule-width',
|
118
|
+
'column-span',
|
119
|
+
'column-width',
|
120
|
+
'columns',
|
121
|
+
|
122
|
+
// Object fit.
|
123
|
+
'object-fit',
|
124
|
+
'object-position',
|
125
|
+
|
126
|
+
// Regions.
|
127
|
+
'flow-from',
|
128
|
+
'flow-into',
|
129
|
+
'region-fragment',
|
130
|
+
|
131
|
+
// Scroll snap points.
|
132
|
+
'scroll-snap-coordinate',
|
133
|
+
'scroll-snap-destination',
|
134
|
+
'scroll-snap-points-x',
|
135
|
+
'scroll-snap-points-y',
|
136
|
+
'scroll-snap-type',
|
137
|
+
|
138
|
+
// Shapes.
|
139
|
+
'shape-image-threshold',
|
140
|
+
'shape-margin',
|
141
|
+
'shape-outside',
|
142
|
+
|
143
|
+
// Tab size.
|
144
|
+
'tab-size',
|
145
|
+
|
146
|
+
// Text align last.
|
147
|
+
'text-align-last',
|
148
|
+
|
149
|
+
// Text decoration.
|
150
|
+
'text-decoration-color',
|
151
|
+
'text-decoration-line',
|
152
|
+
'text-decoration-skip',
|
153
|
+
'text-decoration-style',
|
154
|
+
|
155
|
+
// Text emphasis.
|
156
|
+
'text-emphasis',
|
157
|
+
'text-emphasis-color',
|
158
|
+
'text-emphasis-position',
|
159
|
+
'text-emphasis-style',
|
160
|
+
|
161
|
+
// Text size adjust.
|
162
|
+
'text-size-adjust',
|
163
|
+
|
164
|
+
// Text spacing.
|
165
|
+
'text-spacing',
|
166
|
+
|
167
|
+
// Transform.
|
168
|
+
'transform',
|
169
|
+
'transform-origin',
|
170
|
+
|
171
|
+
// Transform 3D.
|
172
|
+
'backface-visibility',
|
173
|
+
'perspective',
|
174
|
+
'perspective-origin',
|
175
|
+
'transform-style',
|
176
|
+
|
177
|
+
// Transition.
|
178
|
+
'transition',
|
179
|
+
'transition-delay',
|
180
|
+
'transition-duration',
|
181
|
+
'transition-property',
|
182
|
+
'transition-timing-function',
|
183
|
+
|
184
|
+
// Unicode bidi.
|
185
|
+
'unicode-bidi',
|
186
|
+
|
187
|
+
// User select.
|
188
|
+
'user-select',
|
189
|
+
|
190
|
+
// Writing mode.
|
191
|
+
'writing-mode',
|
192
|
+
|
193
|
+
);
|
194
|
+
|
195
|
+
/// Values that should be vendorized.
|
196
|
+
/// Data via caniuse.com, github.com/postcss/autoprefixer, and developer.mozilla.org
|
197
|
+
/// @var {list}
|
198
|
+
$vendor-values: (
|
199
|
+
|
200
|
+
// Cross fade.
|
201
|
+
'cross-fade',
|
202
|
+
|
203
|
+
// Element function.
|
204
|
+
'element',
|
205
|
+
|
206
|
+
// Filter function.
|
207
|
+
'filter',
|
208
|
+
|
209
|
+
// Flexbox.
|
210
|
+
'flex',
|
211
|
+
'inline-flex',
|
212
|
+
|
213
|
+
// Grab cursors.
|
214
|
+
'grab',
|
215
|
+
'grabbing',
|
216
|
+
|
217
|
+
// Gradients.
|
218
|
+
'linear-gradient',
|
219
|
+
'repeating-linear-gradient',
|
220
|
+
'radial-gradient',
|
221
|
+
'repeating-radial-gradient',
|
222
|
+
|
223
|
+
// Grid layout.
|
224
|
+
'grid',
|
225
|
+
'inline-grid',
|
226
|
+
|
227
|
+
// Image set.
|
228
|
+
'image-set',
|
229
229
|
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
230
|
+
// Intrinsic width.
|
231
|
+
'max-content',
|
232
|
+
'min-content',
|
233
|
+
'fit-content',
|
234
|
+
'fill',
|
235
|
+
'fill-available',
|
236
|
+
'stretch',
|
237
237
|
|
238
|
-
|
239
|
-
|
238
|
+
// Sticky position.
|
239
|
+
'sticky',
|
240
240
|
|
241
|
-
|
242
|
-
|
241
|
+
// Transform.
|
242
|
+
'transform',
|
243
243
|
|
244
|
-
|
245
|
-
|
246
|
-
|
244
|
+
// Zoom cursors.
|
245
|
+
'zoom-in',
|
246
|
+
'zoom-out',
|
247
247
|
|
248
|
-
|
248
|
+
);
|
249
249
|
|
250
250
|
// Functions.
|
251
251
|
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
252
|
+
/// Removes a specific item from a list.
|
253
|
+
/// @author Hugo Giraudel
|
254
|
+
/// @param {list} $list List.
|
255
|
+
/// @param {integer} $index Index.
|
256
|
+
/// @return {list} Updated list.
|
257
|
+
@function remove-nth($list, $index) {
|
258
258
|
|
259
|
-
|
259
|
+
$result: null;
|
260
260
|
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
261
|
+
@if type-of($index) != number {
|
262
|
+
@warn "$index: #{quote($index)} is not a number for `remove-nth`.";
|
263
|
+
}
|
264
|
+
@else if $index == 0 {
|
265
|
+
@warn "List index 0 must be a non-zero integer for `remove-nth`.";
|
266
|
+
}
|
267
|
+
@else if abs($index) > length($list) {
|
268
|
+
@warn "List index is #{$index} but list is only #{length($list)} item long for `remove-nth`.";
|
269
|
+
}
|
270
|
+
@else {
|
271
271
|
|
272
|
-
|
273
|
-
|
272
|
+
$result: ();
|
273
|
+
$index: if($index < 0, length($list) + $index + 1, $index);
|
274
274
|
|
275
|
-
|
275
|
+
@for $i from 1 through length($list) {
|
276
276
|
|
277
|
-
|
278
|
-
|
279
|
-
|
277
|
+
@if $i != $index {
|
278
|
+
$result: append($result, nth($list, $i));
|
279
|
+
}
|
280
280
|
|
281
|
-
|
281
|
+
}
|
282
282
|
|
283
|
-
|
283
|
+
}
|
284
284
|
|
285
|
-
|
285
|
+
@return $result;
|
286
286
|
|
287
|
-
|
287
|
+
}
|
288
288
|
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
293
|
-
|
294
|
-
|
295
|
-
|
289
|
+
/// Replaces a substring within another string.
|
290
|
+
/// @author Hugo Giraudel
|
291
|
+
/// @param {string} $string String.
|
292
|
+
/// @param {string} $search Substring.
|
293
|
+
/// @param {string} $replace Replacement.
|
294
|
+
/// @return {string} Updated string.
|
295
|
+
@function str-replace($string, $search, $replace: '') {
|
296
296
|
|
297
|
-
|
297
|
+
$index: str-index($string, $search);
|
298
298
|
|
299
|
-
|
300
|
-
|
301
|
-
|
299
|
+
@if $index {
|
300
|
+
@return str-slice($string, 1, $index - 1) + $replace + str-replace(str-slice($string, $index + str-length($search)), $search, $replace);
|
301
|
+
}
|
302
302
|
|
303
|
-
|
303
|
+
@return $string;
|
304
304
|
|
305
|
-
|
305
|
+
}
|
306
306
|
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
307
|
+
/// Replaces a substring within each string in a list.
|
308
|
+
/// @param {list} $strings List of strings.
|
309
|
+
/// @param {string} $search Substring.
|
310
|
+
/// @param {string} $replace Replacement.
|
311
|
+
/// @return {list} Updated list of strings.
|
312
|
+
@function str-replace-all($strings, $search, $replace: '') {
|
313
313
|
|
314
|
-
|
315
|
-
|
316
|
-
|
314
|
+
@each $string in $strings {
|
315
|
+
$strings: set-nth($strings, index($strings, $string), str-replace($string, $search, $replace));
|
316
|
+
}
|
317
317
|
|
318
|
-
|
318
|
+
@return $strings;
|
319
319
|
|
320
|
-
|
320
|
+
}
|
321
321
|
|
322
322
|
// Mixins.
|
323
323
|
|
324
|
-
|
325
|
-
|
326
|
-
|
324
|
+
/// Wraps @content in vendorized keyframe blocks.
|
325
|
+
/// @param {string} $name Name.
|
326
|
+
@mixin keyframes($name) {
|
327
327
|
|
328
|
-
|
329
|
-
|
330
|
-
|
331
|
-
|
328
|
+
@-moz-keyframes #{$name} { @content; }
|
329
|
+
@-webkit-keyframes #{$name} { @content; }
|
330
|
+
@-ms-keyframes #{$name} { @content; }
|
331
|
+
@keyframes #{$name} { @content; }
|
332
332
|
|
333
|
-
|
333
|
+
}
|
334
334
|
|
335
|
-
|
336
|
-
|
337
|
-
|
338
|
-
|
335
|
+
/// Vendorizes a declaration's property and/or value(s).
|
336
|
+
/// @param {string} $property Property.
|
337
|
+
/// @param {mixed} $value String/list of value(s).
|
338
|
+
@mixin vendor($property, $value) {
|
339
339
|
|
340
|
-
|
341
|
-
|
340
|
+
// Determine if property should expand.
|
341
|
+
$expandProperty: index($vendor-properties, $property);
|
342
342
|
|
343
|
-
|
344
|
-
|
343
|
+
// Determine if value should expand (and if so, add '-prefix-' placeholder).
|
344
|
+
$expandValue: false;
|
345
345
|
|
346
|
-
|
347
|
-
|
348
|
-
|
346
|
+
@each $x in $value {
|
347
|
+
@each $y in $vendor-values {
|
348
|
+
@if $y == str-slice($x, 1, str-length($y)) {
|
349
349
|
|
350
|
-
|
351
|
-
|
350
|
+
$value: set-nth($value, index($value, $x), '-prefix-' + $x);
|
351
|
+
$expandValue: true;
|
352
352
|
|
353
|
-
|
354
|
-
|
355
|
-
|
353
|
+
}
|
354
|
+
}
|
355
|
+
}
|
356
356
|
|
357
|
-
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
357
|
+
// Expand property?
|
358
|
+
@if $expandProperty {
|
359
|
+
@each $vendor in $vendor-prefixes {
|
360
|
+
#{$vendor}#{$property}: #{str-replace-all($value, '-prefix-', $vendor)};
|
361
|
+
}
|
362
|
+
}
|
363
363
|
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
364
|
+
// Expand just the value?
|
365
|
+
@elseif $expandValue {
|
366
|
+
@each $vendor in $vendor-prefixes {
|
367
|
+
#{$property}: #{str-replace-all($value, '-prefix-', $vendor)};
|
368
|
+
}
|
369
|
+
}
|
370
370
|
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
371
|
+
// Neither? Treat them as a normal declaration.
|
372
|
+
@else {
|
373
|
+
#{$property}: #{$value};
|
374
|
+
}
|
375
375
|
|
376
|
-
|
376
|
+
}
|