bulma-rails 0.7.3 → 0.9.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +2 -0
- data/README.md +1 -1
- data/app/assets/stylesheets/bulma.sass +3 -1
- data/app/assets/stylesheets/sass/base/_all.sass +0 -1
- data/app/assets/stylesheets/sass/base/generic.sass +22 -10
- data/app/assets/stylesheets/sass/base/helpers.sass +1 -276
- data/app/assets/stylesheets/sass/base/minireset.sass +3 -3
- data/app/assets/stylesheets/sass/components/_all.sass +0 -1
- data/app/assets/stylesheets/sass/components/breadcrumb.sass +4 -4
- data/app/assets/stylesheets/sass/components/card.sass +15 -10
- data/app/assets/stylesheets/sass/components/dropdown.sass +15 -11
- data/app/assets/stylesheets/sass/components/level.sass +5 -3
- data/app/assets/stylesheets/sass/components/media.sass +14 -10
- data/app/assets/stylesheets/sass/components/menu.sass +16 -9
- data/app/assets/stylesheets/sass/components/message.sass +24 -11
- data/app/assets/stylesheets/sass/components/modal.sass +4 -4
- data/app/assets/stylesheets/sass/components/navbar.sass +40 -27
- data/app/assets/stylesheets/sass/components/pagination.sass +16 -10
- data/app/assets/stylesheets/sass/components/panel.sass +33 -15
- data/app/assets/stylesheets/sass/components/tabs.sass +36 -13
- data/app/assets/stylesheets/sass/elements/_all.sass +0 -1
- data/app/assets/stylesheets/sass/elements/box.sass +4 -4
- data/app/assets/stylesheets/sass/elements/button.sass +79 -31
- data/app/assets/stylesheets/sass/elements/container.sass +14 -15
- data/app/assets/stylesheets/sass/elements/content.sass +9 -5
- data/app/assets/stylesheets/sass/elements/form.sass +1 -602
- data/app/assets/stylesheets/sass/elements/image.sass +2 -0
- data/app/assets/stylesheets/sass/elements/notification.sass +16 -3
- data/app/assets/stylesheets/sass/elements/progress.sass +16 -14
- data/app/assets/stylesheets/sass/elements/table.sass +10 -7
- data/app/assets/stylesheets/sass/elements/tag.sass +31 -25
- data/app/assets/stylesheets/sass/elements/title.sass +9 -3
- data/app/assets/stylesheets/sass/form/_all.sass +8 -0
- data/app/assets/stylesheets/sass/form/checkbox-radio.sass +21 -0
- data/app/assets/stylesheets/sass/form/file.sass +180 -0
- data/app/assets/stylesheets/sass/form/input-textarea.sass +64 -0
- data/app/assets/stylesheets/sass/form/select.sass +85 -0
- data/app/assets/stylesheets/sass/form/shared.sass +55 -0
- data/app/assets/stylesheets/sass/form/tools.sass +213 -0
- data/app/assets/stylesheets/sass/grid/columns.sass +7 -7
- data/app/assets/stylesheets/sass/grid/tiles.sass +8 -6
- data/app/assets/stylesheets/sass/helpers/_all.sass +10 -0
- data/app/assets/stylesheets/sass/helpers/color.sass +37 -0
- data/app/assets/stylesheets/sass/helpers/float.sass +8 -0
- data/app/assets/stylesheets/sass/helpers/other.sass +8 -0
- data/app/assets/stylesheets/sass/helpers/overflow.sass +2 -0
- data/app/assets/stylesheets/sass/helpers/position.sass +5 -0
- data/app/assets/stylesheets/sass/helpers/spacing.sass +28 -0
- data/app/assets/stylesheets/sass/helpers/typography.sass +98 -0
- data/app/assets/stylesheets/sass/helpers/visibility.sass +122 -0
- data/app/assets/stylesheets/sass/layout/footer.sass +4 -1
- data/app/assets/stylesheets/sass/layout/hero.sass +23 -34
- data/app/assets/stylesheets/sass/utilities/_all.sass +1 -1
- data/app/assets/stylesheets/sass/utilities/controls.sass +3 -3
- data/app/assets/stylesheets/sass/utilities/derived-variables.scss +132 -0
- data/app/assets/stylesheets/sass/utilities/functions.sass +68 -15
- data/app/assets/stylesheets/sass/utilities/initial-variables.sass +10 -4
- data/app/assets/stylesheets/sass/utilities/mixins.sass +31 -7
- data/bulma-rails.gemspec +2 -2
- metadata +23 -8
- data/app/assets/stylesheets/sass/components/list.sass +0 -39
- data/app/assets/stylesheets/sass/utilities/derived-variables.sass +0 -85
@@ -1,8 +1,13 @@
|
|
1
|
-
$pagination-color: $
|
2
|
-
$pagination-border-color: $
|
1
|
+
$pagination-color: $text-strong !default
|
2
|
+
$pagination-border-color: $border !default
|
3
3
|
$pagination-margin: -0.25rem !default
|
4
4
|
$pagination-min-width: $control-height !default
|
5
5
|
|
6
|
+
$pagination-item-font-size: 1em !default
|
7
|
+
$pagination-item-margin: 0.25rem !default
|
8
|
+
$pagination-item-padding-left: 0.5em !default
|
9
|
+
$pagination-item-padding-right: 0.5em !default
|
10
|
+
|
6
11
|
$pagination-hover-color: $link-hover !default
|
7
12
|
$pagination-hover-border-color: $link-hover-border !default
|
8
13
|
|
@@ -12,9 +17,9 @@ $pagination-focus-border-color: $link-focus-border !default
|
|
12
17
|
$pagination-active-color: $link-active !default
|
13
18
|
$pagination-active-border-color: $link-active-border !default
|
14
19
|
|
15
|
-
$pagination-disabled-color: $
|
16
|
-
$pagination-disabled-background-color: $
|
17
|
-
$pagination-disabled-border-color: $
|
20
|
+
$pagination-disabled-color: $text-light !default
|
21
|
+
$pagination-disabled-background-color: $border !default
|
22
|
+
$pagination-disabled-border-color: $border !default
|
18
23
|
|
19
24
|
$pagination-current-color: $link-invert !default
|
20
25
|
$pagination-current-background-color: $link !default
|
@@ -22,9 +27,10 @@ $pagination-current-border-color: $link !default
|
|
22
27
|
|
23
28
|
$pagination-ellipsis-color: $grey-light !default
|
24
29
|
|
25
|
-
$pagination-shadow-inset: inset 0 1px 2px rgba($
|
30
|
+
$pagination-shadow-inset: inset 0 1px 2px rgba($scheme-invert, 0.2)
|
26
31
|
|
27
32
|
.pagination
|
33
|
+
@extend %block
|
28
34
|
font-size: $size-normal
|
29
35
|
margin: $pagination-margin
|
30
36
|
// Sizes
|
@@ -56,11 +62,11 @@ $pagination-shadow-inset: inset 0 1px 2px rgba($black, 0.2)
|
|
56
62
|
.pagination-ellipsis
|
57
63
|
@extend %control
|
58
64
|
@extend %unselectable
|
59
|
-
font-size:
|
60
|
-
padding-left: 0.5em
|
61
|
-
padding-right: 0.5em
|
65
|
+
font-size: $pagination-item-font-size
|
62
66
|
justify-content: center
|
63
|
-
margin:
|
67
|
+
margin: $pagination-item-margin
|
68
|
+
padding-left: $pagination-item-padding-left
|
69
|
+
padding-right: $pagination-item-padding-right
|
64
70
|
text-align: center
|
65
71
|
|
66
72
|
.pagination-previous,
|
@@ -1,13 +1,17 @@
|
|
1
|
-
$panel-
|
1
|
+
$panel-margin: $block-spacing !default
|
2
|
+
$panel-item-border: 1px solid $border-light !default
|
3
|
+
$panel-radius: $radius-large !default
|
4
|
+
$panel-shadow: 0 0.5em 1em -0.125em rgba($scheme-invert, 0.1), 0 0px 0 1px rgba($scheme-invert, 0.02) !default
|
2
5
|
|
3
|
-
$panel-heading-background-color: $
|
6
|
+
$panel-heading-background-color: $border-light !default
|
4
7
|
$panel-heading-color: $text-strong !default
|
5
8
|
$panel-heading-line-height: 1.25 !default
|
6
|
-
$panel-heading-padding: 0.
|
9
|
+
$panel-heading-padding: 0.75em 1em !default
|
7
10
|
$panel-heading-radius: $radius !default
|
8
11
|
$panel-heading-size: 1.25em !default
|
9
|
-
$panel-heading-weight: $weight-
|
12
|
+
$panel-heading-weight: $weight-bold !default
|
10
13
|
|
14
|
+
$panel-tabs-font-size: 0.875em !default
|
11
15
|
$panel-tab-border-bottom: 1px solid $border !default
|
12
16
|
$panel-tab-active-border-bottom-color: $link-active-border !default
|
13
17
|
$panel-tab-active-color: $link-active !default
|
@@ -22,24 +26,35 @@ $panel-block-active-color: $link-active !default
|
|
22
26
|
$panel-block-active-icon-color: $link !default
|
23
27
|
|
24
28
|
$panel-icon-color: $text-light !default
|
29
|
+
$panel-colors: $colors !default
|
25
30
|
|
26
31
|
.panel
|
32
|
+
border-radius: $panel-radius
|
33
|
+
box-shadow: $panel-shadow
|
27
34
|
font-size: $size-normal
|
28
35
|
&:not(:last-child)
|
29
|
-
margin-bottom:
|
36
|
+
margin-bottom: $panel-margin
|
37
|
+
// Colors
|
38
|
+
@each $name, $components in $panel-colors
|
39
|
+
$color: nth($components, 1)
|
40
|
+
$color-invert: nth($components, 2)
|
41
|
+
&.is-#{$name}
|
42
|
+
.panel-heading
|
43
|
+
background-color: $color
|
44
|
+
color: $color-invert
|
45
|
+
.panel-tabs a.is-active
|
46
|
+
border-bottom-color: $color
|
47
|
+
.panel-block.is-active .panel-icon
|
48
|
+
color: $color
|
30
49
|
|
31
|
-
.panel-heading,
|
32
50
|
.panel-tabs,
|
33
51
|
.panel-block
|
34
|
-
|
35
|
-
|
36
|
-
border-right: $panel-item-border
|
37
|
-
&:first-child
|
38
|
-
border-top: $panel-item-border
|
52
|
+
&:not(:last-child)
|
53
|
+
border-bottom: $panel-item-border
|
39
54
|
|
40
55
|
.panel-heading
|
41
56
|
background-color: $panel-heading-background-color
|
42
|
-
border-radius: $panel-
|
57
|
+
border-radius: $panel-radius $panel-radius 0 0
|
43
58
|
color: $panel-heading-color
|
44
59
|
font-size: $panel-heading-size
|
45
60
|
font-weight: $panel-heading-weight
|
@@ -49,7 +64,7 @@ $panel-icon-color: $text-light !default
|
|
49
64
|
.panel-tabs
|
50
65
|
align-items: flex-end
|
51
66
|
display: flex
|
52
|
-
font-size:
|
67
|
+
font-size: $panel-tabs-font-size
|
53
68
|
justify-content: center
|
54
69
|
a
|
55
70
|
border-bottom: $panel-tab-border-bottom
|
@@ -73,7 +88,7 @@ $panel-icon-color: $text-light !default
|
|
73
88
|
justify-content: flex-start
|
74
89
|
padding: 0.5em 0.75em
|
75
90
|
input[type="checkbox"]
|
76
|
-
margin
|
91
|
+
+ltr-property("margin", 0.75em)
|
77
92
|
& > .control
|
78
93
|
flex-grow: 1
|
79
94
|
flex-shrink: 1
|
@@ -85,6 +100,9 @@ $panel-icon-color: $text-light !default
|
|
85
100
|
color: $panel-block-active-color
|
86
101
|
.panel-icon
|
87
102
|
color: $panel-block-active-icon-color
|
103
|
+
&:last-child
|
104
|
+
border-bottom-left-radius: $panel-radius
|
105
|
+
border-bottom-right-radius: $panel-radius
|
88
106
|
|
89
107
|
a.panel-block,
|
90
108
|
label.panel-block
|
@@ -95,7 +113,7 @@ label.panel-block
|
|
95
113
|
.panel-icon
|
96
114
|
+fa(14px, 1em)
|
97
115
|
color: $panel-icon-color
|
98
|
-
margin
|
116
|
+
+ltr-property("margin", 0.75em)
|
99
117
|
.fa
|
100
118
|
font-size: inherit
|
101
119
|
line-height: inherit
|
@@ -12,7 +12,7 @@ $tabs-boxed-link-radius: $radius !default
|
|
12
12
|
$tabs-boxed-link-hover-background-color: $background !default
|
13
13
|
$tabs-boxed-link-hover-border-bottom-color: $border !default
|
14
14
|
|
15
|
-
$tabs-boxed-link-active-background-color: $
|
15
|
+
$tabs-boxed-link-active-background-color: $scheme-main !default
|
16
16
|
$tabs-boxed-link-active-border-color: $border !default
|
17
17
|
$tabs-boxed-link-active-border-bottom-color: transparent !default
|
18
18
|
|
@@ -78,9 +78,9 @@ $tabs-toggle-link-active-color: $link-invert !default
|
|
78
78
|
padding-left: 0.75em
|
79
79
|
.icon
|
80
80
|
&:first-child
|
81
|
-
margin
|
81
|
+
+ltr-property("margin", 0.5em)
|
82
82
|
&:last-child
|
83
|
-
margin
|
83
|
+
+ltr-property("margin", 0.5em, false)
|
84
84
|
// Alignment
|
85
85
|
&.is-centered
|
86
86
|
ul
|
@@ -92,7 +92,10 @@ $tabs-toggle-link-active-color: $link-invert !default
|
|
92
92
|
&.is-boxed
|
93
93
|
a
|
94
94
|
border: 1px solid transparent
|
95
|
-
|
95
|
+
+ltr
|
96
|
+
border-radius: $tabs-boxed-link-radius $tabs-boxed-link-radius 0 0
|
97
|
+
+rtl
|
98
|
+
border-radius: 0 0 $tabs-boxed-link-radius $tabs-boxed-link-radius
|
96
99
|
&:hover
|
97
100
|
background-color: $tabs-boxed-link-hover-background-color
|
98
101
|
border-bottom-color: $tabs-boxed-link-hover-border-bottom-color
|
@@ -119,11 +122,21 @@ $tabs-toggle-link-active-color: $link-invert !default
|
|
119
122
|
z-index: 2
|
120
123
|
li
|
121
124
|
& + li
|
122
|
-
margin
|
125
|
+
+ltr-property("margin", -#{$tabs-toggle-link-border-width}, false)
|
123
126
|
&:first-child a
|
124
|
-
|
127
|
+
+ltr
|
128
|
+
border-top-left-radius: $tabs-toggle-link-radius
|
129
|
+
border-bottom-left-radius: $tabs-toggle-link-radius
|
130
|
+
+rtl
|
131
|
+
border-top-right-radius: $tabs-toggle-link-radius
|
132
|
+
border-bottom-right-radius: $tabs-toggle-link-radius
|
125
133
|
&:last-child a
|
126
|
-
|
134
|
+
+ltr
|
135
|
+
border-top-right-radius: $tabs-toggle-link-radius
|
136
|
+
border-bottom-right-radius: $tabs-toggle-link-radius
|
137
|
+
+rtl
|
138
|
+
border-top-left-radius: $tabs-toggle-link-radius
|
139
|
+
border-bottom-left-radius: $tabs-toggle-link-radius
|
127
140
|
&.is-active
|
128
141
|
a
|
129
142
|
background-color: $tabs-toggle-link-active-background-color
|
@@ -135,13 +148,23 @@ $tabs-toggle-link-active-color: $link-invert !default
|
|
135
148
|
&.is-toggle-rounded
|
136
149
|
li
|
137
150
|
&:first-child a
|
138
|
-
|
139
|
-
|
140
|
-
|
151
|
+
+ltr
|
152
|
+
border-bottom-left-radius: $radius-rounded
|
153
|
+
border-top-left-radius: $radius-rounded
|
154
|
+
padding-left: 1.25em
|
155
|
+
+rtl
|
156
|
+
border-bottom-right-radius: $radius-rounded
|
157
|
+
border-top-right-radius: $radius-rounded
|
158
|
+
padding-right: 1.25em
|
141
159
|
&:last-child a
|
142
|
-
|
143
|
-
|
144
|
-
|
160
|
+
+ltr
|
161
|
+
border-bottom-right-radius: $radius-rounded
|
162
|
+
border-top-right-radius: $radius-rounded
|
163
|
+
padding-right: 1.25em
|
164
|
+
+rtl
|
165
|
+
border-bottom-left-radius: $radius-rounded
|
166
|
+
border-top-left-radius: $radius-rounded
|
167
|
+
padding-left: 1.25em
|
145
168
|
// Sizes
|
146
169
|
&.is-small
|
147
170
|
font-size: $size-small
|
@@ -1,11 +1,11 @@
|
|
1
1
|
$box-color: $text !default
|
2
|
-
$box-background-color: $
|
2
|
+
$box-background-color: $scheme-main !default
|
3
3
|
$box-radius: $radius-large !default
|
4
|
-
$box-shadow: 0
|
4
|
+
$box-shadow: 0 0.5em 1em -0.125em rgba($scheme-invert, 0.1), 0 0px 0 1px rgba($scheme-invert, 0.02) !default
|
5
5
|
$box-padding: 1.25rem !default
|
6
6
|
|
7
|
-
$box-link-hover-shadow: 0
|
8
|
-
$box-link-active-shadow: inset 0 1px 2px rgba($
|
7
|
+
$box-link-hover-shadow: 0 0.5em 1em -0.125em rgba($scheme-invert, 0.1), 0 0 0 1px $link !default
|
8
|
+
$box-link-active-shadow: inset 0 1px 2px rgba($scheme-invert, 0.2), 0 0 0 1px $link !default
|
9
9
|
|
10
10
|
.box
|
11
11
|
@extend %block
|
@@ -1,11 +1,12 @@
|
|
1
|
-
$button-color: $
|
2
|
-
$button-background-color: $
|
1
|
+
$button-color: $text-strong !default
|
2
|
+
$button-background-color: $scheme-main !default
|
3
|
+
$button-family: false !default
|
3
4
|
|
4
|
-
$button-border-color: $
|
5
|
+
$button-border-color: $border !default
|
5
6
|
$button-border-width: $control-border-width !default
|
6
7
|
|
7
|
-
$button-padding-vertical: calc(0.
|
8
|
-
$button-padding-horizontal:
|
8
|
+
$button-padding-vertical: calc(0.5em - #{$button-border-width}) !default
|
9
|
+
$button-padding-horizontal: 1em !default
|
9
10
|
|
10
11
|
$button-hover-color: $link-hover !default
|
11
12
|
$button-hover-border-color: $link-hover-border !default
|
@@ -13,23 +14,24 @@ $button-hover-border-color: $link-hover-border !default
|
|
13
14
|
$button-focus-color: $link-focus !default
|
14
15
|
$button-focus-border-color: $link-focus-border !default
|
15
16
|
$button-focus-box-shadow-size: 0 0 0 0.125em !default
|
16
|
-
$button-focus-box-shadow-color:
|
17
|
+
$button-focus-box-shadow-color: bulmaRgba($link, 0.25) !default
|
17
18
|
|
18
19
|
$button-active-color: $link-active !default
|
19
20
|
$button-active-border-color: $link-active-border !default
|
20
21
|
|
21
22
|
$button-text-color: $text !default
|
23
|
+
$button-text-decoration: underline !default
|
22
24
|
$button-text-hover-background-color: $background !default
|
23
25
|
$button-text-hover-color: $text-strong !default
|
24
26
|
|
25
|
-
$button-disabled-background-color: $
|
26
|
-
$button-disabled-border-color: $
|
27
|
+
$button-disabled-background-color: $scheme-main !default
|
28
|
+
$button-disabled-border-color: $border !default
|
27
29
|
$button-disabled-shadow: none !default
|
28
30
|
$button-disabled-opacity: 0.5 !default
|
29
31
|
|
30
|
-
$button-static-color: $
|
31
|
-
$button-static-background-color: $
|
32
|
-
$button-static-border-color: $
|
32
|
+
$button-static-color: $text-light !default
|
33
|
+
$button-static-background-color: $scheme-main-ter !default
|
34
|
+
$button-static-border-color: $border !default
|
33
35
|
|
34
36
|
// The button sizes use mixins so they can be used at different breakpoints
|
35
37
|
=button-small
|
@@ -50,6 +52,8 @@ $button-static-border-color: $grey-lighter !default
|
|
50
52
|
border-width: $button-border-width
|
51
53
|
color: $button-color
|
52
54
|
cursor: pointer
|
55
|
+
@if $button-family
|
56
|
+
font-family: $button-family
|
53
57
|
justify-content: center
|
54
58
|
padding-bottom: $button-padding-vertical
|
55
59
|
padding-left: $button-padding-horizontal
|
@@ -67,14 +71,14 @@ $button-static-border-color: $grey-lighter !default
|
|
67
71
|
height: 1.5em
|
68
72
|
width: 1.5em
|
69
73
|
&:first-child:not(:last-child)
|
70
|
-
margin
|
71
|
-
margin-
|
74
|
+
+ltr-property("margin", calc(#{-1 / 2 * $button-padding-horizontal} - #{$button-border-width}), false)
|
75
|
+
+ltr-property("margin", $button-padding-horizontal / 4)
|
72
76
|
&:last-child:not(:first-child)
|
73
|
-
margin-
|
74
|
-
margin
|
77
|
+
+ltr-property("margin", $button-padding-horizontal / 4, false)
|
78
|
+
+ltr-property("margin", calc(#{-1 / 2 * $button-padding-horizontal} - #{$button-border-width}))
|
75
79
|
&:first-child:last-child
|
76
|
-
margin-left: calc(-
|
77
|
-
margin-right: calc(-
|
80
|
+
margin-left: calc(#{-1 / 2 * $button-padding-horizontal} - #{$button-border-width})
|
81
|
+
margin-right: calc(#{-1 / 2 * $button-padding-horizontal} - #{$button-border-width})
|
78
82
|
// States
|
79
83
|
&:hover,
|
80
84
|
&.is-hovered
|
@@ -95,7 +99,7 @@ $button-static-border-color: $grey-lighter !default
|
|
95
99
|
background-color: transparent
|
96
100
|
border-color: transparent
|
97
101
|
color: $button-text-color
|
98
|
-
text-decoration:
|
102
|
+
text-decoration: $button-text-decoration
|
99
103
|
&:hover,
|
100
104
|
&.is-hovered,
|
101
105
|
&:focus,
|
@@ -104,7 +108,7 @@ $button-static-border-color: $grey-lighter !default
|
|
104
108
|
color: $button-text-hover-color
|
105
109
|
&:active,
|
106
110
|
&.is-active
|
107
|
-
background-color:
|
111
|
+
background-color: bulmaDarken($button-text-hover-background-color, 5%)
|
108
112
|
color: $button-text-hover-color
|
109
113
|
&[disabled],
|
110
114
|
fieldset[disabled] &
|
@@ -120,7 +124,7 @@ $button-static-border-color: $grey-lighter !default
|
|
120
124
|
color: $color-invert
|
121
125
|
&:hover,
|
122
126
|
&.is-hovered
|
123
|
-
background-color:
|
127
|
+
background-color: bulmaDarken($color, 2.5%)
|
124
128
|
border-color: transparent
|
125
129
|
color: $color-invert
|
126
130
|
&:focus,
|
@@ -128,10 +132,10 @@ $button-static-border-color: $grey-lighter !default
|
|
128
132
|
border-color: transparent
|
129
133
|
color: $color-invert
|
130
134
|
&:not(:active)
|
131
|
-
box-shadow: $button-focus-box-shadow-size
|
135
|
+
box-shadow: $button-focus-box-shadow-size bulmaRgba($color, 0.25)
|
132
136
|
&:active,
|
133
137
|
&.is-active
|
134
|
-
background-color:
|
138
|
+
background-color: bulmaDarken($color, 5%)
|
135
139
|
border-color: transparent
|
136
140
|
color: $color-invert
|
137
141
|
&[disabled],
|
@@ -142,8 +146,9 @@ $button-static-border-color: $grey-lighter !default
|
|
142
146
|
&.is-inverted
|
143
147
|
background-color: $color-invert
|
144
148
|
color: $color
|
145
|
-
&:hover
|
146
|
-
|
149
|
+
&:hover,
|
150
|
+
&.is-hovered
|
151
|
+
background-color: bulmaDarken($color-invert, 5%)
|
147
152
|
&[disabled],
|
148
153
|
fieldset[disabled] &
|
149
154
|
background-color: $color-invert
|
@@ -158,13 +163,21 @@ $button-static-border-color: $grey-lighter !default
|
|
158
163
|
border-color: $color
|
159
164
|
color: $color
|
160
165
|
&:hover,
|
161
|
-
|
166
|
+
&.is-hovered,
|
167
|
+
&:focus,
|
168
|
+
&.is-focused
|
162
169
|
background-color: $color
|
163
170
|
border-color: $color
|
164
171
|
color: $color-invert
|
165
172
|
&.is-loading
|
166
173
|
&::after
|
167
174
|
border-color: transparent transparent $color $color !important
|
175
|
+
&:hover,
|
176
|
+
&.is-hovered,
|
177
|
+
&:focus,
|
178
|
+
&.is-focused
|
179
|
+
&::after
|
180
|
+
border-color: transparent transparent $color-invert $color-invert !important
|
168
181
|
&[disabled],
|
169
182
|
fieldset[disabled] &
|
170
183
|
background-color: transparent
|
@@ -176,15 +189,41 @@ $button-static-border-color: $grey-lighter !default
|
|
176
189
|
border-color: $color-invert
|
177
190
|
color: $color-invert
|
178
191
|
&:hover,
|
179
|
-
|
192
|
+
&.is-hovered,
|
193
|
+
&:focus,
|
194
|
+
&.is-focused
|
180
195
|
background-color: $color-invert
|
181
196
|
color: $color
|
197
|
+
&.is-loading
|
198
|
+
&:hover,
|
199
|
+
&.is-hovered,
|
200
|
+
&:focus,
|
201
|
+
&.is-focused
|
202
|
+
&::after
|
203
|
+
border-color: transparent transparent $color $color !important
|
182
204
|
&[disabled],
|
183
205
|
fieldset[disabled] &
|
184
206
|
background-color: transparent
|
185
207
|
border-color: $color-invert
|
186
208
|
box-shadow: none
|
187
209
|
color: $color-invert
|
210
|
+
// If light and dark colors are provided
|
211
|
+
@if length($pair) >= 4
|
212
|
+
$color-light: nth($pair, 3)
|
213
|
+
$color-dark: nth($pair, 4)
|
214
|
+
&.is-light
|
215
|
+
background-color: $color-light
|
216
|
+
color: $color-dark
|
217
|
+
&:hover,
|
218
|
+
&.is-hovered
|
219
|
+
background-color: bulmaDarken($color-light, 2.5%)
|
220
|
+
border-color: transparent
|
221
|
+
color: $color-dark
|
222
|
+
&:active,
|
223
|
+
&.is-active
|
224
|
+
background-color: bulmaDarken($color-light, 5%)
|
225
|
+
border-color: transparent
|
226
|
+
color: $color-dark
|
188
227
|
// Sizes
|
189
228
|
&.is-small
|
190
229
|
+button-small
|
@@ -219,8 +258,8 @@ $button-static-border-color: $grey-lighter !default
|
|
219
258
|
pointer-events: none
|
220
259
|
&.is-rounded
|
221
260
|
border-radius: $radius-rounded
|
222
|
-
padding-left:
|
223
|
-
padding-right:
|
261
|
+
padding-left: calc(#{$button-padding-horizontal} + 0.25em)
|
262
|
+
padding-right: calc(#{$button-padding-horizontal} + 0.25em)
|
224
263
|
|
225
264
|
.buttons
|
226
265
|
align-items: center
|
@@ -230,7 +269,7 @@ $button-static-border-color: $grey-lighter !default
|
|
230
269
|
.button
|
231
270
|
margin-bottom: 0.5rem
|
232
271
|
&:not(:last-child):not(.is-fullwidth)
|
233
|
-
margin
|
272
|
+
+ltr-property("margin", 0.5rem)
|
234
273
|
&:last-child
|
235
274
|
margin-bottom: -0.5rem
|
236
275
|
&:not(:last-child)
|
@@ -253,9 +292,9 @@ $button-static-border-color: $grey-lighter !default
|
|
253
292
|
&:not(:last-child)
|
254
293
|
border-bottom-right-radius: 0
|
255
294
|
border-top-right-radius: 0
|
256
|
-
margin
|
295
|
+
+ltr-property("margin", -1px)
|
257
296
|
&:last-child
|
258
|
-
margin
|
297
|
+
+ltr-property("margin", 0)
|
259
298
|
&:hover,
|
260
299
|
&.is-hovered
|
261
300
|
z-index: 2
|
@@ -269,7 +308,16 @@ $button-static-border-color: $grey-lighter !default
|
|
269
308
|
z-index: 4
|
270
309
|
&.is-expanded
|
271
310
|
flex-grow: 1
|
311
|
+
flex-shrink: 1
|
272
312
|
&.is-centered
|
273
313
|
justify-content: center
|
314
|
+
&:not(.has-addons)
|
315
|
+
.button:not(.is-fullwidth)
|
316
|
+
margin-left: 0.25rem
|
317
|
+
margin-right: 0.25rem
|
274
318
|
&.is-right
|
275
319
|
justify-content: flex-end
|
320
|
+
&:not(.has-addons)
|
321
|
+
.button:not(.is-fullwidth)
|
322
|
+
margin-left: 0.25rem
|
323
|
+
margin-right: 0.25rem
|