locomotivecms_wagon 2.4.0.rc2 → 2.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/generators/foundation/public/javascripts/vendor/foundation.js +10839 -6523
- data/generators/foundation/public/javascripts/vendor/foundation.min.js +5 -3
- data/generators/foundation/public/stylesheets/_settings.scss +455 -115
- data/generators/foundation/public/stylesheets/app.css +0 -3
- data/generators/foundation/public/stylesheets/app.scss +15 -6
- data/generators/foundation/public/stylesheets/foundation.css +4191 -1885
- data/generators/foundation/public/stylesheets/foundation6/_global.scss +106 -54
- data/generators/foundation/public/stylesheets/foundation6/components/_accordion-menu.scss +157 -14
- data/generators/foundation/public/stylesheets/foundation6/components/_accordion.scss +71 -28
- data/generators/foundation/public/stylesheets/foundation6/components/_badge.scss +17 -9
- data/generators/foundation/public/stylesheets/foundation6/components/_breadcrumbs.scss +33 -10
- data/generators/foundation/public/stylesheets/foundation6/components/_button-group.scss +168 -30
- data/generators/foundation/public/stylesheets/foundation6/components/_button.scss +165 -44
- data/generators/foundation/public/stylesheets/foundation6/components/_callout.scss +9 -18
- data/generators/foundation/public/stylesheets/foundation6/components/_card.scss +129 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_close-button.scss +54 -13
- data/generators/foundation/public/stylesheets/foundation6/components/_drilldown.scss +108 -33
- data/generators/foundation/public/stylesheets/foundation6/components/_dropdown-menu.scss +215 -64
- data/generators/foundation/public/stylesheets/foundation6/components/_dropdown.scss +22 -7
- data/generators/foundation/public/stylesheets/foundation6/components/_flex-video.scss +1 -68
- data/generators/foundation/public/stylesheets/foundation6/components/_flex.scss +117 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_float.scss +1 -1
- data/generators/foundation/public/stylesheets/foundation6/components/_label.scss +16 -8
- data/generators/foundation/public/stylesheets/foundation6/components/_media-object.scss +50 -10
- data/generators/foundation/public/stylesheets/foundation6/components/_menu-icon.scss +9 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_menu.scss +373 -91
- data/generators/foundation/public/stylesheets/foundation6/components/_off-canvas.scss +418 -83
- data/generators/foundation/public/stylesheets/foundation6/components/_orbit.scss +17 -7
- data/generators/foundation/public/stylesheets/foundation6/components/_pagination.scss +77 -45
- data/generators/foundation/public/stylesheets/foundation6/components/_progress-bar.scss +16 -35
- data/generators/foundation/public/stylesheets/foundation6/components/_responsive-embed.scss +70 -0
- data/generators/foundation/public/stylesheets/foundation6/components/_reveal.scss +59 -34
- data/generators/foundation/public/stylesheets/foundation6/components/_slider.scss +17 -38
- data/generators/foundation/public/stylesheets/foundation6/components/_sticky.scss +5 -4
- data/generators/foundation/public/stylesheets/foundation6/components/_switch.scss +52 -36
- data/generators/foundation/public/stylesheets/foundation6/components/_table.scss +197 -79
- data/generators/foundation/public/stylesheets/foundation6/components/_tabs.scss +126 -67
- data/generators/foundation/public/stylesheets/foundation6/components/_thumbnail.scss +17 -4
- data/generators/foundation/public/stylesheets/foundation6/components/_title-bar.scss +61 -21
- data/generators/foundation/public/stylesheets/foundation6/components/_tooltip.scss +74 -24
- data/generators/foundation/public/stylesheets/foundation6/components/_top-bar.scss +128 -10
- data/generators/foundation/public/stylesheets/foundation6/components/_visibility.scss +6 -5
- data/generators/foundation/public/stylesheets/foundation6/forms/_checkbox.scss +14 -9
- data/generators/foundation/public/stylesheets/foundation6/forms/_error.scss +12 -5
- data/generators/foundation/public/stylesheets/foundation6/forms/_fieldset.scss +6 -6
- data/generators/foundation/public/stylesheets/foundation6/forms/_forms.scss +11 -9
- data/generators/foundation/public/stylesheets/foundation6/forms/_help-text.scss +1 -1
- data/generators/foundation/public/stylesheets/foundation6/forms/_input-group.scss +82 -10
- data/generators/foundation/public/stylesheets/foundation6/forms/_label.scss +2 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_meter.scss +116 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_progress.scss +94 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_range.scss +149 -0
- data/generators/foundation/public/stylesheets/foundation6/forms/_select.scss +36 -14
- data/generators/foundation/public/stylesheets/foundation6/forms/_text.scss +53 -27
- data/generators/foundation/public/stylesheets/foundation6/foundation.scss +59 -17
- data/generators/foundation/public/stylesheets/foundation6/grid/_classes.scss +100 -56
- data/generators/foundation/public/stylesheets/foundation6/grid/_column.scss +22 -22
- data/generators/foundation/public/stylesheets/foundation6/grid/_flex-grid.scss +164 -96
- data/generators/foundation/public/stylesheets/foundation6/grid/_grid.scss +19 -4
- data/generators/foundation/public/stylesheets/foundation6/grid/_gutter.scss +61 -10
- data/generators/foundation/public/stylesheets/foundation6/grid/_layout.scss +49 -5
- data/generators/foundation/public/stylesheets/foundation6/grid/_position.scss +14 -9
- data/generators/foundation/public/stylesheets/foundation6/grid/_row.scss +42 -15
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/_classes.scss +11 -4
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/effects/_fade.scss +4 -1
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/effects/_zoom.scss +1 -1
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/transitions/_slide.scss +1 -1
- data/generators/foundation/public/stylesheets/foundation6/motion-ui/util/_transition.scss +1 -1
- data/generators/foundation/public/stylesheets/foundation6/prototype/_arrow.scss +36 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_border-box.scss +35 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_border-none.scss +35 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_bordered.scss +54 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_box.scss +23 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_display.scss +50 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_font-styling.scss +95 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_list-style-type.scss +95 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_overflow.scss +72 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_position.scss +114 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_prototype.scss +87 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_relation.scss +157 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_rotate.scss +31 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_rounded.scss +54 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_separator.scss +96 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_shadow.scss +43 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_sizing.scss +73 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_spacing.scss +204 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_text-decoration.scss +48 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_text-transformation.scss +48 -0
- data/generators/foundation/public/stylesheets/foundation6/prototype/_text-utilities.scss +88 -0
- data/generators/foundation/public/stylesheets/foundation6/settings/_settings.scss +454 -116
- data/generators/foundation/public/stylesheets/foundation6/typography/_alignment.scss +9 -8
- data/generators/foundation/public/stylesheets/foundation6/typography/_base.scss +128 -55
- data/generators/foundation/public/stylesheets/foundation6/typography/_helpers.scss +7 -4
- data/generators/foundation/public/stylesheets/foundation6/typography/_print.scss +22 -9
- data/generators/foundation/public/stylesheets/foundation6/typography/_typography.scss +0 -2
- data/generators/foundation/public/stylesheets/foundation6/util/_breakpoint.scss +213 -47
- data/generators/foundation/public/stylesheets/foundation6/util/_color.scss +105 -17
- data/generators/foundation/public/stylesheets/foundation6/util/_direction.scss +31 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_flex.scss +85 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_math.scss +72 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_mixins.scss +161 -38
- data/generators/foundation/public/stylesheets/foundation6/util/_selector.scss +5 -3
- data/generators/foundation/public/stylesheets/foundation6/util/_typography.scss +26 -0
- data/generators/foundation/public/stylesheets/foundation6/util/_unit.scss +100 -17
- data/generators/foundation/public/stylesheets/foundation6/util/_util.scss +4 -5
- data/generators/foundation/public/stylesheets/foundation6/util/_value.scss +68 -25
- data/generators/foundation/public/stylesheets/foundation6/vendor/normalize-scss/sass/_normalize.scss +3 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/normalize-scss/sass/normalize/_import-now.scss +11 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/normalize-scss/sass/normalize/_normalize-mixin.scss +676 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/normalize-scss/sass/normalize/_variables.scss +36 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/normalize-scss/sass/normalize/_vertical-rhythm.scss +61 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/sassy-lists/stylesheets/functions/_contain.scss +31 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/sassy-lists/stylesheets/functions/_purge.scss +38 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/sassy-lists/stylesheets/functions/_remove.scss +31 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/sassy-lists/stylesheets/functions/_replace.scss +46 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/sassy-lists/stylesheets/functions/_to-list.scss +27 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/sassy-lists/stylesheets/helpers/_missing-dependencies.scss +25 -0
- data/generators/foundation/public/stylesheets/foundation6/vendor/sassy-lists/stylesheets/helpers/_true.scss +13 -0
- data/generators/foundation/public/stylesheets/foundation6/xy-grid/_cell.scss +169 -0
- data/generators/foundation/public/stylesheets/foundation6/xy-grid/_classes.scss +476 -0
- data/generators/foundation/public/stylesheets/foundation6/xy-grid/_collapse.scss +74 -0
- data/generators/foundation/public/stylesheets/foundation6/xy-grid/_frame.scss +85 -0
- data/generators/foundation/public/stylesheets/foundation6/xy-grid/_grid.scss +35 -0
- data/generators/foundation/public/stylesheets/foundation6/xy-grid/_gutters.scss +45 -0
- data/generators/foundation/public/stylesheets/foundation6/xy-grid/_layout.scss +33 -0
- data/generators/foundation/public/stylesheets/foundation6/xy-grid/_position.scss +28 -0
- data/generators/foundation/public/stylesheets/foundation6/xy-grid/_xy-grid.scss +51 -0
- data/lib/locomotive/wagon/tools/styled_yaml.rb +1 -1
- data/lib/locomotive/wagon/version.rb +1 -1
- data/locomotivecms_wagon.gemspec +2 -2
- data/spec/fixtures/cassettes/authenticate.yml +102 -48
- data/spec/fixtures/cassettes/delete.yml +519 -259
- data/spec/fixtures/cassettes/push.yml +2724 -1486
- metadata +61 -10
- data/generators/foundation/public/stylesheets/foundation6/motion-ui.scss +0 -4
- data/generators/foundation/public/stylesheets/foundation6/vendor/normalize.scss +0 -424
@@ -12,7 +12,15 @@ $label-background: $primary-color !default;
|
|
12
12
|
|
13
13
|
/// Default text color for labels.
|
14
14
|
/// @type Color
|
15
|
-
$label-color:
|
15
|
+
$label-color: $white !default;
|
16
|
+
|
17
|
+
/// Alternate text color for labels.
|
18
|
+
/// @type Color
|
19
|
+
$label-color-alt: $black !default;
|
20
|
+
|
21
|
+
/// Coloring classes. A map of classes to output in your CSS, like `.secondary`, `.success`, and so on.
|
22
|
+
/// @type Map
|
23
|
+
$label-palette: $foundation-palette !default;
|
16
24
|
|
17
25
|
/// Default font size for labels.
|
18
26
|
/// @type Number
|
@@ -30,11 +38,13 @@ $label-radius: $global-radius !default;
|
|
30
38
|
@mixin label {
|
31
39
|
display: inline-block;
|
32
40
|
padding: $label-padding;
|
41
|
+
|
42
|
+
border-radius: $label-radius;
|
43
|
+
|
33
44
|
font-size: $label-font-size;
|
34
45
|
line-height: 1;
|
35
46
|
white-space: nowrap;
|
36
47
|
cursor: default;
|
37
|
-
border-radius: $label-radius;
|
38
48
|
}
|
39
49
|
|
40
50
|
@mixin foundation-label {
|
@@ -44,12 +54,10 @@ $label-radius: $global-radius !default;
|
|
44
54
|
background: $label-background;
|
45
55
|
color: $label-color;
|
46
56
|
|
47
|
-
@each $name, $color in $
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
color: foreground($color);
|
52
|
-
}
|
57
|
+
@each $name, $color in $label-palette {
|
58
|
+
&.#{$name} {
|
59
|
+
background: $color;
|
60
|
+
color: color-pick-contrast($color, ($label-color, $label-color-alt));
|
53
61
|
}
|
54
62
|
}
|
55
63
|
}
|
@@ -14,37 +14,57 @@ $mediaobject-margin-bottom: $global-margin !default;
|
|
14
14
|
/// @type Number
|
15
15
|
$mediaobject-section-padding: $global-padding !default;
|
16
16
|
|
17
|
-
///
|
17
|
+
/// Width of images within a media object, when the object is stacked vertically. Set to 'auto' to use the image's natural width.
|
18
18
|
/// @type Number
|
19
19
|
$mediaobject-image-width-stacked: 100% !default;
|
20
20
|
|
21
21
|
/// Adds styles for a media object container.
|
22
22
|
@mixin media-object-container {
|
23
|
+
display: if($global-flexbox, flex, block);
|
23
24
|
margin-bottom: $mediaobject-margin-bottom;
|
24
|
-
|
25
|
+
|
26
|
+
@if $global-flexbox {
|
27
|
+
flex-wrap: nowrap;
|
28
|
+
}
|
25
29
|
}
|
26
30
|
|
27
31
|
/// Adds styles for sections within a media object.
|
28
32
|
/// @param {Number} $padding [$mediaobject-section-padding] - Padding between sections.
|
29
33
|
@mixin media-object-section($padding: $mediaobject-section-padding) {
|
30
|
-
|
31
|
-
|
34
|
+
@if $global-flexbox {
|
35
|
+
flex: 0 1 auto;
|
36
|
+
}
|
37
|
+
@else {
|
38
|
+
display: table-cell;
|
39
|
+
vertical-align: top;
|
40
|
+
}
|
32
41
|
|
33
42
|
&:first-child {
|
34
43
|
padding-#{$global-right}: $padding;
|
35
44
|
}
|
36
45
|
|
37
|
-
&:last-child:not(
|
46
|
+
&:last-child:not(:nth-child(2)) {
|
38
47
|
padding-#{$global-left}: $padding;
|
39
48
|
}
|
49
|
+
|
50
|
+
> :last-child {
|
51
|
+
margin-bottom: 0;
|
52
|
+
}
|
40
53
|
}
|
41
54
|
|
42
55
|
/// Adds styles to stack sections of a media object. Apply this to the section elements, not the container.
|
43
56
|
@mixin media-object-stack {
|
44
|
-
display: block;
|
45
57
|
padding: 0;
|
46
58
|
padding-bottom: $mediaobject-section-padding;
|
47
59
|
|
60
|
+
@if $global-flexbox {
|
61
|
+
flex-basis: 100%;
|
62
|
+
max-width: 100%;
|
63
|
+
}
|
64
|
+
@else {
|
65
|
+
display: block;
|
66
|
+
}
|
67
|
+
|
48
68
|
img {
|
49
69
|
width: $mediaobject-image-width-stacked;
|
50
70
|
}
|
@@ -58,8 +78,16 @@ $mediaobject-image-width-stacked: 100% !default;
|
|
58
78
|
max-width: none;
|
59
79
|
}
|
60
80
|
|
61
|
-
|
62
|
-
|
81
|
+
@if $global-flexbox {
|
82
|
+
&.stack-for-#{$-zf-zero-breakpoint} {
|
83
|
+
@include breakpoint($-zf-zero-breakpoint only) {
|
84
|
+
flex-wrap: wrap;
|
85
|
+
}
|
86
|
+
}
|
87
|
+
}
|
88
|
+
|
89
|
+
&.stack-for-#{$-zf-zero-breakpoint} .media-object-section {
|
90
|
+
@include breakpoint($-zf-zero-breakpoint only) {
|
63
91
|
@include media-object-stack;
|
64
92
|
}
|
65
93
|
}
|
@@ -68,7 +96,19 @@ $mediaobject-image-width-stacked: 100% !default;
|
|
68
96
|
.media-object-section {
|
69
97
|
@include media-object-section;
|
70
98
|
|
71
|
-
|
72
|
-
|
99
|
+
@if $global-flexbox {
|
100
|
+
&.main-section {
|
101
|
+
flex: 1 1 0px; // sass-lint:disable-line zero-unit
|
102
|
+
}
|
103
|
+
}
|
104
|
+
@else {
|
105
|
+
&.middle {
|
106
|
+
vertical-align: middle;
|
107
|
+
}
|
108
|
+
|
109
|
+
&.bottom {
|
110
|
+
vertical-align: bottom;
|
111
|
+
}
|
112
|
+
}
|
73
113
|
}
|
74
114
|
}
|
@@ -12,59 +12,163 @@ $menu-margin: 0 !default;
|
|
12
12
|
|
13
13
|
/// Left-hand margin of a nested menu.
|
14
14
|
/// @type Number
|
15
|
-
$menu-margin-nested
|
15
|
+
$menu-nested-margin: $global-menu-nested-margin !default;
|
16
16
|
|
17
|
-
/// Padding for items in a menu.
|
17
|
+
/// Padding for items in a pill menu.
|
18
18
|
/// @type Number
|
19
|
-
$menu-
|
19
|
+
$menu-items-padding: $global-menu-padding !default;
|
20
|
+
|
21
|
+
/// margin for items in a simple menu.
|
22
|
+
/// @type Number
|
23
|
+
$menu-simple-margin: 1rem !default;
|
24
|
+
|
25
|
+
/// Text color of an active menu item.
|
26
|
+
/// @type Color
|
27
|
+
$menu-item-color-active: $white !default;
|
28
|
+
|
29
|
+
/// Background color of an active menu item.
|
30
|
+
/// @type Color
|
31
|
+
$menu-item-background-active: get-color(primary) !default;
|
20
32
|
|
21
33
|
/// Spacing between an icon and text in a menu item.
|
22
34
|
/// @type Number
|
23
35
|
$menu-icon-spacing: 0.25rem !default;
|
24
36
|
|
25
|
-
///
|
26
|
-
/// @type
|
27
|
-
$menu-
|
37
|
+
/// Background color for an hovered menu item.
|
38
|
+
/// @type Color
|
39
|
+
$menu-item-background-hover: $light-gray !default;
|
40
|
+
|
41
|
+
/// Backward compatibility for menu state. If true, this duplicate `active` with `is-active`.
|
42
|
+
/// But please note that `active` will be removed in upcoming versions.
|
43
|
+
/// @type Boolean
|
44
|
+
$menu-state-back-compat: true !default;
|
45
|
+
|
46
|
+
/// Backward compatibility for menu centered. If true, this duplicate `.menu-centered > .menu` with `.menu.align-center`.
|
47
|
+
/// But please note that `menu-centered` will be removed in upcoming versions.
|
48
|
+
/// @type Boolean
|
49
|
+
$menu-centered-back-compat: true !default;
|
50
|
+
|
51
|
+
/// Backward compatibility for using `icon-*` classes without `.icons` classes
|
52
|
+
/// But please note that this backward compatibility will be removed in upcoming versions.
|
53
|
+
/// @type Boolean
|
54
|
+
$menu-icons-back-compat: true !default;
|
28
55
|
|
29
56
|
/// Creates the base styles for a Menu.
|
30
57
|
@mixin menu-base {
|
31
|
-
|
32
|
-
|
58
|
+
padding: 0;
|
59
|
+
margin: 0;
|
60
|
+
list-style: none;
|
61
|
+
position: relative;
|
62
|
+
|
63
|
+
@if $global-flexbox {
|
64
|
+
display: flex;
|
65
|
+
flex-wrap: wrap;
|
66
|
+
}
|
33
67
|
|
34
|
-
|
35
|
-
> li {
|
68
|
+
li {
|
36
69
|
@include disable-mouse-outline;
|
37
|
-
display: table-cell;
|
38
|
-
vertical-align: middle;
|
39
70
|
}
|
40
71
|
|
41
|
-
|
42
|
-
|
43
|
-
display: block;
|
44
|
-
padding: $menu-item-padding;
|
72
|
+
a,
|
73
|
+
.button {
|
45
74
|
line-height: 1;
|
75
|
+
text-decoration: none;
|
76
|
+
display: block;
|
77
|
+
padding: $menu-items-padding;
|
46
78
|
}
|
47
79
|
|
48
80
|
// Reset styles of inner elements
|
49
81
|
input,
|
82
|
+
select,
|
50
83
|
a,
|
51
84
|
button {
|
52
85
|
margin-bottom: 0;
|
53
86
|
}
|
87
|
+
|
88
|
+
input {
|
89
|
+
display: inline-block;
|
90
|
+
}
|
54
91
|
}
|
55
92
|
|
56
93
|
/// Expands the items of a Menu, so each item is the same width.
|
57
|
-
|
58
|
-
@
|
59
|
-
|
60
|
-
|
94
|
+
@mixin menu-expand {
|
95
|
+
@if $global-flexbox {
|
96
|
+
li {
|
97
|
+
flex: 1 1 0px; // sass-lint:disable-line zero-unit
|
98
|
+
}
|
99
|
+
}
|
100
|
+
@else {
|
101
|
+
display: table;
|
102
|
+
width: 100%;
|
103
|
+
|
104
|
+
> li {
|
105
|
+
display: table-cell;
|
106
|
+
vertical-align: middle;
|
107
|
+
}
|
108
|
+
}
|
109
|
+
}
|
110
|
+
|
111
|
+
/// Align menu items.
|
112
|
+
@mixin menu-align($alignment) {
|
113
|
+
@if $alignment == left {
|
114
|
+
@if $global-flexbox {
|
115
|
+
justify-content: flex-start;
|
116
|
+
}
|
117
|
+
@else {
|
118
|
+
text-align: $global-left;
|
119
|
+
}
|
120
|
+
}
|
121
|
+
@else if $alignment == right {
|
122
|
+
@if $global-flexbox {
|
123
|
+
li {
|
124
|
+
display: flex;
|
125
|
+
justify-content: flex-end;
|
126
|
+
|
127
|
+
.submenu li {
|
128
|
+
justify-content: flex-start;
|
129
|
+
}
|
130
|
+
}
|
131
|
+
|
132
|
+
&.vertical li {
|
133
|
+
display: block;
|
134
|
+
text-align: $global-right;
|
135
|
+
|
136
|
+
.submenu li {
|
137
|
+
text-align: $global-right;
|
138
|
+
}
|
139
|
+
}
|
140
|
+
}
|
141
|
+
@else {
|
142
|
+
text-align: $global-right;
|
143
|
+
|
144
|
+
.submenu li {
|
145
|
+
text-align: $global-left;
|
146
|
+
}
|
61
147
|
|
62
|
-
|
63
|
-
|
64
|
-
|
148
|
+
&.vertical {
|
149
|
+
.submenu li {
|
150
|
+
text-align: $global-right;
|
151
|
+
}
|
152
|
+
}
|
153
|
+
}
|
154
|
+
}
|
155
|
+
@else if $alignment == center {
|
156
|
+
@if $global-flexbox {
|
157
|
+
li {
|
158
|
+
display: flex;
|
159
|
+
justify-content: center;
|
160
|
+
|
161
|
+
.submenu li {
|
162
|
+
justify-content: flex-start;
|
163
|
+
}
|
164
|
+
}
|
65
165
|
}
|
66
|
-
@else
|
67
|
-
|
166
|
+
@else {
|
167
|
+
text-align: center;
|
168
|
+
|
169
|
+
.submenu li {
|
170
|
+
text-align: $global-left;
|
171
|
+
}
|
68
172
|
}
|
69
173
|
}
|
70
174
|
}
|
@@ -73,13 +177,25 @@ $menu-expand-max: 6 !default;
|
|
73
177
|
/// @param {Keyword} $dir [horizontal] - Direction of the Menu. Can be `horizontal` or `vertical`.
|
74
178
|
@mixin menu-direction($dir: horizontal) {
|
75
179
|
@if $dir == horizontal {
|
76
|
-
|
77
|
-
|
180
|
+
@if $global-flexbox {
|
181
|
+
flex-wrap: wrap;
|
182
|
+
flex-direction: row;
|
183
|
+
}
|
184
|
+
@else {
|
185
|
+
li {
|
186
|
+
display: inline-block;
|
187
|
+
}
|
78
188
|
}
|
79
189
|
}
|
80
190
|
@else if $dir == vertical {
|
81
|
-
|
82
|
-
|
191
|
+
@if $global-flexbox {
|
192
|
+
flex-wrap: nowrap;
|
193
|
+
flex-direction: column;
|
194
|
+
}
|
195
|
+
@else {
|
196
|
+
li {
|
197
|
+
display: block;
|
198
|
+
}
|
83
199
|
}
|
84
200
|
}
|
85
201
|
@else {
|
@@ -88,91 +204,176 @@ $menu-expand-max: 6 !default;
|
|
88
204
|
}
|
89
205
|
|
90
206
|
/// Creates a simple Menu, which has no padding or hover state.
|
91
|
-
@
|
207
|
+
/// @param {Keyword} $dir [$global-left] - Direction of the menu. This effects the side of the `<li>` that receives the margin.
|
208
|
+
/// @param {Number} $margin [$menu-simple-margin] - The margin to apply to each `<li>`.
|
209
|
+
@mixin menu-simple($dir: $global-left, $margin: $menu-simple-margin) {
|
210
|
+
@if $global-flexbox {
|
211
|
+
align-items: center;
|
212
|
+
}
|
213
|
+
|
214
|
+
li + li {
|
215
|
+
margin-#{$dir}: $margin;
|
216
|
+
}
|
217
|
+
|
92
218
|
a {
|
93
219
|
padding: 0;
|
94
|
-
margin-#{$global-right}: get-side($menu-item-padding, $global-right);
|
95
220
|
}
|
96
221
|
}
|
97
222
|
|
98
223
|
/// Adds styles for a nested Menu, by adding `margin-left` to the menu.
|
99
|
-
/// @param {Keyword|Number} $
|
100
|
-
@
|
101
|
-
|
224
|
+
/// @param {Keyword|Number} $margin [$menu-nested-margin] - Length of the margin.
|
225
|
+
/// @param {Keyword} $nested-alignment [left] - Alignment of the nested class
|
226
|
+
@mixin menu-nested(
|
227
|
+
$margin: $menu-nested-margin,
|
228
|
+
$nested-alignment: left
|
229
|
+
) {
|
230
|
+
@if $nested-alignment == right {
|
231
|
+
margin-#{$global-right}: $margin;
|
232
|
+
margin-#{$global-left}: 0;
|
233
|
+
}
|
234
|
+
@else {
|
235
|
+
margin-#{$global-right}: 0;
|
236
|
+
margin-#{$global-left}: $margin;
|
237
|
+
}
|
238
|
+
|
102
239
|
}
|
103
240
|
|
104
|
-
/// Adds
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
241
|
+
/// Adds basic styles for icons in menus.
|
242
|
+
@mixin menu-icons() {
|
243
|
+
@if $global-flexbox {
|
244
|
+
a {
|
245
|
+
display: flex;
|
246
|
+
}
|
247
|
+
}
|
248
|
+
@else {
|
249
|
+
img,
|
250
|
+
i,
|
251
|
+
svg {
|
252
|
+
vertical-align: middle;
|
253
|
+
|
254
|
+
+ span {
|
112
255
|
vertical-align: middle;
|
113
256
|
}
|
257
|
+
}
|
258
|
+
}
|
259
|
+
}
|
114
260
|
|
115
|
-
|
116
|
-
|
261
|
+
/// Adds position classes for icons within a menu.
|
262
|
+
@mixin menu-icon-position($position: left, $spacing: $menu-icon-spacing) {
|
263
|
+
@if $position == left {
|
264
|
+
li a {
|
265
|
+
@if $global-flexbox {
|
266
|
+
flex-flow: row nowrap;
|
267
|
+
}
|
268
|
+
|
269
|
+
img,
|
270
|
+
i,
|
271
|
+
svg {
|
272
|
+
margin-#{$global-right}: $spacing;
|
273
|
+
|
274
|
+
@if not $global-flexbox {
|
275
|
+
display: inline-block;
|
276
|
+
}
|
117
277
|
}
|
118
278
|
}
|
119
279
|
}
|
280
|
+
@else if $position == right {
|
281
|
+
li a {
|
282
|
+
@if $global-flexbox {
|
283
|
+
flex-flow: row nowrap;
|
284
|
+
}
|
120
285
|
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
286
|
+
img,
|
287
|
+
i,
|
288
|
+
svg {
|
289
|
+
margin-#{$global-left}: $spacing;
|
290
|
+
|
291
|
+
@if not $global-flexbox {
|
292
|
+
display: inline-block;
|
293
|
+
}
|
127
294
|
}
|
128
295
|
}
|
129
296
|
}
|
130
297
|
@else if $position == top {
|
131
|
-
|
132
|
-
|
298
|
+
li a {
|
299
|
+
@if $global-flexbox {
|
300
|
+
flex-flow: column nowrap;
|
301
|
+
}
|
302
|
+
@else {
|
303
|
+
text-align: center;
|
304
|
+
}
|
133
305
|
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
306
|
+
img,
|
307
|
+
i,
|
308
|
+
svg {
|
309
|
+
@if not $global-flexbox {
|
310
|
+
display: block;
|
311
|
+
margin: 0 auto $spacing;
|
312
|
+
}
|
313
|
+
@else {
|
314
|
+
align-self: stretch;
|
315
|
+
margin-bottom: $spacing;
|
316
|
+
text-align: center;
|
317
|
+
}
|
318
|
+
}
|
319
|
+
}
|
320
|
+
}
|
321
|
+
@else if $position == bottom {
|
322
|
+
li a {
|
323
|
+
@if $global-flexbox {
|
324
|
+
flex-flow: column nowrap;
|
325
|
+
}
|
326
|
+
@else {
|
327
|
+
text-align: center;
|
328
|
+
}
|
329
|
+
|
330
|
+
img,
|
331
|
+
i,
|
332
|
+
svg {
|
333
|
+
@if not $global-flexbox {
|
334
|
+
display: block;
|
335
|
+
margin: $spacing auto 0;
|
336
|
+
}
|
337
|
+
@else {
|
338
|
+
align-self: stretch;
|
339
|
+
margin-bottom: $spacing;
|
340
|
+
text-align: center;
|
341
|
+
}
|
138
342
|
}
|
139
343
|
}
|
140
344
|
}
|
141
345
|
}
|
142
346
|
|
143
347
|
@mixin menu-text {
|
348
|
+
padding: $global-menu-padding;
|
349
|
+
|
144
350
|
font-weight: bold;
|
145
|
-
color: inherit;
|
146
351
|
line-height: 1;
|
147
|
-
|
148
|
-
|
149
|
-
|
352
|
+
color: inherit;
|
353
|
+
}
|
354
|
+
|
355
|
+
@mixin menu-state-active {
|
356
|
+
background: $menu-item-background-active;
|
357
|
+
color: $menu-item-color-active;
|
150
358
|
}
|
151
359
|
|
152
360
|
@mixin foundation-menu {
|
153
361
|
.menu {
|
154
362
|
@include menu-base;
|
155
|
-
@include menu-icons;
|
156
363
|
|
157
|
-
//
|
158
|
-
|
364
|
+
// Default orientation: horizontal
|
365
|
+
&, &.horizontal {
|
366
|
+
@include menu-direction(horizontal);
|
367
|
+
}
|
159
368
|
|
369
|
+
// Vertical orientation modifier
|
160
370
|
&.vertical {
|
161
371
|
@include menu-direction(vertical);
|
162
372
|
}
|
163
373
|
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
&.#{$size}-horizontal {
|
168
|
-
@include menu-direction(horizontal);
|
169
|
-
}
|
170
|
-
|
171
|
-
&.#{$size}-vertical {
|
172
|
-
@include menu-direction(vertical);
|
173
|
-
}
|
174
|
-
}
|
175
|
-
}
|
374
|
+
// Even-width modifier for horizontal orientation
|
375
|
+
&.expanded {
|
376
|
+
@include menu-expand;
|
176
377
|
}
|
177
378
|
|
178
379
|
// Simple
|
@@ -180,34 +381,115 @@ $menu-expand-max: 6 !default;
|
|
180
381
|
@include menu-simple;
|
181
382
|
}
|
182
383
|
|
183
|
-
//
|
184
|
-
|
185
|
-
|
186
|
-
|
384
|
+
// Breakpoint specific versions
|
385
|
+
@include -zf-each-breakpoint($small: false) {
|
386
|
+
&.#{$-zf-size}-horizontal {
|
387
|
+
@include menu-direction(horizontal);
|
187
388
|
}
|
188
|
-
}
|
189
389
|
|
190
|
-
|
191
|
-
|
192
|
-
|
390
|
+
&.#{$-zf-size}-vertical {
|
391
|
+
@include menu-direction(vertical);
|
392
|
+
}
|
193
393
|
|
194
|
-
|
195
|
-
|
394
|
+
&.#{$-zf-size}-expanded {
|
395
|
+
@include menu-expand;
|
196
396
|
}
|
197
|
-
}
|
198
397
|
|
199
|
-
|
200
|
-
|
201
|
-
|
398
|
+
&.#{$-zf-size}-simple {
|
399
|
+
@include menu-expand;
|
400
|
+
}
|
202
401
|
}
|
203
402
|
|
204
403
|
// Nesting
|
205
404
|
&.nested {
|
206
405
|
@include menu-nested;
|
207
406
|
}
|
407
|
+
|
408
|
+
// Icon Base Styles
|
409
|
+
&.icons {
|
410
|
+
@include menu-icons;
|
411
|
+
}
|
412
|
+
|
413
|
+
// Backward Compatibility for active state
|
414
|
+
@if $menu-icons-back-compat {
|
415
|
+
&.icon-top,
|
416
|
+
&.icon-right,
|
417
|
+
&.icon-bottom,
|
418
|
+
&.icon-left {
|
419
|
+
@include menu-icons;
|
420
|
+
}
|
421
|
+
}
|
422
|
+
|
423
|
+
// Icon Left
|
424
|
+
&.icon-left {
|
425
|
+
@include menu-icon-position(left);
|
426
|
+
}
|
427
|
+
|
428
|
+
// Icon Right
|
429
|
+
&.icon-right {
|
430
|
+
@include menu-icon-position(right);
|
431
|
+
}
|
432
|
+
|
433
|
+
// Icon Top
|
434
|
+
&.icon-top {
|
435
|
+
@include menu-icon-position(top);
|
436
|
+
}
|
437
|
+
|
438
|
+
// Icon Bottom
|
439
|
+
&.icon-bottom {
|
440
|
+
@include menu-icon-position(bottom);
|
441
|
+
}
|
442
|
+
|
443
|
+
// Active state
|
444
|
+
.is-active > a {
|
445
|
+
@include menu-state-active;
|
446
|
+
}
|
447
|
+
|
448
|
+
// Backward Compatibility for active state
|
449
|
+
@if $menu-state-back-compat {
|
450
|
+
.active > a {
|
451
|
+
@include menu-state-active;
|
452
|
+
}
|
453
|
+
}
|
454
|
+
|
455
|
+
// Align left
|
456
|
+
&.align-#{$global-left} {
|
457
|
+
@include menu-align(left);
|
458
|
+
}
|
459
|
+
|
460
|
+
// Align right
|
461
|
+
&.align-#{$global-right} {
|
462
|
+
@include menu-align(right);
|
463
|
+
|
464
|
+
.nested {
|
465
|
+
@include menu-nested($nested-alignment: right);
|
466
|
+
}
|
467
|
+
}
|
468
|
+
|
469
|
+
// Align center
|
470
|
+
&.align-center {
|
471
|
+
@include menu-align(center);
|
472
|
+
}
|
473
|
+
|
474
|
+
.menu-text {
|
475
|
+
@include menu-text;
|
476
|
+
}
|
477
|
+
}
|
478
|
+
|
479
|
+
@if $menu-centered-back-compat {
|
480
|
+
.menu-centered {
|
481
|
+
> .menu {
|
482
|
+
@if $global-flexbox {
|
483
|
+
justify-content: center;
|
484
|
+
}
|
485
|
+
|
486
|
+
@include menu-align(center);
|
487
|
+
}
|
488
|
+
}
|
208
489
|
}
|
209
490
|
|
210
|
-
|
211
|
-
|
491
|
+
// Prevent FOUC when using the Responsive Menu plugin
|
492
|
+
.no-js [data-responsive-menu] ul {
|
493
|
+
display: none;
|
212
494
|
}
|
213
495
|
}
|