jekyll-theme-foundation 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE.txt +21 -0
- data/README.md +48 -0
- data/_includes/google-analytics.html +8 -0
- data/_includes/head.html +17 -0
- data/_includes/scripts.html +4 -0
- data/_layouts/default.html +16 -0
- data/_layouts/home.html +5 -0
- data/_layouts/page.html +5 -0
- data/_layouts/post.html +5 -0
- data/_sass/_vendor/normalize-scss/sass/_normalize.scss +3 -0
- data/_sass/_vendor/normalize-scss/sass/normalize/_import-now.scss +11 -0
- data/_sass/_vendor/normalize-scss/sass/normalize/_normalize-mixin.scss +676 -0
- data/_sass/_vendor/normalize-scss/sass/normalize/_variables.scss +36 -0
- data/_sass/_vendor/normalize-scss/sass/normalize/_vertical-rhythm.scss +61 -0
- data/_sass/_vendor/sassy-lists/stylesheets/functions/_contain.scss +31 -0
- data/_sass/_vendor/sassy-lists/stylesheets/functions/_purge.scss +38 -0
- data/_sass/_vendor/sassy-lists/stylesheets/functions/_remove.scss +31 -0
- data/_sass/_vendor/sassy-lists/stylesheets/functions/_replace.scss +46 -0
- data/_sass/_vendor/sassy-lists/stylesheets/functions/_to-list.scss +27 -0
- data/_sass/_vendor/sassy-lists/stylesheets/helpers/_missing-dependencies.scss +25 -0
- data/_sass/_vendor/sassy-lists/stylesheets/helpers/_true.scss +13 -0
- data/_sass/assets/foundation-float.scss +5 -0
- data/_sass/assets/foundation-prototype.scss +3 -0
- data/_sass/assets/foundation-rtl.scss +5 -0
- data/_sass/assets/foundation.scss +3 -0
- data/_sass/jekyll-theme-foundation.scss +5 -0
- data/_sass/scss/_global.scss +249 -0
- data/_sass/scss/components/_accordion-menu.scss +171 -0
- data/_sass/scss/components/_accordion.scss +155 -0
- data/_sass/scss/components/_badge.scss +63 -0
- data/_sass/scss/components/_breadcrumbs.scss +117 -0
- data/_sass/scss/components/_button-group.scss +253 -0
- data/_sass/scss/components/_button.scss +385 -0
- data/_sass/scss/components/_callout.scss +106 -0
- data/_sass/scss/components/_card.scss +129 -0
- data/_sass/scss/components/_close-button.scss +102 -0
- data/_sass/scss/components/_drilldown.scss +142 -0
- data/_sass/scss/components/_dropdown-menu.scss +274 -0
- data/_sass/scss/components/_dropdown.scss +79 -0
- data/_sass/scss/components/_flex-video.scss +1 -0
- data/_sass/scss/components/_flex.scss +117 -0
- data/_sass/scss/components/_float.scss +27 -0
- data/_sass/scss/components/_label.scss +64 -0
- data/_sass/scss/components/_media-object.scss +114 -0
- data/_sass/scss/components/_menu-icon.scss +9 -0
- data/_sass/scss/components/_menu.scss +495 -0
- data/_sass/scss/components/_off-canvas.scss +506 -0
- data/_sass/scss/components/_orbit.scss +196 -0
- data/_sass/scss/components/_pagination.scss +193 -0
- data/_sass/scss/components/_progress-bar.scss +64 -0
- data/_sass/scss/components/_responsive-embed.scss +70 -0
- data/_sass/scss/components/_reveal.scss +180 -0
- data/_sass/scss/components/_slider.scss +137 -0
- data/_sass/scss/components/_sticky.scss +39 -0
- data/_sass/scss/components/_switch.scss +247 -0
- data/_sass/scss/components/_table.scss +330 -0
- data/_sass/scss/components/_tabs.scss +196 -0
- data/_sass/scss/components/_thumbnail.scss +67 -0
- data/_sass/scss/components/_title-bar.scss +84 -0
- data/_sass/scss/components/_tooltip.scss +160 -0
- data/_sass/scss/components/_top-bar.scss +175 -0
- data/_sass/scss/components/_visibility.scss +132 -0
- data/_sass/scss/forms/_checkbox.scss +41 -0
- data/_sass/scss/forms/_error.scss +88 -0
- data/_sass/scss/forms/_fieldset.scss +53 -0
- data/_sass/scss/forms/_forms.scss +34 -0
- data/_sass/scss/forms/_help-text.scss +30 -0
- data/_sass/scss/forms/_input-group.scss +142 -0
- data/_sass/scss/forms/_label.scss +50 -0
- data/_sass/scss/forms/_meter.scss +116 -0
- data/_sass/scss/forms/_progress.scss +94 -0
- data/_sass/scss/forms/_range.scss +149 -0
- data/_sass/scss/forms/_select.scss +86 -0
- data/_sass/scss/forms/_text.scss +179 -0
- data/_sass/scss/foundation.scss +133 -0
- data/_sass/scss/grid/_classes.scss +176 -0
- data/_sass/scss/grid/_column.scss +112 -0
- data/_sass/scss/grid/_flex-grid.scss +259 -0
- data/_sass/scss/grid/_grid.scss +48 -0
- data/_sass/scss/grid/_gutter.scss +82 -0
- data/_sass/scss/grid/_layout.scss +76 -0
- data/_sass/scss/grid/_position.scss +76 -0
- data/_sass/scss/grid/_row.scss +99 -0
- data/_sass/scss/grid/_size.scss +24 -0
- data/_sass/scss/prototype/_arrow.scss +36 -0
- data/_sass/scss/prototype/_border-box.scss +35 -0
- data/_sass/scss/prototype/_border-none.scss +35 -0
- data/_sass/scss/prototype/_bordered.scss +54 -0
- data/_sass/scss/prototype/_box.scss +23 -0
- data/_sass/scss/prototype/_display.scss +50 -0
- data/_sass/scss/prototype/_font-styling.scss +95 -0
- data/_sass/scss/prototype/_list-style-type.scss +95 -0
- data/_sass/scss/prototype/_overflow.scss +72 -0
- data/_sass/scss/prototype/_position.scss +114 -0
- data/_sass/scss/prototype/_prototype.scss +87 -0
- data/_sass/scss/prototype/_relation.scss +157 -0
- data/_sass/scss/prototype/_rotate.scss +31 -0
- data/_sass/scss/prototype/_rounded.scss +54 -0
- data/_sass/scss/prototype/_separator.scss +96 -0
- data/_sass/scss/prototype/_shadow.scss +43 -0
- data/_sass/scss/prototype/_sizing.scss +73 -0
- data/_sass/scss/prototype/_spacing.scss +204 -0
- data/_sass/scss/prototype/_text-decoration.scss +48 -0
- data/_sass/scss/prototype/_text-transformation.scss +48 -0
- data/_sass/scss/prototype/_text-utilities.scss +88 -0
- data/_sass/scss/settings/_settings.scss +869 -0
- data/_sass/scss/typography/_alignment.scss +22 -0
- data/_sass/scss/typography/_base.scss +509 -0
- data/_sass/scss/typography/_helpers.scss +80 -0
- data/_sass/scss/typography/_print.scss +86 -0
- data/_sass/scss/typography/_typography.scss +26 -0
- data/_sass/scss/util/_breakpoint.scss +348 -0
- data/_sass/scss/util/_color.scss +129 -0
- data/_sass/scss/util/_direction.scss +31 -0
- data/_sass/scss/util/_flex.scss +85 -0
- data/_sass/scss/util/_math.scss +72 -0
- data/_sass/scss/util/_mixins.scss +313 -0
- data/_sass/scss/util/_selector.scss +41 -0
- data/_sass/scss/util/_typography.scss +26 -0
- data/_sass/scss/util/_unit.scss +152 -0
- data/_sass/scss/util/_util.scss +14 -0
- data/_sass/scss/util/_value.scss +160 -0
- data/_sass/scss/xy-grid/_cell.scss +169 -0
- data/_sass/scss/xy-grid/_classes.scss +476 -0
- data/_sass/scss/xy-grid/_collapse.scss +74 -0
- data/_sass/scss/xy-grid/_frame.scss +85 -0
- data/_sass/scss/xy-grid/_grid.scss +35 -0
- data/_sass/scss/xy-grid/_gutters.scss +45 -0
- data/_sass/scss/xy-grid/_layout.scss +33 -0
- data/_sass/scss/xy-grid/_position.scss +28 -0
- data/_sass/scss/xy-grid/_xy-grid.scss +51 -0
- data/assets/css/main.scss +5 -0
- data/assets/css/motion-ui.min.css +1 -0
- data/assets/js/foundation.min.js +5 -0
- data/assets/js/motion-ui.min.js +1 -0
- metadata +235 -0
@@ -0,0 +1,476 @@
|
|
1
|
+
// Foundation for Sites by ZURB
|
2
|
+
// foundation.zurb.com
|
3
|
+
// Licensed under MIT Open Source
|
4
|
+
|
5
|
+
////
|
6
|
+
/// @group xy-grid
|
7
|
+
////
|
8
|
+
|
9
|
+
// Margin Grid classes
|
10
|
+
@mixin xy-base-grid-classes {
|
11
|
+
|
12
|
+
// Grid Container
|
13
|
+
.grid-container {
|
14
|
+
@include xy-grid-container;
|
15
|
+
|
16
|
+
&.fluid {
|
17
|
+
@include xy-grid-container(100%);
|
18
|
+
}
|
19
|
+
|
20
|
+
&.full {
|
21
|
+
@include xy-grid-container(100%, 0);
|
22
|
+
}
|
23
|
+
}
|
24
|
+
|
25
|
+
// Base grid styles
|
26
|
+
.grid-x {
|
27
|
+
@include xy-grid;
|
28
|
+
}
|
29
|
+
|
30
|
+
.cell {
|
31
|
+
@include xy-cell-base();
|
32
|
+
@include xy-cell-static($grid-columns, false, $gutter-type: padding);
|
33
|
+
|
34
|
+
&.auto {
|
35
|
+
@include xy-cell-base(auto);
|
36
|
+
}
|
37
|
+
|
38
|
+
&.shrink {
|
39
|
+
@include xy-cell-base(shrink);
|
40
|
+
}
|
41
|
+
|
42
|
+
}
|
43
|
+
.grid-x {
|
44
|
+
> .auto {
|
45
|
+
@include xy-cell-static(auto, false);
|
46
|
+
}
|
47
|
+
|
48
|
+
> .shrink {
|
49
|
+
@include xy-cell-static(shrink, false);
|
50
|
+
}
|
51
|
+
}
|
52
|
+
|
53
|
+
// Auto width
|
54
|
+
@include -zf-each-breakpoint() {
|
55
|
+
// This is a bit of a hack/workaround, see these issues & PRs for the backstory:
|
56
|
+
// https://github.com/zurb/foundation-sites/issues/10244
|
57
|
+
// https://github.com/zurb/foundation-sites/pull/10222 and
|
58
|
+
// https://github.com/zurb/foundation-sites/pull/10164
|
59
|
+
.grid-x {
|
60
|
+
$str: "> .#{$-zf-size}-shrink, > .#{$-zf-size}-full";
|
61
|
+
@for $i from 1 through $grid-columns {
|
62
|
+
$str: $str + ", > .#{$-zf-size}-#{$i}"
|
63
|
+
}
|
64
|
+
#{$str} {
|
65
|
+
flex-basis: auto;
|
66
|
+
}
|
67
|
+
}
|
68
|
+
}
|
69
|
+
|
70
|
+
@include -zf-each-breakpoint() {
|
71
|
+
@if not($-zf-size == small) {
|
72
|
+
.grid-x > .#{$-zf-size}-auto {
|
73
|
+
@include xy-cell-base(auto);
|
74
|
+
@include xy-cell-static(auto, false);
|
75
|
+
}
|
76
|
+
|
77
|
+
.grid-x > .#{$-zf-size}-shrink {
|
78
|
+
@include xy-cell-base(shrink);
|
79
|
+
@include xy-cell-static(shrink, false);
|
80
|
+
}
|
81
|
+
}
|
82
|
+
|
83
|
+
@for $i from 1 through $grid-columns {
|
84
|
+
// Sizing (percentage)
|
85
|
+
.grid-x > .#{$-zf-size}-#{$i} {
|
86
|
+
@include xy-cell-static($i, false, $gutter-type: padding);
|
87
|
+
}
|
88
|
+
}
|
89
|
+
}
|
90
|
+
|
91
|
+
// Reset width when using `.grid-margin-x` not on `.grid-x`
|
92
|
+
.grid-margin-x:not(.grid-x) > .cell {
|
93
|
+
width: auto;
|
94
|
+
}
|
95
|
+
|
96
|
+
// Reset height when using `.grid-margin-y` not on `.grid-y`
|
97
|
+
.grid-margin-y:not(.grid-y) > .cell {
|
98
|
+
height: auto;
|
99
|
+
}
|
100
|
+
}
|
101
|
+
|
102
|
+
@mixin -xy-breakpoint-cell-classes($class-breakpoint, $gutter-breakpoint, $vertical) {
|
103
|
+
$prefix: if($class-breakpoint == $-zf-zero-breakpoint, '', '#{$class-breakpoint}-');
|
104
|
+
> .#{$prefix}auto {
|
105
|
+
@include xy-cell-static(auto, false, $breakpoint: $gutter-breakpoint, $vertical: $vertical);
|
106
|
+
}
|
107
|
+
|
108
|
+
> .#{$prefix}shrink {
|
109
|
+
@include xy-cell-static(shrink, false, $breakpoint: $gutter-breakpoint, $vertical: $vertical);
|
110
|
+
}
|
111
|
+
|
112
|
+
@for $i from 1 through $grid-columns {
|
113
|
+
// Sizing (percentage)
|
114
|
+
$classname: if($vertical, '.#{$class-breakpoint}-#{$i}', '.#{$class-breakpoint}-#{$i}');
|
115
|
+
|
116
|
+
> #{$classname} {
|
117
|
+
@include xy-cell-static($i, false, $breakpoint: $gutter-breakpoint, $vertical: $vertical);
|
118
|
+
}
|
119
|
+
}
|
120
|
+
}
|
121
|
+
|
122
|
+
// Margin Grid classes
|
123
|
+
@mixin xy-margin-grid-classes(
|
124
|
+
$gutter-position: left right,
|
125
|
+
$vertical: false,
|
126
|
+
$wrapping-selector: '.grid-margin-x'
|
127
|
+
){
|
128
|
+
#{$wrapping-selector} {
|
129
|
+
@include xy-gutters($negative: true, $gutter-position: $gutter-position);
|
130
|
+
|
131
|
+
// Base cell styles
|
132
|
+
> .cell {
|
133
|
+
@include xy-cell-static($vertical: $vertical);
|
134
|
+
}
|
135
|
+
|
136
|
+
// base styles need to all be before the auto and shrink styles
|
137
|
+
@include -zf-each-breakpoint() {
|
138
|
+
@if(type-of($grid-margin-gutters) == 'map' and map-has-key($grid-margin-gutters, $-zf-size) and $-zf-size != $-zf-zero-breakpoint) {
|
139
|
+
> .cell {
|
140
|
+
@include xy-cell-static($breakpoint: $-zf-size, $vertical: $vertical);
|
141
|
+
}
|
142
|
+
}
|
143
|
+
}
|
144
|
+
|
145
|
+
@include -zf-each-breakpoint() {
|
146
|
+
|
147
|
+
// This is purely for responsive gutters - the margin grid has to go back and adjust widths (or heights)
|
148
|
+
// for prior breakpoints based on the responsive gutter.
|
149
|
+
@if(type-of($grid-margin-gutters) == 'map' and map-has-key($grid-margin-gutters, $-zf-size)) {
|
150
|
+
@each $bp in -zf-breakpoints-less-than($-zf-size) {
|
151
|
+
@if(map-has-key($grid-margin-gutters, $bp)) {
|
152
|
+
@include -xy-breakpoint-cell-classes($bp, $-zf-size, $vertical);
|
153
|
+
}
|
154
|
+
}
|
155
|
+
}
|
156
|
+
|
157
|
+
@include -xy-breakpoint-cell-classes($-zf-size, $-zf-size, $vertical);
|
158
|
+
}
|
159
|
+
}
|
160
|
+
}
|
161
|
+
|
162
|
+
// Padding Grid classes
|
163
|
+
@mixin xy-padding-grid-classes {
|
164
|
+
.grid-padding-x {
|
165
|
+
|
166
|
+
// Negative margin for nested grids
|
167
|
+
.grid-padding-x {
|
168
|
+
@include xy-gutters($negative: true);
|
169
|
+
}
|
170
|
+
|
171
|
+
// Negative margin for grids within `grid-container/grid-container.fluid`
|
172
|
+
// This allows margin and padding grids to line up with eachother
|
173
|
+
.grid-container:not(.full) > & {
|
174
|
+
@include xy-gutters($negative: true);
|
175
|
+
}
|
176
|
+
|
177
|
+
// Base cell styles
|
178
|
+
> .cell {
|
179
|
+
@include xy-gutters($gutters: $grid-padding-gutters, $gutter-type: padding);
|
180
|
+
}
|
181
|
+
}
|
182
|
+
}
|
183
|
+
|
184
|
+
// Block Grid classes
|
185
|
+
@mixin xy-block-grid-classes($margin-grid: true, $padding-grid: true) {
|
186
|
+
@if $padding-grid {
|
187
|
+
@include -zf-each-breakpoint {
|
188
|
+
@for $i from 1 through $xy-block-grid-max {
|
189
|
+
.#{$-zf-size}-up-#{$i} {
|
190
|
+
@include xy-grid-layout($i, '.cell', false, $gutter-type: padding);
|
191
|
+
}
|
192
|
+
}
|
193
|
+
}
|
194
|
+
}
|
195
|
+
|
196
|
+
@if $margin-grid {
|
197
|
+
@include -zf-each-breakpoint {
|
198
|
+
@for $i from 1 through $xy-block-grid-max {
|
199
|
+
// This is purely for responsive gutters - the margin grid has to go back and adjust widths (or heights)
|
200
|
+
// for prior breakpoints based on the responsive gutter.
|
201
|
+
@if(type-of($grid-margin-gutters) == 'map' and map-has-key($grid-margin-gutters, $-zf-size)) {
|
202
|
+
@each $bp in -zf-breakpoints-less-than($-zf-size) {
|
203
|
+
@if(map-has-key($grid-margin-gutters, $bp)) {
|
204
|
+
.grid-margin-x.#{$bp}-up-#{$i} {
|
205
|
+
@include xy-grid-layout($i, '.cell', false, $gutter-type: margin, $breakpoint: $bp);
|
206
|
+
}
|
207
|
+
}
|
208
|
+
}
|
209
|
+
}
|
210
|
+
}
|
211
|
+
@for $i from 1 through $xy-block-grid-max {
|
212
|
+
.grid-margin-x.#{$-zf-size}-up-#{$i} {
|
213
|
+
@include xy-grid-layout($i, '.cell', false, $gutter-type: margin, $breakpoint: $-zf-size);
|
214
|
+
}
|
215
|
+
}
|
216
|
+
}
|
217
|
+
}
|
218
|
+
}
|
219
|
+
|
220
|
+
// Collapse classes
|
221
|
+
@mixin xy-collapse-grid-classes($margin-grid: true, $padding-grid: true) {
|
222
|
+
@each $bp in $breakpoint-classes {
|
223
|
+
@if $margin-grid {
|
224
|
+
.#{$bp}-margin-collapse {
|
225
|
+
@include xy-grid-collapse($gutter-type: margin, $min-breakpoint: $bp);
|
226
|
+
}
|
227
|
+
}
|
228
|
+
|
229
|
+
@if $padding-grid {
|
230
|
+
.#{$bp}-padding-collapse {
|
231
|
+
@include xy-grid-collapse($gutter-type: padding, $min-breakpoint: $bp);
|
232
|
+
}
|
233
|
+
}
|
234
|
+
}
|
235
|
+
}
|
236
|
+
|
237
|
+
// Offset classes
|
238
|
+
@mixin xy-offset-cell-classes {
|
239
|
+
@include -zf-each-breakpoint {
|
240
|
+
@for $i from 1 through $grid-columns {
|
241
|
+
// Offsets
|
242
|
+
$o: $i - 1;
|
243
|
+
|
244
|
+
.#{$-zf-size}-offset-#{$o} {
|
245
|
+
@include xy-cell-offset($o, $gutters: $grid-padding-gutters, $gutter-type: padding, $breakpoint: $-zf-size);
|
246
|
+
}
|
247
|
+
|
248
|
+
.grid-margin-x > .#{$-zf-size}-offset-#{$o} {
|
249
|
+
@include xy-cell-offset($o, $breakpoint: $-zf-size);
|
250
|
+
}
|
251
|
+
}
|
252
|
+
}
|
253
|
+
}
|
254
|
+
|
255
|
+
// Vertical Grid classes
|
256
|
+
@mixin xy-vertical-grid-classes(
|
257
|
+
$margin-grid: true,
|
258
|
+
$padding-grid: true
|
259
|
+
) {
|
260
|
+
|
261
|
+
@include -zf-each-breakpoint() {
|
262
|
+
@if not($-zf-size == small) {
|
263
|
+
}
|
264
|
+
}
|
265
|
+
|
266
|
+
.grid-y {
|
267
|
+
@include xy-grid(vertical, false);
|
268
|
+
|
269
|
+
|
270
|
+
> .cell {
|
271
|
+
@include xy-cell-reset();
|
272
|
+
}
|
273
|
+
|
274
|
+
> .auto {
|
275
|
+
@include xy-cell-static(auto, false, $breakpoint: $-zf-size, $vertical: true);
|
276
|
+
}
|
277
|
+
|
278
|
+
> .shrink {
|
279
|
+
@include xy-cell-static(shrink, false, $breakpoint: $-zf-size, $vertical: true);
|
280
|
+
}
|
281
|
+
|
282
|
+
|
283
|
+
@include -zf-each-breakpoint() {
|
284
|
+
// This is a bit of a hack/workaround, see these issues and PRs for the backstory:
|
285
|
+
// https://github.com/zurb/foundation-sites/issues/10244
|
286
|
+
// https://github.com/zurb/foundation-sites/pull/10222 and
|
287
|
+
// https://github.com/zurb/foundation-sites/pull/10164
|
288
|
+
$str: "> .#{$-zf-size}-shrink, > .#{$-zf-size}-full";
|
289
|
+
@for $i from 1 through $grid-columns {
|
290
|
+
$str: $str + ", > .#{$-zf-size}-#{$i}"
|
291
|
+
}
|
292
|
+
#{$str} {
|
293
|
+
flex-basis: auto;
|
294
|
+
}
|
295
|
+
}
|
296
|
+
|
297
|
+
@include -zf-each-breakpoint() {
|
298
|
+
@if not($-zf-size == small) {
|
299
|
+
> .#{$-zf-size}-auto {
|
300
|
+
@include xy-cell-base(auto);
|
301
|
+
@include xy-cell-static(auto, false, $breakpoint: $-zf-size, $vertical: true);
|
302
|
+
}
|
303
|
+
|
304
|
+
> .#{$-zf-size}-shrink {
|
305
|
+
@include xy-cell-static(shrink, false, $breakpoint: $-zf-size, $vertical: true);
|
306
|
+
}
|
307
|
+
|
308
|
+
}
|
309
|
+
|
310
|
+
@for $i from 1 through $grid-columns {
|
311
|
+
// Sizing (percentage)
|
312
|
+
> .#{$-zf-size}-#{$i} {
|
313
|
+
@include xy-cell-static($i, false, $vertical: true, $gutter-type: padding);
|
314
|
+
}
|
315
|
+
}
|
316
|
+
|
317
|
+
}
|
318
|
+
}
|
319
|
+
|
320
|
+
@if $padding-grid {
|
321
|
+
.grid-padding-y {
|
322
|
+
// Negative margin for nested grids
|
323
|
+
.grid-padding-y {
|
324
|
+
@include xy-gutters($negative: true, $gutter-position: top bottom);
|
325
|
+
}
|
326
|
+
|
327
|
+
// Base cell styles
|
328
|
+
> .cell {
|
329
|
+
@include xy-gutters($gutters: $grid-padding-gutters, $gutter-type: padding, $gutter-position: top bottom);
|
330
|
+
}
|
331
|
+
}
|
332
|
+
}
|
333
|
+
|
334
|
+
@if $margin-grid {
|
335
|
+
@include xy-margin-grid-classes(top bottom, true, '.grid-margin-y');
|
336
|
+
}
|
337
|
+
|
338
|
+
}
|
339
|
+
|
340
|
+
@mixin xy-frame-grid-classes($vertical-grid: true, $margin-grid: true) {
|
341
|
+
// Framed grid styles
|
342
|
+
.grid-frame {
|
343
|
+
@include xy-grid-frame;
|
344
|
+
}
|
345
|
+
|
346
|
+
.cell .grid-frame {
|
347
|
+
width: 100%; // Same as include with $nested, but with less css
|
348
|
+
}
|
349
|
+
|
350
|
+
.cell-block {
|
351
|
+
@include xy-cell-block();
|
352
|
+
}
|
353
|
+
|
354
|
+
.cell-block-y {
|
355
|
+
@include xy-cell-block(true);
|
356
|
+
}
|
357
|
+
|
358
|
+
|
359
|
+
.cell-block-container {
|
360
|
+
@include xy-cell-block-container();
|
361
|
+
}
|
362
|
+
|
363
|
+
|
364
|
+
@include -zf-each-breakpoint(false) {
|
365
|
+
|
366
|
+
.#{$-zf-size}-grid-frame {
|
367
|
+
@include xy-grid-frame;
|
368
|
+
}
|
369
|
+
|
370
|
+
.cell .#{$-zf-size}-grid-frame {
|
371
|
+
width: 100%; // Same as include with $nested, but with less css
|
372
|
+
}
|
373
|
+
|
374
|
+
.#{$-zf-size}-cell-block {
|
375
|
+
@include xy-cell-block();
|
376
|
+
}
|
377
|
+
|
378
|
+
.#{$-zf-size}-cell-block-container {
|
379
|
+
@include xy-cell-block-container();
|
380
|
+
}
|
381
|
+
|
382
|
+
.#{$-zf-size}-cell-block-y {
|
383
|
+
@include xy-cell-block(true);
|
384
|
+
}
|
385
|
+
}
|
386
|
+
|
387
|
+
@if $vertical-grid {
|
388
|
+
.grid-y {
|
389
|
+
&.grid-frame {
|
390
|
+
width: auto;
|
391
|
+
@include xy-grid-frame(true);
|
392
|
+
}
|
393
|
+
|
394
|
+
@include -zf-each-breakpoint(false) {
|
395
|
+
&.#{$-zf-size}-grid-frame {
|
396
|
+
width: auto;
|
397
|
+
@include xy-grid-frame(true);
|
398
|
+
}
|
399
|
+
|
400
|
+
}
|
401
|
+
}
|
402
|
+
.cell {
|
403
|
+
.grid-y.grid-frame {
|
404
|
+
height: 100%; // Same as include with $nested, but with less css
|
405
|
+
}
|
406
|
+
@include -zf-each-breakpoint(false) {
|
407
|
+
.grid-y.#{$-zf-size}-grid-frame {
|
408
|
+
height: 100%; // Same as include with $nested, but with less css
|
409
|
+
}
|
410
|
+
}
|
411
|
+
}
|
412
|
+
}
|
413
|
+
@if $margin-grid {
|
414
|
+
@include xy-margin-grid-classes(top bottom, true, '.grid-margin-y');
|
415
|
+
.grid-frame.grid-margin-y {
|
416
|
+
@include xy-grid-frame(true, false, $grid-margin-gutters, $include-base: false);
|
417
|
+
}
|
418
|
+
@include -zf-each-breakpoint(false) {
|
419
|
+
.grid-margin-y.#{$-zf-size}-grid-frame {
|
420
|
+
@include xy-grid-frame(true, false, $grid-margin-gutters, $-zf-size, false);
|
421
|
+
}
|
422
|
+
}
|
423
|
+
}
|
424
|
+
}
|
425
|
+
|
426
|
+
// Final classes
|
427
|
+
@mixin foundation-xy-grid-classes(
|
428
|
+
$base-grid: true,
|
429
|
+
$margin-grid: true,
|
430
|
+
$padding-grid: true,
|
431
|
+
$block-grid: true,
|
432
|
+
$collapse: true,
|
433
|
+
$offset: true,
|
434
|
+
$vertical-grid: true,
|
435
|
+
$frame-grid: true
|
436
|
+
) {
|
437
|
+
|
438
|
+
// Base grid styles
|
439
|
+
@if($base-grid) {
|
440
|
+
@include xy-base-grid-classes();
|
441
|
+
}
|
442
|
+
|
443
|
+
// Margin grid
|
444
|
+
@if($margin-grid) {
|
445
|
+
@include xy-margin-grid-classes();
|
446
|
+
}
|
447
|
+
|
448
|
+
// Padding grid
|
449
|
+
@if($padding-grid) {
|
450
|
+
@include xy-padding-grid-classes();
|
451
|
+
}
|
452
|
+
|
453
|
+
// Block grid
|
454
|
+
@if($block-grid) {
|
455
|
+
@include xy-block-grid-classes($margin-grid, $padding-grid);
|
456
|
+
}
|
457
|
+
|
458
|
+
// Collapse gutters
|
459
|
+
@if($collapse) {
|
460
|
+
@include xy-collapse-grid-classes($margin-grid, $padding-grid);
|
461
|
+
}
|
462
|
+
|
463
|
+
// Offset gutters
|
464
|
+
@if($offset) {
|
465
|
+
@include xy-offset-cell-classes();
|
466
|
+
}
|
467
|
+
|
468
|
+
// Vertical grid
|
469
|
+
@if($vertical-grid) {
|
470
|
+
@include xy-vertical-grid-classes($margin-grid, $padding-grid);
|
471
|
+
}
|
472
|
+
|
473
|
+
@if ($frame-grid) {
|
474
|
+
@include xy-frame-grid-classes($vertical-grid, $margin-grid)
|
475
|
+
}
|
476
|
+
}
|
@@ -0,0 +1,74 @@
|
|
1
|
+
// Foundation for Sites by ZURB
|
2
|
+
// foundation.zurb.com
|
3
|
+
// Licensed under MIT Open Source
|
4
|
+
|
5
|
+
////
|
6
|
+
/// @group xy-grid
|
7
|
+
////
|
8
|
+
|
9
|
+
/// Collapses the grid a cells within it.
|
10
|
+
///
|
11
|
+
/// @param {String} $selector [.cell] - The child element to remove the gutter from.
|
12
|
+
/// @param {Keyword} $gutter-type [margin] - The type of gutter to remove.
|
13
|
+
/// @param {List} $gutter-position [right left] - The positions to remove gutters from. Accepts `top`, `bottom`, `left`, `right` in any combination.
|
14
|
+
@mixin xy-grid-collapse(
|
15
|
+
$selector: '.cell',
|
16
|
+
$gutter-type: margin,
|
17
|
+
$gutter-position: right left,
|
18
|
+
$min-breakpoint: $-zf-zero-breakpoint
|
19
|
+
) {
|
20
|
+
// First, lets negate any margins on the top level
|
21
|
+
@if ($gutter-type == 'margin') {
|
22
|
+
|
23
|
+
@include breakpoint($min-breakpoint) {
|
24
|
+
@each $value in $gutter-position {
|
25
|
+
margin-#{$value}: 0;
|
26
|
+
}
|
27
|
+
|
28
|
+
> #{$selector} {
|
29
|
+
@each $value in $gutter-position {
|
30
|
+
margin-#{$value}: 0;
|
31
|
+
}
|
32
|
+
}
|
33
|
+
}
|
34
|
+
|
35
|
+
$excluded-bps: -zf-breakpoints-less-than($min-breakpoint);
|
36
|
+
|
37
|
+
// Output new widths to not include gutters
|
38
|
+
@each $bp in $breakpoint-classes {
|
39
|
+
@if(sl-contain($excluded-bps, $bp)) {
|
40
|
+
@include breakpoint($min-breakpoint) {
|
41
|
+
@for $i from 1 through $grid-columns {
|
42
|
+
// Sizing (percentage)
|
43
|
+
> .#{$bp}-#{$i} {
|
44
|
+
@include xy-cell-static($i, $gutter-output: false, $gutter-type: padding);
|
45
|
+
}
|
46
|
+
}
|
47
|
+
}
|
48
|
+
} @else {
|
49
|
+
@include breakpoint($bp) {
|
50
|
+
@for $i from 1 through $grid-columns {
|
51
|
+
// Sizing (percentage)
|
52
|
+
> .#{$bp}-#{$i} {
|
53
|
+
@include xy-cell-static($i, $gutter-output: false, $gutter-type: padding);
|
54
|
+
}
|
55
|
+
}
|
56
|
+
}
|
57
|
+
}
|
58
|
+
}
|
59
|
+
}
|
60
|
+
@else {
|
61
|
+
|
62
|
+
@include breakpoint($min-breakpoint) {
|
63
|
+
@each $value in $gutter-position {
|
64
|
+
margin-#{$value}: 0;
|
65
|
+
}
|
66
|
+
|
67
|
+
> #{$selector} {
|
68
|
+
@each $value in $gutter-position {
|
69
|
+
padding-#{$value}: 0;
|
70
|
+
}
|
71
|
+
}
|
72
|
+
}
|
73
|
+
}
|
74
|
+
}
|
@@ -0,0 +1,85 @@
|
|
1
|
+
/// Modifies a grid to give it "frame" behavior (no overflow, no wrap, stretch behavior)
|
2
|
+
///
|
3
|
+
/// @param {Boolean} $vertical [false] - Is grid vertical or horizontal. Should match grid.
|
4
|
+
/// @param {Boolean} $nested [false] - Is grid nested or not. If nested is true this sets the frame to 100% height, otherwise will be 100vh.
|
5
|
+
/// @param {Number|Map} $gutters [null] - Map or single value for gutters.
|
6
|
+
/// @param {String} $breakpoint [null] - The name of the breakpoint size in your gutters map to get the size from.
|
7
|
+
/// @param {Boolean} $include-base [true] - Include the base styles that don't vary per breakpoint.
|
8
|
+
@mixin xy-grid-frame(
|
9
|
+
$vertical: false,
|
10
|
+
$nested: false,
|
11
|
+
$gutters: null,
|
12
|
+
$breakpoint: null,
|
13
|
+
$include-base: true
|
14
|
+
) {
|
15
|
+
|
16
|
+
@if $include-base {
|
17
|
+
overflow: hidden;
|
18
|
+
position: relative;
|
19
|
+
flex-wrap: nowrap;
|
20
|
+
align-items: stretch;
|
21
|
+
}
|
22
|
+
|
23
|
+
@if $breakpoint == null and type-of($gutters) == 'map' {
|
24
|
+
@include -zf-each-breakpoint() {
|
25
|
+
@include xy-grid-frame($vertical, $nested, $gutters, $-zf-size, false);
|
26
|
+
}
|
27
|
+
} @else {
|
28
|
+
// Get our gutters if applicable
|
29
|
+
$gutter: -zf-get-bp-val($gutters, $breakpoint);
|
30
|
+
|
31
|
+
// If we have a gutter, add it to the width/height
|
32
|
+
@if $gutter {
|
33
|
+
@if $vertical == true {
|
34
|
+
$unit: if($nested == true, 100%, 100vh);
|
35
|
+
$gutter: rem-calc($gutter);
|
36
|
+
height: calc(#{$unit} + #{$gutter});
|
37
|
+
} @else {
|
38
|
+
$unit: if($nested == true, 100%, 100vw);
|
39
|
+
$gutter: rem-calc($gutter);
|
40
|
+
width: calc(#{$unit} + #{$gutter});
|
41
|
+
}
|
42
|
+
}
|
43
|
+
@else {
|
44
|
+
@if $vertical == true {
|
45
|
+
height: if($nested == true, 100%, 100vh);
|
46
|
+
} @else {
|
47
|
+
width: if($nested == true, 100%, 100vw);
|
48
|
+
}
|
49
|
+
}
|
50
|
+
}
|
51
|
+
}
|
52
|
+
|
53
|
+
/// Modifies a cell to give it "block" behavior (overflow auto, inertial scrolling)
|
54
|
+
///
|
55
|
+
/// @param {Boolean} $vertical [false] - Is grid vertical or horizontal. Should match grid.
|
56
|
+
@mixin xy-cell-block(
|
57
|
+
$vertical: false
|
58
|
+
) {
|
59
|
+
$property: if($vertical == true, 'overflow-y', 'overflow-x');
|
60
|
+
|
61
|
+
@if $vertical == true {
|
62
|
+
overflow-y: auto;
|
63
|
+
max-height: 100%;
|
64
|
+
} @else {
|
65
|
+
overflow-x: auto;
|
66
|
+
max-width: 100%;
|
67
|
+
}
|
68
|
+
|
69
|
+
-webkit-overflow-scrolling: touch;
|
70
|
+
-ms-overflow-stype: -ms-autohiding-scrollbar;
|
71
|
+
}
|
72
|
+
|
73
|
+
/// Container for inside a grid frame containing multiple blocks. Typically used
|
74
|
+
/// as a modifier for a `.cell` to allow the cell to pass along flex sizing
|
75
|
+
/// constraints / from parents to children.
|
76
|
+
@mixin xy-cell-block-container() {
|
77
|
+
display: flex;
|
78
|
+
flex-direction: column;
|
79
|
+
max-height: 100%;
|
80
|
+
|
81
|
+
> .grid-x {
|
82
|
+
max-height: 100%;
|
83
|
+
flex-wrap: nowrap;
|
84
|
+
}
|
85
|
+
}
|
@@ -0,0 +1,35 @@
|
|
1
|
+
// Foundation for Sites by ZURB
|
2
|
+
// foundation.zurb.com
|
3
|
+
// Licensed under MIT Open Source
|
4
|
+
|
5
|
+
////
|
6
|
+
/// @group xy-grid
|
7
|
+
////
|
8
|
+
|
9
|
+
/// Creates a max width container, designed to house your grid content.
|
10
|
+
///
|
11
|
+
/// @param {Number} $width [$grid-container] - a width to limit the container to.
|
12
|
+
@mixin xy-grid-container(
|
13
|
+
$width: $grid-container,
|
14
|
+
$padding: $grid-container-padding
|
15
|
+
) {
|
16
|
+
@include xy-gutters($gutters: $padding, $gutter-type: padding);
|
17
|
+
|
18
|
+
max-width: $width;
|
19
|
+
margin: 0 auto;
|
20
|
+
}
|
21
|
+
|
22
|
+
/// Creates a container for your flex cells.
|
23
|
+
///
|
24
|
+
/// @param {Keyword} $direction [horizontal] - Either horizontal or vertical direction of cells within.
|
25
|
+
/// @param {Boolean} $wrap [true] - If the cells within should wrap or not.
|
26
|
+
@mixin xy-grid(
|
27
|
+
$direction: horizontal,
|
28
|
+
$wrap: true
|
29
|
+
) {
|
30
|
+
$direction: if($direction == 'horizontal', row, column);
|
31
|
+
$wrap: if($wrap, wrap, nowrap);
|
32
|
+
|
33
|
+
display: flex;
|
34
|
+
flex-flow: $direction $wrap;
|
35
|
+
}
|
@@ -0,0 +1,45 @@
|
|
1
|
+
// Foundation for Sites by ZURB
|
2
|
+
// foundation.zurb.com
|
3
|
+
// Licensed under MIT Open Source
|
4
|
+
|
5
|
+
////
|
6
|
+
/// @group xy-grid
|
7
|
+
////
|
8
|
+
|
9
|
+
/// Create gutters for a cell/container.
|
10
|
+
///
|
11
|
+
/// @param {Number|Map} $gutters [$grid-margin-gutters] - Map or single value for gutters.
|
12
|
+
/// @param {Keyword} $gutter-type [margin] - Type of gutter to output. Accepts either margin or padding.
|
13
|
+
/// @param {List} $gutter-position [right left] - The position to apply gutters to. Accepts `top`, `bottom`, `left`, `right` in any combination.
|
14
|
+
/// @param {Boolean} $negative [false] - Whether to apply the gutter as a negative value. Commonly used for nested grids.
|
15
|
+
@mixin xy-gutters(
|
16
|
+
$gutters: $grid-margin-gutters,
|
17
|
+
$gutter-type: margin,
|
18
|
+
$gutter-position: right left,
|
19
|
+
$negative: false
|
20
|
+
) {
|
21
|
+
$operator: if($negative, '-', '');
|
22
|
+
|
23
|
+
// If we have declared negative gutters, force type to `margin.
|
24
|
+
$gutter-type: if($negative, 'margin', $gutter-type);
|
25
|
+
|
26
|
+
// Output our margin gutters.
|
27
|
+
@if (type-of($gutters) == 'map') {
|
28
|
+
@include -zf-breakpoint-value(auto, $gutters) {
|
29
|
+
$gutter: rem-calc($-zf-bp-value) / 2;
|
30
|
+
|
31
|
+
// Loop through each gutter position
|
32
|
+
@each $value in $gutter-position {
|
33
|
+
#{$gutter-type}-#{$value}: #{$operator}$gutter;
|
34
|
+
}
|
35
|
+
}
|
36
|
+
}
|
37
|
+
@elseif (type-of($gutters) == 'number') {
|
38
|
+
$gutter: rem-calc($gutters) / 2;
|
39
|
+
|
40
|
+
// Loop through each gutter position
|
41
|
+
@each $value in $gutter-position {
|
42
|
+
#{$gutter-type}-#{$value}: #{$operator}$gutter;
|
43
|
+
}
|
44
|
+
}
|
45
|
+
}
|