material-sass 4.0.0.beta3 → 4.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Rakefile +11 -10
- data/assets/javascripts/material-sprockets.js +1 -5
- data/assets/javascripts/material.js +155 -109
- data/assets/javascripts/material.min.js +4 -5
- data/assets/javascripts/material/addons/pickadate.js +0 -1
- data/assets/javascripts/material/components/expansion-panel.js +4 -5
- data/assets/javascripts/material/components/floating-label.js +10 -10
- data/assets/javascripts/material/components/nav-drawer.js +94 -68
- data/assets/javascripts/material/components/selection-control-focus.js +4 -5
- data/assets/javascripts/material/components/tab-switch.js +22 -11
- data/assets/javascripts/material/components/util.js +4 -14
- data/assets/stylesheets/material/{_colours.scss → _colors.scss} +414 -6
- data/assets/stylesheets/material/_functions.scss +17 -5
- data/assets/stylesheets/material/base/_base.scss +24 -0
- data/assets/stylesheets/material/bootstrap/_alert.scss +2 -2
- data/assets/stylesheets/material/bootstrap/_badge.scss +4 -4
- data/assets/stylesheets/material/bootstrap/_carousel.scss +36 -0
- data/assets/stylesheets/material/bootstrap/_close.scss +1 -1
- data/assets/stylesheets/material/bootstrap/_form.scss +26 -25
- data/assets/stylesheets/material/bootstrap/_pagination.scss +1 -1
- data/assets/stylesheets/material/material.scss +1 -1
- data/assets/stylesheets/material/material/_button-flat.scss +1 -1
- data/assets/stylesheets/material/material/_button-float.scss +22 -0
- data/assets/stylesheets/material/material/_button-group.scss +2 -2
- data/assets/stylesheets/material/material/_button.scss +6 -6
- data/assets/stylesheets/material/material/_card.scss +4 -4
- data/assets/stylesheets/material/material/_chip.scss +2 -2
- data/assets/stylesheets/material/material/_data-table.scss +62 -35
- data/assets/stylesheets/material/material/_dialog.scss +1 -1
- data/assets/stylesheets/material/material/_expansion-panel.scss +6 -6
- data/assets/stylesheets/material/material/_menu.scss +14 -0
- data/assets/stylesheets/material/material/_navdrawer.scss +99 -90
- data/assets/stylesheets/material/material/_picker.scss +69 -10
- data/assets/stylesheets/material/material/_progress-circular.scss +3 -3
- data/assets/stylesheets/material/material/_progress.scss +7 -7
- data/assets/stylesheets/material/material/_tab.scss +4 -0
- data/assets/stylesheets/material/material/_text-field-box.scss +19 -19
- data/assets/stylesheets/material/material/_text-field-floating-label.scss +8 -8
- data/assets/stylesheets/material/material/_text-field-input-group.scss +3 -3
- data/assets/stylesheets/material/material/_text-field.scss +3 -3
- data/assets/stylesheets/material/material/_toolbar.scss +48 -65
- data/assets/stylesheets/material/mixins/_breakpoint.scss +40 -22
- data/assets/stylesheets/material/mixins/_grid-framework.scss +6 -2
- data/assets/stylesheets/material/mixins/_grid.scss +10 -19
- data/assets/stylesheets/material/utilities/_background.scss +1 -1
- data/assets/stylesheets/material/utilities/_border.scss +1 -2
- data/assets/stylesheets/material/utilities/_display.scss +24 -16
- data/assets/stylesheets/material/utilities/_flex.scss +4 -0
- data/assets/stylesheets/material/utilities/_text.scss +1 -1
- data/assets/stylesheets/material/variables/_elevation-shadow.scss +0 -6
- data/assets/stylesheets/material/variables/_grid.scss +10 -19
- data/assets/stylesheets/material/variables/_palette.scss +26 -25
- data/assets/stylesheets/material/variables/_spacer.scss +24 -21
- data/assets/stylesheets/material/variables/_typography.scss +0 -1
- data/assets/stylesheets/material/variables/_variable-bootstrap.scss +7 -9
- data/assets/stylesheets/material/variables/_variable-material.scss +34 -29
- data/lib/material-sass/version.rb +1 -1
- metadata +5 -5
@@ -44,6 +44,10 @@
|
|
44
44
|
.order#{$infix}-first {
|
45
45
|
order: -1;
|
46
46
|
}
|
47
|
+
|
48
|
+
.order#{$infix}-last {
|
49
|
+
order: $grid-columns + 1;
|
50
|
+
}
|
47
51
|
}
|
48
52
|
|
49
53
|
.col#{$infix},
|
@@ -53,9 +57,9 @@
|
|
53
57
|
}
|
54
58
|
|
55
59
|
%grid-column {
|
56
|
-
@include make-gutters;
|
57
|
-
|
58
60
|
min-height: 1px;
|
61
|
+
padding-right: ($grid-gutter-width / 2);
|
62
|
+
padding-left: ($grid-gutter-width / 2);
|
59
63
|
position: relative;
|
60
64
|
width: 100%;
|
61
65
|
}
|
@@ -1,5 +1,4 @@
|
|
1
1
|
// Make column
|
2
|
-
|
3
2
|
@mixin make-col($size) {
|
4
3
|
flex: 0 0 percentage($size / $grid-columns);
|
5
4
|
max-width: percentage($size / $grid-columns);
|
@@ -11,29 +10,21 @@
|
|
11
10
|
margin-left: if($num == 0, 0, percentage($num));
|
12
11
|
}
|
13
12
|
|
14
|
-
@mixin make-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
margin-right: ($gutter / -2);
|
21
|
-
margin-left: ($gutter / -2);
|
22
|
-
} @else if ($type == padding) {
|
23
|
-
padding-right: ($gutter / 2);
|
24
|
-
padding-left: ($gutter / 2);
|
25
|
-
}
|
26
|
-
}
|
27
|
-
}
|
13
|
+
@mixin make-col-ready() {
|
14
|
+
min-height: 1px;
|
15
|
+
padding-right: ($grid-gutter-width / 2);
|
16
|
+
padding-left: ($grid-gutter-width / 2);
|
17
|
+
position: relative;
|
18
|
+
width: 100%;
|
28
19
|
}
|
29
20
|
|
30
21
|
// Make container
|
31
22
|
|
32
23
|
@mixin make-container() {
|
33
|
-
@include make-gutters;
|
34
|
-
|
35
24
|
margin-right: auto;
|
36
25
|
margin-left: auto;
|
26
|
+
padding-right: ($grid-gutter-width / 2);
|
27
|
+
padding-left: ($grid-gutter-width / 2);
|
37
28
|
width: 100%;
|
38
29
|
}
|
39
30
|
|
@@ -48,8 +39,8 @@
|
|
48
39
|
// Make row
|
49
40
|
|
50
41
|
@mixin make-row() {
|
51
|
-
@include make-gutters(margin);
|
52
|
-
|
53
42
|
display: flex;
|
54
43
|
flex-wrap: wrap;
|
44
|
+
margin-right: ($grid-gutter-width / -2);
|
45
|
+
margin-left: ($grid-gutter-width / -2);
|
55
46
|
}
|
@@ -15,5 +15,5 @@
|
|
15
15
|
// Palette
|
16
16
|
|
17
17
|
@each $color, $values in $theme-colors {
|
18
|
-
@include bg-variant('.bg-#{$color}',
|
18
|
+
@include bg-variant('.bg-#{$color}', theme-color($color), theme-color-dark($color));
|
19
19
|
}
|
@@ -42,7 +42,6 @@
|
|
42
42
|
border-left: 0 !important;
|
43
43
|
}
|
44
44
|
|
45
|
-
// Colour
|
46
45
|
.border-black {
|
47
46
|
border-color: $black !important;
|
48
47
|
}
|
@@ -85,7 +84,7 @@
|
|
85
84
|
|
86
85
|
@each $color, $values in $theme-colors {
|
87
86
|
.border-#{$color} {
|
88
|
-
border-color:
|
87
|
+
border-color: theme-color($color) !important;
|
89
88
|
}
|
90
89
|
}
|
91
90
|
|
@@ -46,32 +46,40 @@
|
|
46
46
|
|
47
47
|
// Utilities for toggling `display` in print
|
48
48
|
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
@media print {
|
49
|
+
@media print {
|
50
|
+
.d-print-block {
|
53
51
|
display: block !important;
|
54
52
|
}
|
55
|
-
}
|
56
53
|
|
57
|
-
.d-print-
|
58
|
-
|
54
|
+
.d-print-flex {
|
55
|
+
display: flex !important;
|
56
|
+
}
|
59
57
|
|
60
|
-
|
58
|
+
.d-print-inline {
|
61
59
|
display: inline !important;
|
62
60
|
}
|
63
|
-
}
|
64
61
|
|
65
|
-
.d-print-inline-block {
|
66
|
-
display: none !important;
|
67
|
-
|
68
|
-
@media print {
|
62
|
+
.d-print-inline-block {
|
69
63
|
display: inline-block !important;
|
70
64
|
}
|
71
|
-
}
|
72
65
|
|
73
|
-
.d-print-
|
74
|
-
|
66
|
+
.d-print-inline-flex {
|
67
|
+
display: inline-flex !important;
|
68
|
+
}
|
69
|
+
|
70
|
+
.d-print-none {
|
75
71
|
display: none !important;
|
76
72
|
}
|
73
|
+
|
74
|
+
.d-print-table {
|
75
|
+
display: table !important;
|
76
|
+
}
|
77
|
+
|
78
|
+
.d-print-table-cell {
|
79
|
+
display: table-cell !important;
|
80
|
+
}
|
81
|
+
|
82
|
+
.d-print-table-row {
|
83
|
+
display: table-row !important;
|
84
|
+
}
|
77
85
|
}
|
@@ -47,7 +47,7 @@
|
|
47
47
|
@include text-emphasis-variant('.text-muted', $text-muted);
|
48
48
|
|
49
49
|
@each $color, $values in $theme-colors {
|
50
|
-
@include text-emphasis-variant('.text-#{$color}',
|
50
|
+
@include text-emphasis-variant('.text-#{$color}', theme-color($color), theme-color-dark($color));
|
51
51
|
}
|
52
52
|
|
53
53
|
// Italcs and weight
|
@@ -7,7 +7,6 @@ $elevation-12dp: 12 * 10 !default;
|
|
7
7
|
$elevation-8dp: 8 * 10 !default;
|
8
8
|
$elevation-6dp: 6 * 10 !default;
|
9
9
|
$elevation-4dp: 4 * 10 !default;
|
10
|
-
$elevation-3dp: 3 * 10 !default;
|
11
10
|
$elevation-2dp: 2 * 10 !default;
|
12
11
|
$elevation-1dp: 1 * 10 !default;
|
13
12
|
|
@@ -24,7 +23,6 @@ $shadow-12dp: 0 12px 17px 2px $shadow-color-1, 0 5px 22px 4px $shadow-color-2
|
|
24
23
|
$shadow-8dp: 0 8px 10px 1px $shadow-color-1, 0 3px 14px 3px $shadow-color-2, 0 4px 15px 0 $shadow-color-3 !default;
|
25
24
|
$shadow-6dp: 0 6px 10px 0 $shadow-color-1, 0 1px 18px 0 $shadow-color-2, 0 3px 5px 0 $shadow-color-3 !default;
|
26
25
|
$shadow-4dp: 0 2px 4px 0 $shadow-color-1, 0 4px 5px 0 $shadow-color-2, 0 1px 10px 0 $shadow-color-3 !default;
|
27
|
-
$shadow-3dp: 0 3px 3px 0 $shadow-color-1, 0 3px 4px 0 $shadow-color-2, 0 1px 8px 0 $shadow-color-3 !default;
|
28
26
|
$shadow-2dp: 0 0 4px 0 $shadow-color-1, 0 3px 4px 0 $shadow-color-2, 0 1px 5px 0 $shadow-color-3 !default;
|
29
27
|
$shadow-1dp: 0 0 2px 0 $shadow-color-1, 0 2px 2px 0 $shadow-color-2, 0 1px 3px 0 $shadow-color-3 !default;
|
30
28
|
|
@@ -55,10 +53,6 @@ $elevation-shadow-4dp: (
|
|
55
53
|
elevation: $elevation-4dp,
|
56
54
|
shadow: $shadow-4dp
|
57
55
|
) !default;
|
58
|
-
$elevation-shadow-3dp: (
|
59
|
-
elevation: $elevation-3dp,
|
60
|
-
shadow: $shadow-3dp
|
61
|
-
) !default;
|
62
56
|
$elevation-shadow-2dp: (
|
63
57
|
elevation: $elevation-2dp,
|
64
58
|
shadow: $shadow-2dp
|
@@ -1,24 +1,15 @@
|
|
1
|
-
$grid-columns:
|
2
|
-
$grid-gutter-width
|
3
|
-
$grid-gutter-width-desktop: 24px !default;
|
4
|
-
|
5
|
-
$grid-gutter-widths: (
|
6
|
-
xs: $grid-gutter-width-base,
|
7
|
-
sm: $grid-gutter-width-base,
|
8
|
-
md: $grid-gutter-width-desktop,
|
9
|
-
lg: $grid-gutter-width-desktop,
|
10
|
-
xl: $grid-gutter-width-desktop
|
11
|
-
) !default;
|
1
|
+
$grid-columns: 12 !default;
|
2
|
+
$grid-gutter-width: 40px !default;
|
12
3
|
|
13
4
|
// Breakpoint
|
14
5
|
// Based on https://material.google.com/layout/responsive-ui.html#responsive-ui-breakpoints
|
15
6
|
|
16
7
|
$grid-breakpoints: (
|
17
8
|
xs: 0,
|
18
|
-
sm:
|
19
|
-
md:
|
20
|
-
lg:
|
21
|
-
xl:
|
9
|
+
sm: 576px,
|
10
|
+
md: 768px,
|
11
|
+
lg: 992px,
|
12
|
+
xl: 1200px
|
22
13
|
) !default;
|
23
14
|
|
24
15
|
@include _assert-ascending($grid-breakpoints, '$grid-breakpoints');
|
@@ -28,10 +19,10 @@ $grid-breakpoints: (
|
|
28
19
|
// Based on https://material.google.com/layout/responsive-ui.html#responsive-ui-breakpoints
|
29
20
|
|
30
21
|
$container-max-widths: (
|
31
|
-
sm:
|
32
|
-
md:
|
33
|
-
lg:
|
34
|
-
xl:
|
22
|
+
sm: 540px,
|
23
|
+
md: 720px,
|
24
|
+
lg: 960px,
|
25
|
+
xl: 1140px
|
35
26
|
) !default;
|
36
27
|
|
37
28
|
@include _assert-ascending($container-max-widths, '$container-max-widths');
|
@@ -2,55 +2,54 @@
|
|
2
2
|
// Change these values to customise colour palettes
|
3
3
|
|
4
4
|
$primary: (
|
5
|
-
color:
|
6
|
-
|
7
|
-
|
5
|
+
color: $material-color-purple-500,
|
6
|
+
dark: $material-color-purple-700,
|
7
|
+
light: $material-color-purple-100
|
8
8
|
) !default;
|
9
9
|
|
10
10
|
$secondary: (
|
11
|
-
color:
|
12
|
-
|
13
|
-
|
11
|
+
color: $material-color-pink-a200,
|
12
|
+
dark: $material-color-pink-a400,
|
13
|
+
light: $material-color-pink-a100
|
14
14
|
) !default;
|
15
15
|
|
16
16
|
$danger: (
|
17
|
-
color:
|
18
|
-
|
19
|
-
|
17
|
+
color: $material-color-red-500,
|
18
|
+
dark: $material-color-red-700,
|
19
|
+
light: $material-color-red-100
|
20
20
|
) !default;
|
21
21
|
|
22
22
|
$info: (
|
23
|
-
color:
|
24
|
-
|
25
|
-
|
23
|
+
color: $material-color-blue-500,
|
24
|
+
dark: $material-color-blue-700,
|
25
|
+
light: $material-color-blue-100
|
26
26
|
) !default;
|
27
27
|
|
28
28
|
$success: (
|
29
|
-
color:
|
30
|
-
|
31
|
-
|
29
|
+
color: $material-color-green-500,
|
30
|
+
dark: $material-color-green-700,
|
31
|
+
light: $material-color-green-100
|
32
32
|
) !default;
|
33
33
|
|
34
34
|
$warning: (
|
35
|
-
color:
|
36
|
-
|
37
|
-
|
35
|
+
color: $material-color-orange-500,
|
36
|
+
dark: $material-color-orange-700,
|
37
|
+
light: $material-color-orange-100
|
38
38
|
) !default;
|
39
39
|
|
40
40
|
$dark: (
|
41
|
-
color:
|
42
|
-
|
43
|
-
|
41
|
+
color: $material-color-grey-800,
|
42
|
+
dark: $material-color-grey-900,
|
43
|
+
light: $material-color-grey-600
|
44
44
|
) !default;
|
45
45
|
|
46
46
|
$light: (
|
47
|
-
color:
|
48
|
-
|
49
|
-
|
47
|
+
color: $material-color-grey-100,
|
48
|
+
dark: $material-color-grey-300,
|
49
|
+
light: $material-color-grey-050
|
50
50
|
) !default;
|
51
51
|
|
52
52
|
$theme-colors: () !default;
|
53
|
-
|
54
53
|
$theme-colors: map-merge(
|
55
54
|
(
|
56
55
|
'primary': $primary,
|
@@ -66,3 +65,5 @@ $theme-colors: map-merge(
|
|
66
65
|
);
|
67
66
|
|
68
67
|
$yiq-contrasted-threshold: 150 !default;
|
68
|
+
$yiq-text-dark: $black-primary !default;
|
69
|
+
$yiq-text-light: $white-primary !default;
|
@@ -1,14 +1,19 @@
|
|
1
1
|
$border-color: $black-divider !default;
|
2
|
-
$border-color-solid:
|
2
|
+
$border-color-solid: #e1e1e1 !default;
|
3
3
|
$border-radius: 2px !default;
|
4
4
|
$border-width: 1px !default;
|
5
5
|
|
6
|
-
$sizes: (
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
6
|
+
$sizes: () !default;
|
7
|
+
$sizes: map-merge(
|
8
|
+
(
|
9
|
+
25: 25%,
|
10
|
+
50: 50%,
|
11
|
+
75: 75%,
|
12
|
+
100: 100%,
|
13
|
+
auto: auto
|
14
|
+
),
|
15
|
+
$sizes
|
16
|
+
);
|
12
17
|
|
13
18
|
$spacer: 1rem !default;
|
14
19
|
|
@@ -17,17 +22,15 @@ $spacer-sm: ($spacer * 0.5) !default;
|
|
17
22
|
$spacer-lg: ($spacer * 1.5) !default;
|
18
23
|
$spacer-xl: ($spacer * 3) !default;
|
19
24
|
|
20
|
-
$spacers: (
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
xl: $spacer-xl
|
33
|
-
) !default;
|
25
|
+
$spacers: () !default;
|
26
|
+
$spacers: map-merge(
|
27
|
+
(
|
28
|
+
0: 0,
|
29
|
+
1: $spacer-xs,
|
30
|
+
2: $spacer-sm,
|
31
|
+
3: $spacer,
|
32
|
+
4: $spacer-lg,
|
33
|
+
5: $spacer-xl
|
34
|
+
),
|
35
|
+
$spacers
|
36
|
+
);
|
@@ -16,7 +16,6 @@ $font-family-serif: 'Roboto Slab', Georgia, 'Times New Roman', Times, serif
|
|
16
16
|
|
17
17
|
$font-family-base: $font-family-sans-serif !default;
|
18
18
|
|
19
|
-
$font-weight-bold: 700 !default;
|
20
19
|
$font-weight-medium: 500 !default;
|
21
20
|
$font-weight-regular: 400 !default;
|
22
21
|
$font-weight-light: 300 !default;
|
@@ -83,14 +83,12 @@ $pre-scrollable-max-height: 340px !default;
|
|
83
83
|
// Form
|
84
84
|
|
85
85
|
$custom-file-button-icon: 'attachment' !default;
|
86
|
-
$custom-file-width: 14rem !default;
|
87
|
-
$custom-file-text: (en: 'Choose file...') !default;
|
88
86
|
|
89
87
|
$form-check-inline-margin-x: $spacer-sm !default;
|
90
|
-
$form-check-input-
|
88
|
+
$form-check-input-gutter: 1.25rem !default;
|
91
89
|
|
92
|
-
$form-feedback-invalid-color:
|
93
|
-
$form-feedback-valid-color:
|
90
|
+
$form-feedback-invalid-color: theme-color(danger) !default;
|
91
|
+
$form-feedback-valid-color: theme-color(success) !default;
|
94
92
|
|
95
93
|
$form-group-margin-y: $spacer !default;
|
96
94
|
|
@@ -107,14 +105,14 @@ $jumbotron-padding-y: 3rem !default;
|
|
107
105
|
|
108
106
|
// Link
|
109
107
|
|
110
|
-
$link-color:
|
111
|
-
$link-color-hover:
|
108
|
+
$link-color: theme-color(primary) !default;
|
109
|
+
$link-color-hover: theme-color(primary) !default;
|
112
110
|
$link-decoration: none !default;
|
113
111
|
$link-decoration-hover: underline !default;
|
114
112
|
|
115
113
|
// Misc
|
116
114
|
|
117
|
-
$blockquote-border-color:
|
115
|
+
$blockquote-border-color: theme-color(primary) !default;
|
118
116
|
$blockquote-border-width: 0.3125rem !default;
|
119
117
|
$blockquote-small-color: $black-hint !default;
|
120
118
|
|
@@ -157,7 +155,7 @@ $nav-link-padding-y: 0.5rem !default;
|
|
157
155
|
$nav-pills-bg-hover: $black-divider !default;
|
158
156
|
$nav-pills-border-radius: $border-radius !default;
|
159
157
|
$nav-pills-color: $black-primary !default;
|
160
|
-
$nav-pills-color-active:
|
158
|
+
$nav-pills-color-active: theme-color(secondary) !default;
|
161
159
|
$nav-pills-link-opacity: 0.7 !default;
|
162
160
|
|
163
161
|
// Pagination
|