@oruga-ui/theme-oruga 0.5.1 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -3
- package/dist/oruga.css +2 -2
- package/dist/scss/components/_autocomplete.scss +15 -15
- package/dist/scss/components/_button.scss +174 -165
- package/dist/scss/components/_carousel.scss +199 -177
- package/dist/scss/components/_checkbox.scss +130 -122
- package/dist/scss/components/_collapse.scss +11 -9
- package/dist/scss/components/_datepicker.scss +408 -416
- package/dist/scss/components/_datetimepicker.scss +8 -8
- package/dist/scss/components/_dropdown.scss +224 -206
- package/dist/scss/components/_field.scss +107 -106
- package/dist/scss/components/_icon.scss +44 -40
- package/dist/scss/components/_input.scss +127 -112
- package/dist/scss/components/_loading.scss +27 -24
- package/dist/scss/components/_menu.scss +100 -63
- package/dist/scss/components/_modal.scss +66 -66
- package/dist/scss/components/_notification.scss +146 -134
- package/dist/scss/components/_pagination.scss +227 -198
- package/dist/scss/components/_radio.scss +95 -74
- package/dist/scss/components/_select.scss +143 -120
- package/dist/scss/components/_sidebar.scss +120 -104
- package/dist/scss/components/_skeleton.scss +55 -55
- package/dist/scss/components/_slider.scss +166 -151
- package/dist/scss/components/_steps.scss +300 -287
- package/dist/scss/components/_switch.scss +115 -128
- package/dist/scss/components/_table.scss +363 -330
- package/dist/scss/components/_tabs.scss +295 -280
- package/dist/scss/components/_taginput.scss +95 -93
- package/dist/scss/components/_timepicker.scss +74 -68
- package/dist/scss/components/_tooltip.scss +522 -424
- package/dist/scss/components/_upload.scss +51 -48
- package/dist/scss/oruga.scss +0 -1
- package/dist/scss/utils/_animations.scss +97 -97
- package/dist/scss/utils/_base.scss +31 -14
- package/dist/scss/utils/_helpers.scss +65 -65
- package/dist/scss/utils/_root.scss +37 -44
- package/dist/scss/utils/_variables.scss +44 -44
- package/dist/theme.js +1 -1
- package/package.json +20 -19
|
@@ -20,152 +20,160 @@ $checkbox-line-height: 1.5 !default;
|
|
|
20
20
|
|
|
21
21
|
// checkmark svg calculation
|
|
22
22
|
@function svg_checkmark($color) {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
23
|
+
$start: '<svg width="100%" height="100%" viewBox="0 0 234 225" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:1.5;">';
|
|
24
|
+
$content: '<g transform="matrix(4.16667,0,0,4.16667,0,0)"><g transform="matrix(3.13817,0,0,3.13817,-69.2796,-49.5156)"><path style="fill:#{$color}" d="M22.504,26.219L28.637,32.386L39.494,18.284L37.348,16.379L28,27.725L24.46,24.196L22.504,26.219Z"></path></g></g>';
|
|
25
|
+
$end: "</svg>";
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
@return svg-encode("#{$start}#{$content}#{$end}");
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
// indeterminate svg calculation
|
|
31
31
|
@function svg_indeterminate($color) {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
32
|
+
$start: '<svg width="100%" height="100%" viewBox="0 0 417 417" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;">';
|
|
33
|
+
$content: '<g transform="matrix(4.16667,0,0,4.16667,0,0)"><g transform="matrix(6.96176,0,0,20.5682,-118.661,-806.753)"><path style="fill:#{$color}" d="M31.265,41.654C31.265,41.324 30.474,41.057 29.5,41.057L18.953,41.057C17.979,41.057 17.188,41.324 17.188,41.654C17.188,41.984 17.979,42.252 18.953,42.252L29.5,42.252C30.474,42.252 31.265,41.984 31.265,41.654Z"/></g></g>';
|
|
34
|
+
$end: "</svg>";
|
|
35
35
|
|
|
36
|
-
|
|
36
|
+
@return svg-encode("#{$start}#{$content}#{$end}");
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
.o-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
position: relative;
|
|
45
|
-
|
|
46
|
-
line-height: var(--#{$prefix}checkbox-line-height, $checkbox-line-height);
|
|
47
|
-
margin-right: var(
|
|
48
|
-
--#{$prefix}checkbox-margin-sibiling,
|
|
49
|
-
$checkbox-margin-sibiling
|
|
50
|
-
);
|
|
51
|
-
|
|
52
|
-
&__input {
|
|
53
|
-
width: var(--#{$prefix}checkbox-size, $checkbox-size);
|
|
54
|
-
height: var(--#{$prefix}checkbox-size, $checkbox-size);
|
|
55
|
-
margin: 0;
|
|
56
|
-
outline: none;
|
|
57
|
-
vertical-align: top;
|
|
58
|
-
-webkit-appearance: none;
|
|
59
|
-
-moz-appearance: none;
|
|
60
|
-
appearance: none;
|
|
61
|
-
-webkit-print-color-adjust: exact;
|
|
62
|
-
print-color-adjust: exact;
|
|
63
|
-
flex-shrink: 0;
|
|
39
|
+
.o-checkbox {
|
|
40
|
+
@include unselectable;
|
|
41
|
+
|
|
42
|
+
display: inline-flex;
|
|
43
|
+
align-items: center;
|
|
64
44
|
cursor: pointer;
|
|
45
|
+
position: relative;
|
|
65
46
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
47
|
+
line-height: var(--#{$prefix}checkbox-line-height, $checkbox-line-height);
|
|
48
|
+
margin-right: var(
|
|
49
|
+
--#{$prefix}checkbox-margin-sibiling,
|
|
50
|
+
$checkbox-margin-sibiling
|
|
70
51
|
);
|
|
71
|
-
background-position: center;
|
|
72
|
-
background-size: contain;
|
|
73
|
-
background-repeat: no-repeat;
|
|
74
|
-
|
|
75
|
-
transition: background var(--#{$prefix}transition-duration)
|
|
76
|
-
var(--#{$prefix}transition-timing);
|
|
77
52
|
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
--#{$prefix}
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
53
|
+
&__input {
|
|
54
|
+
width: var(--#{$prefix}checkbox-size, $checkbox-size);
|
|
55
|
+
height: var(--#{$prefix}checkbox-size, $checkbox-size);
|
|
56
|
+
margin: 0;
|
|
57
|
+
outline: none;
|
|
58
|
+
vertical-align: top;
|
|
59
|
+
-webkit-appearance: none;
|
|
60
|
+
-moz-appearance: none;
|
|
61
|
+
appearance: none;
|
|
62
|
+
-webkit-print-color-adjust: exact;
|
|
63
|
+
print-color-adjust: exact;
|
|
64
|
+
flex-shrink: 0;
|
|
65
|
+
cursor: pointer;
|
|
66
|
+
|
|
67
|
+
box-shadow: var(--#{$prefix}checkbox-box-shadow, $checkbox-box-shadow);
|
|
68
|
+
background-color: var(
|
|
69
|
+
--#{$prefix}checkbox-background-color,
|
|
70
|
+
$checkbox-background-color
|
|
71
|
+
);
|
|
72
|
+
background-position: center;
|
|
73
|
+
background-size: contain;
|
|
74
|
+
background-repeat: no-repeat;
|
|
75
|
+
|
|
76
|
+
transition: background var(--#{$prefix}transition-duration)
|
|
77
|
+
var(--#{$prefix}transition-timing);
|
|
78
|
+
|
|
79
|
+
border-radius: var(
|
|
80
|
+
--#{$prefix}checkbox-border-radius,
|
|
81
|
+
$checkbox-border-radius
|
|
82
|
+
);
|
|
83
|
+
border-width: var(
|
|
84
|
+
--#{$prefix}checkbox-border-width,
|
|
85
|
+
$checkbox-border-width
|
|
86
|
+
);
|
|
87
|
+
border-color: var(
|
|
88
|
+
--#{$prefix}checkbox-border-color,
|
|
89
|
+
$checkbox-border-color
|
|
90
|
+
);
|
|
91
|
+
border-style: var(
|
|
92
|
+
--#{$prefix}checkbox-border-style,
|
|
93
|
+
$checkbox-border-style
|
|
94
|
+
);
|
|
95
|
+
|
|
96
|
+
&:checked {
|
|
97
|
+
background-color: var(
|
|
98
|
+
--#{$prefix}checkbox-active-background-color,
|
|
99
|
+
$checkbox-active-background-color
|
|
100
|
+
);
|
|
101
|
+
border-color: var(
|
|
102
|
+
--#{$prefix}checkbox-active-background-color,
|
|
103
|
+
$checkbox-active-background-color
|
|
104
|
+
);
|
|
105
|
+
background-image: url(svg_checkmark($checkbox-checkmark-color));
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
&:indeterminate {
|
|
109
|
+
background-color: var(
|
|
110
|
+
--#{$prefix}checkbox-active-background-color,
|
|
111
|
+
$checkbox-active-background-color
|
|
112
|
+
);
|
|
113
|
+
border-color: var(
|
|
114
|
+
--#{$prefix}checkbox-active-background-color,
|
|
115
|
+
$checkbox-active-background-color
|
|
116
|
+
);
|
|
117
|
+
background-image: url(svg_indeterminate($checkbox-checkmark-color));
|
|
118
|
+
}
|
|
105
119
|
}
|
|
106
120
|
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
border-color: var(
|
|
113
|
-
--#{$prefix}checkbox-active-background-color,
|
|
114
|
-
$checkbox-active-background-color
|
|
115
|
-
);
|
|
116
|
-
background-image: url(svg_indeterminate($checkbox-checkmark-color));
|
|
121
|
+
&__label {
|
|
122
|
+
padding: var(
|
|
123
|
+
--#{$prefix}checkbox-label-padding,
|
|
124
|
+
$checkbox-label-padding
|
|
125
|
+
);
|
|
117
126
|
}
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
&__label {
|
|
121
|
-
padding: var(--#{$prefix}checkbox-label-padding, $checkbox-label-padding);
|
|
122
|
-
}
|
|
123
127
|
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
128
|
+
&--disabled {
|
|
129
|
+
opacity: var(
|
|
130
|
+
--#{$prefix}checkbox-disabled-opacity,
|
|
131
|
+
$checkbox-disabled-opacity
|
|
132
|
+
);
|
|
133
|
+
}
|
|
130
134
|
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
+
// size variants
|
|
136
|
+
@each $name, $value in $sizes {
|
|
137
|
+
&--#{$name} {
|
|
138
|
+
font-size: var(--#{$prefix}checkbox-font-size-#{$name}, $value);
|
|
135
139
|
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
+
.o-checkbox__input {
|
|
141
|
+
width: var(--#{$prefix}checkbox-font-size-#{$name}, $value);
|
|
142
|
+
height: var(--#{$prefix}checkbox-font-size-#{$name}, $value);
|
|
143
|
+
}
|
|
144
|
+
}
|
|
140
145
|
}
|
|
141
|
-
}
|
|
142
146
|
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
+
// color variants
|
|
148
|
+
@each $name, $pair in $colors {
|
|
149
|
+
$color: list.nth($pair, 1);
|
|
150
|
+
$color-invert: list.nth($pair, 2);
|
|
147
151
|
|
|
148
|
-
|
|
149
|
-
|
|
152
|
+
&--#{$name} {
|
|
153
|
+
--#{$prefix}focus: #{createFocus($color)};
|
|
150
154
|
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
}
|
|
155
|
+
.o-checkbox__input {
|
|
156
|
+
border-color: var(--#{$prefix}variant-#{$name}, $color);
|
|
157
|
+
background-color: var(--#{$prefix}variant-#{$name}, $color);
|
|
155
158
|
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
+
&:checked {
|
|
160
|
+
background-image: url(svg_checkmark($color-invert));
|
|
161
|
+
}
|
|
159
162
|
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
+
&:indeterminate {
|
|
164
|
+
background-image: url(svg_indeterminate($color-invert));
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
}
|
|
163
168
|
}
|
|
164
|
-
}
|
|
165
169
|
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
170
|
+
// focus effect
|
|
171
|
+
&:focus,
|
|
172
|
+
&:focus-visible,
|
|
173
|
+
&:focus-within {
|
|
174
|
+
.o-checkbox__input {
|
|
175
|
+
box-shadow: 0 0 0 0.25rem var(--#{$prefix}focus);
|
|
176
|
+
outline: none;
|
|
177
|
+
}
|
|
178
|
+
}
|
|
171
179
|
}
|
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
/* @docs */
|
|
2
2
|
/* @docs */
|
|
3
3
|
|
|
4
|
-
.o-
|
|
5
|
-
|
|
4
|
+
.o-collapse {
|
|
5
|
+
&__trigger {
|
|
6
|
+
cursor: pointer;
|
|
7
|
+
display: inline-block;
|
|
6
8
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
&--expanded {
|
|
10
|
+
width: 100%;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
11
13
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
14
|
+
&__content {
|
|
15
|
+
display: inherit;
|
|
16
|
+
}
|
|
15
17
|
}
|