material-sass 4.0.0.alpha6 → 4.0.0.beta
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/README.md +36 -8
- data/Rakefile +16 -3
- data/app/assets/javascripts/material-sprockets.js +6 -1
- data/app/assets/javascripts/material.js +654 -417
- data/app/assets/javascripts/material.min.js +1 -0
- data/app/assets/javascripts/material/addons/picker.date.js +234 -0
- data/app/assets/javascripts/material/addons/picker.js +172 -0
- data/app/assets/javascripts/material/addons/textarea-autosize.js +20 -2
- data/app/assets/javascripts/material/addons/waves.js +127 -0
- data/app/assets/javascripts/material/components/floating-label.js +92 -0
- data/app/assets/javascripts/material/components/navdrawer.js +353 -0
- data/app/assets/javascripts/material/components/selection-control-focus.js +47 -0
- data/app/assets/javascripts/material/components/tab-switch.js +148 -0
- data/app/assets/javascripts/material/components/util.js +133 -0
- data/app/assets/javascripts/material/initializers/picker.js +171 -0
- data/app/assets/javascripts/material/initializers/textarea-autosize.js +10 -0
- data/app/assets/javascripts/material/initializers/waves.js +13 -0
- data/app/assets/stylesheets/material/_colours.scss +324 -0
- data/app/assets/stylesheets/material/_functions.scss +65 -0
- data/app/assets/stylesheets/material/_mixins.scss +23 -23
- data/app/assets/stylesheets/material/_print.scss +102 -0
- data/app/assets/stylesheets/material/_utilities.scss +21 -17
- data/app/assets/stylesheets/material/_variables.scss +13 -42
- data/app/assets/stylesheets/material/base/_base.scss +420 -5
- data/app/assets/stylesheets/material/base/_grid.scss +34 -33
- data/app/assets/stylesheets/material/base/_typography.scss +165 -174
- data/app/assets/stylesheets/material/bootstrap/_alert.scss +32 -39
- data/app/assets/stylesheets/material/bootstrap/_badge.scss +34 -0
- data/app/assets/stylesheets/material/bootstrap/_breadcrumb.scss +18 -18
- data/app/assets/stylesheets/material/bootstrap/_carousel.scss +127 -142
- data/app/assets/stylesheets/material/bootstrap/_close.scss +18 -19
- data/app/assets/stylesheets/material/bootstrap/_code.scss +10 -7
- data/app/assets/stylesheets/material/bootstrap/_custom-form.scss +50 -56
- data/app/assets/stylesheets/material/bootstrap/_form.scss +159 -129
- data/app/assets/stylesheets/material/bootstrap/_image.scss +19 -16
- data/app/assets/stylesheets/material/bootstrap/_jumbotron.scss +10 -7
- data/app/assets/stylesheets/material/bootstrap/_nav.scss +71 -69
- data/app/assets/stylesheets/material/bootstrap/_pagination.scss +34 -26
- data/app/assets/stylesheets/material/bootstrap/_popover.scss +26 -59
- data/app/assets/stylesheets/material/bootstrap/_responsive-embed.scss +4 -4
- data/app/assets/stylesheets/material/bootstrap/_transition.scss +10 -8
- data/app/assets/stylesheets/material/material.scss +75 -62
- data/app/assets/stylesheets/material/material/_button-flat.scss +26 -39
- data/app/assets/stylesheets/material/material/_button-float.scss +10 -14
- data/app/assets/stylesheets/material/material/_button-group.scss +268 -0
- data/app/assets/stylesheets/material/material/_button.scss +133 -189
- data/app/assets/stylesheets/material/material/_card.scss +300 -248
- data/app/assets/stylesheets/material/material/_chip.scss +65 -64
- data/app/assets/stylesheets/material/material/_data-table.scss +135 -45
- data/app/assets/stylesheets/material/material/_dialog.scss +141 -110
- data/app/assets/stylesheets/material/material/_expansion-panel.scss +86 -119
- data/app/assets/stylesheets/material/material/_menu.scss +308 -228
- data/app/assets/stylesheets/material/material/_navdrawer.scss +239 -234
- data/app/assets/stylesheets/material/material/_picker.scss +157 -155
- data/app/assets/stylesheets/material/material/_progress-circular.scss +80 -80
- data/app/assets/stylesheets/material/material/_progress.scss +180 -115
- data/app/assets/stylesheets/material/material/_selection-control.scss +132 -139
- data/app/assets/stylesheets/material/material/_stepper.scss +94 -93
- data/app/assets/stylesheets/material/material/_tab.scss +74 -93
- data/app/assets/stylesheets/material/material/_text-field-floating-label.scss +29 -20
- data/app/assets/stylesheets/material/material/_text-field-input-group.scss +94 -24
- data/app/assets/stylesheets/material/material/_text-field-textarea.scss +13 -26
- data/app/assets/stylesheets/material/material/_text-field.scss +127 -118
- data/app/assets/stylesheets/material/material/_toolbar.scss +308 -313
- data/app/assets/stylesheets/material/material/_tooltip.scss +23 -62
- data/app/assets/stylesheets/material/mixins/_background-variant.scss +6 -6
- data/app/assets/stylesheets/material/mixins/_border-radius.scss +17 -17
- data/app/assets/stylesheets/material/mixins/_breakpoint.scss +32 -2
- data/app/assets/stylesheets/material/mixins/_clearfix.scss +1 -1
- data/app/assets/stylesheets/material/mixins/_form.scss +62 -25
- data/app/assets/stylesheets/material/mixins/_grid-framework.scss +8 -16
- data/app/assets/stylesheets/material/mixins/_grid.scss +40 -64
- data/app/assets/stylesheets/material/mixins/_material-icons.scss +36 -0
- data/app/assets/stylesheets/material/mixins/_nav-divider.scss +1 -1
- data/app/assets/stylesheets/material/mixins/_reset-text.scss +2 -21
- data/app/assets/stylesheets/material/mixins/_screenreader.scss +14 -12
- data/app/assets/stylesheets/material/mixins/_text-alignment.scss +23 -0
- data/app/assets/stylesheets/material/mixins/_text-emphasis.scss +6 -6
- data/app/assets/stylesheets/material/mixins/_transition.scss +42 -10
- data/app/assets/stylesheets/material/utilities/_background.scss +18 -18
- data/app/assets/stylesheets/material/utilities/_border.scss +88 -41
- data/app/assets/stylesheets/material/utilities/_display.scss +63 -30
- data/app/assets/stylesheets/material/utilities/_flex.scss +139 -134
- data/app/assets/stylesheets/material/utilities/_material-icons.scss +3 -5
- data/app/assets/stylesheets/material/utilities/_position.scss +19 -22
- data/app/assets/stylesheets/material/utilities/_sizing.scss +11 -12
- data/app/assets/stylesheets/material/utilities/_spacing.scss +51 -56
- data/app/assets/stylesheets/material/utilities/_text.scss +80 -75
- data/app/assets/stylesheets/material/utilities/_visibility.scss +5 -46
- data/app/assets/stylesheets/material/utilities/_waves.scss +11 -18
- data/app/assets/stylesheets/material/variables/_elevation-shadow.scss +89 -82
- data/app/assets/stylesheets/material/variables/_grid.scss +29 -26
- data/app/assets/stylesheets/material/variables/_palette.scss +45 -0
- data/app/assets/stylesheets/material/variables/_spacer.scss +34 -88
- data/app/assets/stylesheets/material/variables/_transition.scss +29 -0
- data/app/assets/stylesheets/material/variables/_typography.scss +88 -74
- data/app/assets/stylesheets/material/variables/_variable-bootstrap.scss +196 -133
- data/app/assets/stylesheets/material/variables/_variable-material.scss +481 -429
- data/lib/material-sass/version.rb +1 -1
- data/material-sass.gemspec +3 -3
- metadata +26 -21
- data/app/assets/javascripts/material/addons-materialise/pickadate.js +0 -139
- data/app/assets/javascripts/material/addons-materialise/textarea-autosize.js +0 -11
- data/app/assets/javascripts/material/addons-materialise/wave.js +0 -15
- data/app/assets/javascripts/material/addons/pickadate.js +0 -7
- data/app/assets/javascripts/material/addons/wave.js +0 -5
- data/app/assets/javascripts/material/src/floating-label.js +0 -91
- data/app/assets/javascripts/material/src/navdrawer.js +0 -352
- data/app/assets/javascripts/material/src/tab-switch.js +0 -133
- data/app/assets/javascripts/material/src/util.js +0 -138
- data/app/assets/stylesheets/material/base/_normalize.scss +0 -253
- data/app/assets/stylesheets/material/base/_reboot.scss +0 -239
- data/app/assets/stylesheets/material/bootstrap/_button-group.scss +0 -134
- data/app/assets/stylesheets/material/mixins/_tab-focus.scss +0 -5
- data/app/assets/stylesheets/material/mixins/_transform.scss +0 -9
- data/app/assets/stylesheets/material/variables/_animation.scss +0 -22
- data/app/assets/stylesheets/material/variables/_colour.scss +0 -389
@@ -1,22 +1,26 @@
|
|
1
1
|
.input-group {
|
2
|
+
align-items: center;
|
2
3
|
display: flex;
|
3
4
|
position: relative;
|
4
5
|
width: 100%;
|
5
6
|
|
6
7
|
.form-control {
|
7
|
-
align-self: center;
|
8
8
|
flex: 1 1 auto;
|
9
9
|
width: 1%;
|
10
10
|
}
|
11
11
|
}
|
12
12
|
|
13
|
+
|
14
|
+
|
15
|
+
// Addon and button
|
16
|
+
|
13
17
|
.input-group-addon {
|
14
18
|
align-items: center;
|
15
19
|
color: inherit;
|
16
20
|
display: flex;
|
17
|
-
font-size:
|
21
|
+
font-size: $textfield-font-size;
|
18
22
|
justify-content: center;
|
19
|
-
line-height:
|
23
|
+
line-height: $textfield-line-height;
|
20
24
|
min-width: $textfield-height;
|
21
25
|
white-space: nowrap;
|
22
26
|
|
@@ -27,6 +31,11 @@
|
|
27
31
|
}
|
28
32
|
|
29
33
|
.input-group-btn {
|
34
|
+
@include border-radius($btn-border-radius);
|
35
|
+
|
36
|
+
align-items: center;
|
37
|
+
background-color: $btn-group-bg;
|
38
|
+
box-shadow: map-get($btn-elevation-shadow, shadow);
|
30
39
|
display: flex;
|
31
40
|
justify-content: center;
|
32
41
|
margin-right: $input-group-addon-margin-x;
|
@@ -40,39 +49,100 @@
|
|
40
49
|
margin-right: 0;
|
41
50
|
}
|
42
51
|
|
43
|
-
.btn {
|
52
|
+
> .btn {
|
53
|
+
border-left: $btn-group-inner-spacer-x solid transparent;
|
54
|
+
box-shadow: none;
|
55
|
+
flex: 0 1 auto;
|
56
|
+
margin-left: ($btn-group-inner-spacer-x * -1);
|
44
57
|
min-width: 0;
|
45
|
-
|
58
|
+
|
59
|
+
&:active,
|
60
|
+
&.active {
|
61
|
+
box-shadow: none;
|
62
|
+
}
|
63
|
+
|
64
|
+
&:disabled,
|
65
|
+
&.disabled {
|
66
|
+
+ .btn:disabled,
|
67
|
+
+ .btn.disabled {
|
68
|
+
border-left-color: $btn-group-divider-bg;
|
69
|
+
}
|
70
|
+
}
|
46
71
|
|
47
72
|
&:first-child {
|
48
|
-
|
73
|
+
border-left-width: 0;
|
74
|
+
margin-left: 0;
|
49
75
|
}
|
50
76
|
|
51
|
-
|
52
|
-
|
77
|
+
&.active {
|
78
|
+
+ .btn.active {
|
79
|
+
border-left-color: $btn-group-divider-bg;
|
80
|
+
}
|
53
81
|
}
|
54
82
|
}
|
55
|
-
}
|
56
83
|
|
57
|
-
//
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
}
|
84
|
+
// Colour
|
85
|
+
@each $color, $values in $theme-colors {
|
86
|
+
> .btn-#{$color} {
|
87
|
+
&:disabled,
|
88
|
+
&.disabled {
|
89
|
+
@include color-yiq(map-get(theme-color($color), lighter));
|
64
90
|
|
65
|
-
|
66
|
-
|
67
|
-
font-size: ($material-icon-size / $font-size-root * 1rem / $textfield-font-size * $textfield-font-size-sm);
|
68
|
-
min-width: $textfield-height-sm;
|
91
|
+
background-color: map-get(theme-color($color), lighter);
|
92
|
+
}
|
69
93
|
}
|
70
94
|
}
|
71
95
|
|
72
|
-
.
|
73
|
-
@
|
96
|
+
> .btn:first-child:not(:last-child):not(.dropdown-toggle) {
|
97
|
+
@include border-right-radius(0);
|
98
|
+
}
|
99
|
+
|
100
|
+
> .btn:last-child:not(:first-child),
|
101
|
+
> .dropdown-toggle:not(:first-child) {
|
102
|
+
@include border-left-radius(0);
|
103
|
+
}
|
104
|
+
|
105
|
+
> .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {
|
106
|
+
border-radius: 0;
|
107
|
+
}
|
108
|
+
|
109
|
+
> .dropdown-toggle:not(:last-child):not(:nth-last-child(2)) {
|
110
|
+
@include border-right-radius(0);
|
111
|
+
}
|
112
|
+
}
|
113
|
+
|
114
|
+
|
115
|
+
|
116
|
+
// Size
|
117
|
+
|
118
|
+
.input-group-lg {
|
119
|
+
> .form-control {
|
120
|
+
@extend %form-control-lg;
|
121
|
+
}
|
122
|
+
|
123
|
+
> .input-group-addon {
|
124
|
+
font-size: $textfield-font-size-lg;
|
125
|
+
line-height: $textfield-line-height-lg;
|
126
|
+
min-width: $textfield-height-lg;
|
74
127
|
}
|
75
128
|
|
76
|
-
.input-group-
|
77
|
-
@extend
|
129
|
+
> .input-group-btn > .btn {
|
130
|
+
@extend %btn-lg;
|
78
131
|
}
|
132
|
+
}
|
133
|
+
|
134
|
+
.input-group-sm {
|
135
|
+
> .form-control {
|
136
|
+
@extend %form-control-sm;
|
137
|
+
}
|
138
|
+
|
139
|
+
> .input-group-addon {
|
140
|
+
font-size: $textfield-font-size-sm;
|
141
|
+
line-height: $textfield-line-height-sm;
|
142
|
+
min-width: $textfield-height-sm;
|
143
|
+
}
|
144
|
+
|
145
|
+
> .input-group-btn > .btn {
|
146
|
+
@extend %btn-sm;
|
147
|
+
}
|
148
|
+
}
|
@@ -1,31 +1,18 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
1
|
+
textarea {
|
2
|
+
&.textarea-autosize {
|
3
|
+
height: $textfield-height;
|
4
|
+
min-height: $textfield-height;
|
5
|
+
resize: none;
|
5
6
|
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
}
|
11
|
-
|
12
|
-
// size
|
13
|
-
.form-control-lg.textarea-autosize {
|
14
|
-
height: $textfield-height-lg;
|
15
|
-
min-height: $textfield-height-lg;
|
16
|
-
|
17
|
-
.floating-label > & {
|
18
|
-
height: ($floating-label-height-lg - $floating-label-padding-top-lg);
|
19
|
-
min-height: ($floating-label-height-lg - $floating-label-padding-top-lg);
|
7
|
+
// Size
|
8
|
+
&.form-control-lg {
|
9
|
+
height: $textfield-height-lg;
|
10
|
+
min-height: $textfield-height-lg;
|
20
11
|
}
|
21
|
-
}
|
22
|
-
|
23
|
-
.form-control-sm.textarea-autosize {
|
24
|
-
height: $textfield-height-sm;
|
25
|
-
min-height: $textfield-height-sm;
|
26
12
|
|
27
|
-
|
28
|
-
height:
|
29
|
-
min-height:
|
13
|
+
&.form-control-sm {
|
14
|
+
height: $textfield-height-sm;
|
15
|
+
min-height: $textfield-height-sm;
|
30
16
|
}
|
31
17
|
}
|
18
|
+
}
|
@@ -1,16 +1,24 @@
|
|
1
|
-
.form-control
|
1
|
+
.form-control,
|
2
|
+
%form-control {
|
3
|
+
@include form-control-size($textfield-font-size, $textfield-height, $textfield-line-height, $textfield-padding-x, $textfield-padding-y);
|
4
|
+
@include transition-standard(border-color, box-shadow);
|
5
|
+
|
2
6
|
background-clip: padding-box;
|
3
7
|
background-color: transparent;
|
4
8
|
background-image: none;
|
5
|
-
border:
|
6
|
-
border-bottom: $textfield-border-width solid $textfield-border-color;
|
9
|
+
border-color: $textfield-border-color;
|
7
10
|
border-radius: 0;
|
11
|
+
border-style: solid;
|
12
|
+
border-width: 0 0 $textfield-border-width;
|
8
13
|
box-shadow: none;
|
9
|
-
color:
|
14
|
+
color: $textfield-color;
|
10
15
|
display: block;
|
11
16
|
width: 100%;
|
12
|
-
|
13
|
-
@include
|
17
|
+
|
18
|
+
@include hover {
|
19
|
+
border-color: $textfield-border-color-hover;
|
20
|
+
box-shadow: inset 0 ($textfield-border-width-hover * -1) 0 ($textfield-border-width * -1) $textfield-border-color-hover;
|
21
|
+
}
|
14
22
|
|
15
23
|
&::-ms-expand {
|
16
24
|
background-color: transparent;
|
@@ -22,76 +30,74 @@
|
|
22
30
|
opacity: 1;
|
23
31
|
}
|
24
32
|
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
}
|
33
|
+
&:disabled,
|
34
|
+
&[readonly] {
|
35
|
+
border-style: dotted;
|
36
|
+
color: $textfield-color-disabled;
|
37
|
+
opacity: 1;
|
31
38
|
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
border-bottom-style: dotted;
|
36
|
-
color: $textfield-color-disabled;
|
37
|
-
opacity: 1;
|
39
|
+
@include hover {
|
40
|
+
border-color: $textfield-border-color;
|
41
|
+
box-shadow: none;
|
38
42
|
}
|
39
43
|
|
40
|
-
&:
|
41
|
-
|
44
|
+
&:focus {
|
45
|
+
border-color: $textfield-border-color;
|
46
|
+
box-shadow: none;
|
42
47
|
}
|
43
|
-
}
|
48
|
+
}
|
44
49
|
|
45
|
-
|
46
|
-
|
47
|
-
|
50
|
+
&:focus {
|
51
|
+
border-color: $textfield-border-color-focus;
|
52
|
+
box-shadow: inset 0 ($textfield-border-width-focus * -1) 0 ($textfield-border-width * -1) $textfield-border-color-focus;
|
53
|
+
outline: 0;
|
54
|
+
}
|
48
55
|
|
49
|
-
|
50
|
-
|
56
|
+
&:invalid:required {
|
57
|
+
outline: 0;
|
58
|
+
}
|
59
|
+
}
|
51
60
|
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
padding-right: $select-bg-size;
|
61
|
+
// Colour
|
62
|
+
@each $color, $values in $theme-colors {
|
63
|
+
.form-control-#{$color} {
|
64
|
+
border-color: map-get(theme-color($color), color);
|
57
65
|
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
height: auto;
|
62
|
-
padding-right: 0;
|
66
|
+
@include focus-hover {
|
67
|
+
border-color: map-get(theme-color($color), color);
|
68
|
+
box-shadow: inset 0 ($textfield-border-width-focus * -1) 0 ($textfield-border-width * -1) map-get(theme-color($color), color);
|
63
69
|
}
|
64
70
|
}
|
65
71
|
}
|
66
72
|
|
67
|
-
|
68
|
-
|
73
|
+
// Size
|
74
|
+
.form-control-lg,
|
75
|
+
%form-control-lg {
|
76
|
+
@include form-control-size($textfield-font-size-lg, $textfield-height-lg, $textfield-line-height-lg, $textfield-padding-x-lg, $textfield-padding-y-lg);
|
69
77
|
}
|
70
78
|
|
71
|
-
|
72
|
-
|
73
|
-
|
79
|
+
.form-control-sm,
|
80
|
+
%form-control-sm {
|
81
|
+
@include form-control-size($textfield-font-size-sm, $textfield-height-sm, $textfield-line-height-sm, $textfield-padding-x-sm, $textfield-padding-y-sm);
|
82
|
+
}
|
74
83
|
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
border-bottom-color: nth($palettes-color, $i);
|
79
|
-
}
|
84
|
+
// Special treatment for select and textarea
|
85
|
+
%form-control-select {
|
86
|
+
appearance: none;
|
80
87
|
|
81
|
-
|
82
|
-
|
83
|
-
}
|
84
|
-
}
|
85
|
-
}
|
88
|
+
@include media-moz-webkit {
|
89
|
+
$select-bg-size: (($material-icon-size / $textfield-font-size) * $textfield-font-size);
|
86
90
|
|
87
|
-
|
88
|
-
|
89
|
-
|
91
|
+
background-image: $caret-bg;
|
92
|
+
background-position: 100% ($textfield-height / 2 - $select-bg-size / 2);
|
93
|
+
background-repeat: no-repeat;
|
94
|
+
background-size: $select-bg-size $select-bg-size;
|
95
|
+
padding-right: $select-bg-size;
|
90
96
|
}
|
91
97
|
|
92
|
-
|
93
|
-
@media
|
94
|
-
$select-bg-size-lg: (($material-icon-size / $
|
98
|
+
&.form-control-lg {
|
99
|
+
@include media-moz-webkit {
|
100
|
+
$select-bg-size-lg: (($material-icon-size / $textfield-font-size) * $textfield-font-size-lg);
|
95
101
|
|
96
102
|
background-position: 100% ($textfield-height-lg / 2 - $select-bg-size-lg / 2);
|
97
103
|
background-size: $select-bg-size-lg $select-bg-size-lg;
|
@@ -99,90 +105,93 @@ textarea.form-control {
|
|
99
105
|
}
|
100
106
|
}
|
101
107
|
|
102
|
-
|
103
|
-
@include
|
104
|
-
|
105
|
-
|
106
|
-
select.form-control-sm {
|
107
|
-
@media screen and (-webkit-min-device-pixel-ratio: 0), (min--moz-device-pixel-ratio: 0) {
|
108
|
-
$select-bg-size-sm: (($material-icon-size / $font-size-root * 1rem / $textfield-font-size) * $textfield-font-size-sm);
|
108
|
+
&.form-control-sm {
|
109
|
+
@include media-moz-webkit {
|
110
|
+
$select-bg-size-sm: (($material-icon-size / $textfield-font-size) * $textfield-font-size-sm);
|
109
111
|
|
110
112
|
background-position: 100% ($textfield-height-sm / 2 - $select-bg-size-sm / 2);
|
111
113
|
background-size: $select-bg-size-sm $select-bg-size-sm;
|
112
114
|
padding-right: $select-bg-size-sm;
|
113
115
|
}
|
114
116
|
}
|
117
|
+
}
|
115
118
|
|
116
|
-
|
117
|
-
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
input[type="week"] {
|
122
|
-
&.form-control {
|
123
|
-
height: $textfield-height;
|
124
|
-
}
|
119
|
+
%textfield-box {
|
120
|
+
border-radius: $textfield-box-border-radius;
|
121
|
+
border-width: $textfield-border-width;
|
122
|
+
height: auto;
|
123
|
+
padding: $textfield-box-padding-y $textfield-box-padding-x;
|
125
124
|
|
126
|
-
|
127
|
-
|
128
|
-
|
125
|
+
@include hover {
|
126
|
+
box-shadow: inset $textfield-border-width-hover $textfield-border-width-hover 0 ($textfield-border-width * -1) $textfield-border-color-hover, inset ($textfield-border-width-hover * -1) ($textfield-border-width-hover * -1) 0 ($textfield-border-width * -1) $textfield-border-color-hover;
|
127
|
+
}
|
129
128
|
|
130
|
-
|
131
|
-
|
132
|
-
}
|
129
|
+
&:focus {
|
130
|
+
box-shadow: inset $textfield-border-width-focus $textfield-border-width-focus 0 ($textfield-border-width * -1) $textfield-border-color-focus, inset ($textfield-border-width-focus * -1) ($textfield-border-width-focus * -1) 0 ($textfield-border-width * -1) $textfield-border-color-focus;
|
133
131
|
}
|
134
132
|
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
}
|
133
|
+
&.form-control-lg {
|
134
|
+
padding: $textfield-box-padding-y-lg $textfield-box-padding-x-lg;
|
135
|
+
}
|
139
136
|
|
140
|
-
|
141
|
-
|
137
|
+
&.form-control-sm {
|
138
|
+
padding: $textfield-box-padding-y-sm $textfield-box-padding-x-sm;
|
139
|
+
}
|
140
|
+
}
|
141
|
+
|
142
|
+
select {
|
143
|
+
&.form-control {
|
144
|
+
&:not([multiple]):not([size]) {
|
145
|
+
@extend %form-control-select;
|
142
146
|
}
|
143
147
|
|
144
|
-
|
145
|
-
|
148
|
+
&[multiple],
|
149
|
+
&[size] {
|
150
|
+
@extend %textfield-box;
|
146
151
|
}
|
147
152
|
}
|
153
|
+
}
|
148
154
|
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
.has-danger {
|
153
|
-
@include form-control-validation($palette-red-500);
|
155
|
+
textarea {
|
156
|
+
&.form-control:not(.textarea-autosize) {
|
157
|
+
@extend %textfield-box;
|
154
158
|
}
|
159
|
+
}
|
155
160
|
|
156
|
-
.has-success {
|
157
|
-
@include form-control-validation($palette-green-500);
|
158
|
-
}
|
159
161
|
|
160
|
-
.has-warning {
|
161
|
-
@include form-control-validation($palette-orange-500);
|
162
|
-
}
|
163
162
|
|
164
|
-
//
|
165
|
-
// form control static
|
166
|
-
//
|
167
|
-
.form-control-static {
|
168
|
-
margin-bottom: 0;
|
169
|
-
@include form-control-size(0px, $textfield-font-size, $textfield-height, $textfield-padding-top, $textfield-padding-bottom);
|
163
|
+
// Form control static
|
170
164
|
|
171
|
-
|
172
|
-
|
173
|
-
}
|
165
|
+
.form-control-plaintext {
|
166
|
+
@include form-control-size($textfield-font-size, $textfield-height, $textfield-line-height, $textfield-padding-x, $textfield-padding-y);
|
174
167
|
|
175
|
-
|
176
|
-
|
177
|
-
|
168
|
+
border-color: transparent;
|
169
|
+
|
170
|
+
&.form-control-lg {
|
171
|
+
@include form-control-size($textfield-font-size-lg, $textfield-height-lg, $textfield-line-height-lg, $textfield-padding-x-lg, $textfield-padding-y-lg);
|
178
172
|
}
|
179
173
|
|
180
|
-
|
181
|
-
|
182
|
-
//
|
183
|
-
.custom-select {
|
184
|
-
@extend .form-control;
|
185
|
-
display: inline-block;
|
186
|
-
vertical-align: middle;
|
187
|
-
width: auto;
|
174
|
+
&.form-control-sm {
|
175
|
+
@include form-control-size($textfield-font-size-sm, $textfield-height-sm, $textfield-line-height-sm, $textfield-padding-x-sm, $textfield-padding-y-sm);
|
188
176
|
}
|
177
|
+
}
|
178
|
+
|
179
|
+
|
180
|
+
|
181
|
+
// Form validation
|
182
|
+
|
183
|
+
@include form-control-validation($form-feedback-invalid-color, 'invalid');
|
184
|
+
@include form-control-validation($form-feedback-valid-color, 'valid');
|
185
|
+
|
186
|
+
|
187
|
+
|
188
|
+
// Style of Material design `select` should also be applied to `.custom-select`
|
189
|
+
|
190
|
+
.custom-select {
|
191
|
+
@extend %form-control;
|
192
|
+
@extend %form-control-select;
|
193
|
+
|
194
|
+
display: inline-block;
|
195
|
+
vertical-align: middle;
|
196
|
+
width: auto;
|
197
|
+
}
|