@oruga-ui/theme-oruga 0.7.1 → 0.8.1
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/LICENSE +1 -1
- package/README.md +5 -5
- package/dist/scss/components/_autocomplete.scss +3 -12
- package/dist/scss/components/_breadcrumb.scss +122 -103
- package/dist/scss/components/_button.scss +228 -173
- package/dist/scss/components/_carousel.scss +164 -142
- package/dist/scss/components/_checkbox.scss +118 -118
- package/dist/scss/components/_collapse.scss +1 -1
- package/dist/scss/components/_datepicker.scss +228 -290
- package/dist/scss/components/_datetimepicker.scss +8 -2
- package/dist/scss/components/_dialog.scss +243 -0
- package/dist/scss/components/_dropdown.scss +190 -164
- package/dist/scss/components/_field.scss +68 -39
- package/dist/scss/components/_icon.scss +24 -29
- package/dist/scss/components/_input.scss +112 -97
- package/dist/scss/components/_listbox.scss +176 -0
- package/dist/scss/components/_loading.scss +35 -15
- package/dist/scss/components/_menu.scss +113 -109
- package/dist/scss/components/_modal.scss +112 -50
- package/dist/scss/components/_notification.scss +113 -97
- package/dist/scss/components/_pagination.scss +173 -106
- package/dist/scss/components/_radio.scss +91 -84
- package/dist/scss/components/_select.scss +108 -115
- package/dist/scss/components/_sidebar.scss +102 -101
- package/dist/scss/components/_skeleton.scss +50 -39
- package/dist/scss/components/_slider.scss +221 -159
- package/dist/scss/components/_steps.scss +223 -261
- package/dist/scss/components/_switch.scss +126 -90
- package/dist/scss/components/_table.scss +307 -251
- package/dist/scss/components/_tabs.scss +360 -247
- package/dist/scss/components/_tag.scss +95 -39
- package/dist/scss/components/_taginput.scss +48 -36
- package/dist/scss/components/_timepicker.scss +61 -62
- package/dist/scss/components/_tooltip.scss +129 -254
- package/dist/scss/components/_upload.scss +83 -35
- package/dist/scss/theme-build.scss +9 -0
- package/dist/scss/theme.scss +44 -0
- package/dist/scss/utils/_animations.scss +30 -9
- package/dist/scss/utils/_base.scss +6 -4
- package/dist/scss/utils/_helpers.scss +84 -22
- package/dist/scss/utils/_root.scss +82 -29
- package/dist/scss/utils/_variables.scss +64 -42
- package/dist/theme.css +2 -0
- package/dist/theme.js +1 -1
- package/package.json +27 -20
- package/dist/oruga.css +0 -2
- package/dist/scss/oruga-build.scss +0 -9
- package/dist/scss/oruga.scss +0 -42
|
@@ -1,29 +1,67 @@
|
|
|
1
1
|
@use "sass:list";
|
|
2
|
+
@use "../utils/helpers" as h;
|
|
3
|
+
@use "../utils/variables" as vars;
|
|
2
4
|
|
|
3
5
|
/* @docs */
|
|
4
|
-
$tag-color: var(--#{$prefix}grey-dark) !default;
|
|
5
|
-
$tag-background-color: $control-brackground-color !default;
|
|
6
|
-
$tag-border-radius: var(--#{$prefix}base-border-radius) !default;
|
|
7
|
-
$tag-rounded-border-radius: var(
|
|
8
|
-
--#{$prefix}base-border-radius-rounded
|
|
9
|
-
) !default;
|
|
10
6
|
$tag-padding: 0 0.75em !default;
|
|
11
|
-
$tag-
|
|
7
|
+
$tag-color: h.useVar("font-color") !default;
|
|
8
|
+
$tag-font-size: h.useVar("font-size") !default;
|
|
9
|
+
$tag-font-weight: h.useVar("font-weight") !default;
|
|
10
|
+
$tag-line-height: h.useVar("line-height") !default;
|
|
11
|
+
$tag-height: h.useVar("control-height") !default;
|
|
12
|
+
$tag-icon-spacer: h.useVar("control-spacer") !default;
|
|
13
|
+
|
|
14
|
+
$tag-close-color: h.useVar("font-color") !default;
|
|
15
|
+
|
|
16
|
+
$tag-box-shadow: unset !default;
|
|
17
|
+
$tag-background-color: h.useVar("grey-lightest") !default;
|
|
18
|
+
$tag-border-color: transparent !default;
|
|
19
|
+
$tag-border-style: solid !default;
|
|
20
|
+
$tag-border-width: h.useVar("control-border-width") !default;
|
|
21
|
+
$tag-border-radius: h.useVar("border-radius") !default;
|
|
22
|
+
$tag-border-radius-rounded: h.useVar("border-radius-rounded") !default;
|
|
12
23
|
/* @docs */
|
|
13
24
|
|
|
14
25
|
.o-tag {
|
|
26
|
+
@include h.defineVar("tag-padding", $tag-padding);
|
|
27
|
+
@include h.defineVar("tag-color", $tag-color);
|
|
28
|
+
@include h.defineVar("tag-font-size", $tag-font-size);
|
|
29
|
+
@include h.defineVar("tag-font-weight", $tag-font-weight);
|
|
30
|
+
@include h.defineVar("tag-line-height", $tag-line-height);
|
|
31
|
+
@include h.defineVar("tag-height", $tag-height);
|
|
32
|
+
@include h.defineVar("tag-icon-spacer", $tag-icon-spacer);
|
|
33
|
+
|
|
34
|
+
@include h.defineVar("tag-close-color", $tag-close-color);
|
|
35
|
+
|
|
36
|
+
@include h.defineVar("tag-box-shadow", $tag-box-shadow);
|
|
37
|
+
@include h.defineVar("tag-background-color", $tag-background-color);
|
|
38
|
+
@include h.defineVar("tag-border-color", $tag-border-color);
|
|
39
|
+
@include h.defineVar("tag-border-style", $tag-border-style);
|
|
40
|
+
@include h.defineVar("tag-border-width", $tag-border-width);
|
|
41
|
+
@include h.defineVar("tag-border-radius", $tag-border-radius);
|
|
42
|
+
@include h.defineVar(
|
|
43
|
+
"tag-border-radius-rounded",
|
|
44
|
+
$tag-border-radius-rounded
|
|
45
|
+
);
|
|
46
|
+
|
|
15
47
|
display: inline-flex;
|
|
16
48
|
align-items: center;
|
|
17
49
|
justify-content: center;
|
|
18
|
-
line-height: 1.5;
|
|
19
50
|
white-space: nowrap;
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
);
|
|
25
|
-
|
|
26
|
-
|
|
51
|
+
|
|
52
|
+
padding: h.useVar("tag-padding");
|
|
53
|
+
|
|
54
|
+
color: h.useVar("tag-color");
|
|
55
|
+
font-size: calc(0.75 * h.useVar("tag-font-size"));
|
|
56
|
+
font-weight: h.useVar("tag-font-weight");
|
|
57
|
+
line-height: h.useVar("tag-line-height");
|
|
58
|
+
|
|
59
|
+
box-shadow: h.useVar("tag-box-shadow");
|
|
60
|
+
background-color: h.useVar("tag-background-color");
|
|
61
|
+
border-color: h.useVar("tag-border-color");
|
|
62
|
+
border-style: h.useVar("tag-border-style");
|
|
63
|
+
border-width: h.useVar("tag-border-width");
|
|
64
|
+
border-radius: h.useVar("tag-border-radius");
|
|
27
65
|
|
|
28
66
|
&:empty {
|
|
29
67
|
width: 1em;
|
|
@@ -31,10 +69,17 @@ $tag-icon-margin: 0.5em !default;
|
|
|
31
69
|
padding-right: 0;
|
|
32
70
|
}
|
|
33
71
|
|
|
72
|
+
&:focus,
|
|
73
|
+
&:hover {
|
|
74
|
+
/* background-color: darken($color-invert, 5%)*/
|
|
75
|
+
/* IE 11 needs polyfill*/
|
|
76
|
+
filter: brightness(98%);
|
|
77
|
+
}
|
|
78
|
+
|
|
34
79
|
&--rounded {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
80
|
+
@include h.defineVar(
|
|
81
|
+
"tag-border-radius",
|
|
82
|
+
h.useVar("tag-border-radius-rounded")
|
|
38
83
|
);
|
|
39
84
|
}
|
|
40
85
|
|
|
@@ -42,43 +87,54 @@ $tag-icon-margin: 0.5em !default;
|
|
|
42
87
|
position: absolute;
|
|
43
88
|
top: 0;
|
|
44
89
|
left: 100%;
|
|
45
|
-
transform:
|
|
90
|
+
transform: translateX(-50%);
|
|
46
91
|
}
|
|
47
92
|
|
|
48
93
|
&__icon {
|
|
49
|
-
margin-right:
|
|
94
|
+
margin-right: h.useVar("tag-icon-spacer");
|
|
50
95
|
}
|
|
51
96
|
|
|
52
97
|
&__close {
|
|
53
|
-
margin-left:
|
|
98
|
+
margin-left: h.useVar("tag-icon-spacer");
|
|
99
|
+
|
|
100
|
+
// add clickable cursor
|
|
101
|
+
@include h.clickable;
|
|
102
|
+
|
|
103
|
+
padding: 0;
|
|
104
|
+
|
|
105
|
+
display: inline-flex;
|
|
106
|
+
align-items: center;
|
|
107
|
+
justify-content: center;
|
|
108
|
+
|
|
109
|
+
color: h.useVar("tag-close-color");
|
|
110
|
+
|
|
111
|
+
border: none;
|
|
112
|
+
background-color: transparent;
|
|
113
|
+
|
|
114
|
+
&:focus,
|
|
115
|
+
&:hover {
|
|
116
|
+
// darken color on hover
|
|
117
|
+
filter: brightness(90%);
|
|
118
|
+
}
|
|
54
119
|
}
|
|
55
120
|
|
|
56
121
|
// size variants
|
|
57
|
-
@each $name, $value in
|
|
122
|
+
@each $name, $value in vars.$sizes {
|
|
58
123
|
&--#{$name} {
|
|
59
|
-
|
|
124
|
+
@include h.defineVar("tag-font-size", h.useVar("size-#{$name}"));
|
|
60
125
|
}
|
|
61
126
|
}
|
|
62
127
|
|
|
63
128
|
// color variants
|
|
64
|
-
@each $name, $pair in
|
|
65
|
-
$color: list.nth($pair, 1);
|
|
66
|
-
$color-invert: list.nth($pair, 2);
|
|
67
|
-
|
|
129
|
+
@each $name, $pair in vars.$colors {
|
|
68
130
|
&--#{$name} {
|
|
69
|
-
background-color
|
|
70
|
-
border-color
|
|
71
|
-
|
|
72
|
-
|
|
131
|
+
@include h.defineVar("tag-background-color", h.useVar($name));
|
|
132
|
+
@include h.defineVar("tag-border-color", h.useVar($name));
|
|
133
|
+
@include h.defineVar("tag-color", h.useVar("#{$name}-invert"));
|
|
134
|
+
@include h.defineVar(
|
|
135
|
+
"tag-close-color",
|
|
136
|
+
h.useVar("#{$name}-invert")
|
|
73
137
|
);
|
|
74
|
-
color: var(--#{$prefix}variant-invert-#{$name}, $color-invert);
|
|
75
|
-
|
|
76
|
-
&:focus,
|
|
77
|
-
&:hover {
|
|
78
|
-
/* background-color: darken($color-invert, 5%)*/
|
|
79
|
-
/* IE 11 needs polyfill*/
|
|
80
|
-
filter: brightness(95%);
|
|
81
|
-
}
|
|
82
138
|
}
|
|
83
139
|
}
|
|
84
140
|
}
|
|
@@ -1,35 +1,50 @@
|
|
|
1
1
|
@use "sass:list";
|
|
2
|
+
@use "../utils/helpers" as h;
|
|
3
|
+
@use "../utils/variables" as vars;
|
|
4
|
+
@use "./input";
|
|
2
5
|
|
|
3
6
|
/* @docs */
|
|
4
|
-
$taginput-counter-font-size: 0.
|
|
5
|
-
$taginput-counter-
|
|
6
|
-
$taginput-item-
|
|
7
|
+
$taginput-counter-font-size: 0.85rem !default;
|
|
8
|
+
$taginput-counter-spacer: h.useVar("control-spacer") !default;
|
|
9
|
+
$taginput-item-spacer: h.useVar("control-spacer") !default;
|
|
7
10
|
/* @docs */
|
|
8
11
|
|
|
9
12
|
.o-taginput {
|
|
13
|
+
@include h.defineVar(
|
|
14
|
+
"taginput-counter-font-size",
|
|
15
|
+
$taginput-counter-font-size
|
|
16
|
+
);
|
|
17
|
+
@include h.defineVar("taginput-counter-spacer", $taginput-counter-spacer);
|
|
18
|
+
@include h.defineVar("taginput-item-spacer", $taginput-item-spacer);
|
|
19
|
+
|
|
10
20
|
display: flex;
|
|
11
21
|
|
|
22
|
+
// extend o-input design
|
|
23
|
+
@extend .o-input;
|
|
24
|
+
|
|
25
|
+
// define focus shadow effect
|
|
26
|
+
@include h.focusable(".o-taginput__container");
|
|
27
|
+
|
|
28
|
+
// disable input focus
|
|
29
|
+
&:hover,
|
|
30
|
+
&:focus,
|
|
31
|
+
&:focus-visible,
|
|
32
|
+
&:focus-within {
|
|
33
|
+
.o-input__input:not(.o-taginput__container) {
|
|
34
|
+
box-shadow: unset !important;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
12
38
|
&__container {
|
|
13
39
|
display: flex;
|
|
14
40
|
flex-wrap: wrap;
|
|
15
41
|
align-items: center;
|
|
16
42
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
border-color: var(--#{$prefix}input-border-color, $input-border-color);
|
|
23
|
-
border-style: var(--#{$prefix}input-border-style, $input-border-style);
|
|
24
|
-
border-width: var(--#{$prefix}input-border-width, $input-border-width);
|
|
25
|
-
border-radius: var(
|
|
26
|
-
--#{$prefix}input-border-radius,
|
|
27
|
-
$input-border-radius
|
|
28
|
-
);
|
|
29
|
-
color: var(--#{$prefix}input-color, $input-color);
|
|
30
|
-
line-height: var(--#{$prefix}input-line-height, $input-line-height);
|
|
31
|
-
margin: var(--#{$prefix}input-margin, $input-margin);
|
|
32
|
-
width: var(--#{$prefix}taginput-width, inherit);
|
|
43
|
+
padding: 0;
|
|
44
|
+
height: fit-content;
|
|
45
|
+
|
|
46
|
+
// pretend container is input element
|
|
47
|
+
@extend .o-input__input;
|
|
33
48
|
}
|
|
34
49
|
|
|
35
50
|
&__autocomplete {
|
|
@@ -43,28 +58,25 @@ $taginput-item-margin: 0.275em !default;
|
|
|
43
58
|
box-shadow: none;
|
|
44
59
|
}
|
|
45
60
|
|
|
46
|
-
// size variants
|
|
47
|
-
@each $name, $value in $sizes {
|
|
48
|
-
&--#{$name} {
|
|
49
|
-
font-size: var(--#{$prefix}taginput-font-size-#{$name}, $value);
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
61
|
&__item {
|
|
54
|
-
margin:
|
|
62
|
+
margin: calc(0.5 * h.useVar("taginput-item-spacer"));
|
|
63
|
+
font-size: h.useVar("tag-font-size");
|
|
64
|
+
|
|
65
|
+
&:first-child {
|
|
66
|
+
margin-left: h.useVar("taginput-item-spacer");
|
|
67
|
+
}
|
|
55
68
|
}
|
|
56
69
|
|
|
57
70
|
&__counter {
|
|
58
|
-
display:
|
|
71
|
+
display: inline-flex;
|
|
59
72
|
float: right;
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
);
|
|
73
|
+
align-items: center;
|
|
74
|
+
font-size: h.useVar("taginput-counter-font-size");
|
|
75
|
+
margin: h.useVar("taginput-counter-spacer");
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
&--disabled {
|
|
79
|
+
@include h.disabled(h.useVar("input-disabled-opacity"));
|
|
68
80
|
}
|
|
69
81
|
|
|
70
82
|
&--expanded {
|
|
@@ -1,98 +1,97 @@
|
|
|
1
|
+
@use "../utils/helpers" as h;
|
|
2
|
+
@use "../utils/variables" as vars;
|
|
3
|
+
|
|
1
4
|
/* @docs */
|
|
2
|
-
$timepicker-font-size:
|
|
3
|
-
$timepicker-
|
|
4
|
-
$timepicker-
|
|
5
|
+
$timepicker-font-size: h.useVar("font-size") !default;
|
|
6
|
+
$timepicker-color: h.useVar("font-color") !default;
|
|
7
|
+
$timepicker-line-height: h.useVar("line-height") !default;
|
|
8
|
+
$timepicker-font-weight: 600 !default;
|
|
9
|
+
$timepicker-box-padding: 0 calc(2 * h.useVar("control-spacer")) !default;
|
|
10
|
+
|
|
5
11
|
$timepicker-footer-padding: 0 0.5rem !default;
|
|
6
|
-
|
|
7
|
-
$timepicker-select-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
$timepicker-select-color: #363636 !default;
|
|
11
|
-
$timepicker-select-font-weight: 600 !default;
|
|
12
|
-
$timepicker-select-placeholder-opacity: var(
|
|
13
|
-
--#{$prefix}base-disabled-opacity
|
|
14
|
-
) !default;
|
|
15
|
-
$timepicker-separator-font-weight: 600 !default;
|
|
12
|
+
|
|
13
|
+
$timepicker-select-padding: h.useVar("control-padding-vertical")
|
|
14
|
+
h.useVar("control-padding-horizontal") !default;
|
|
15
|
+
$timepicker-select-placeholder-opacity: h.useVar("disabled-opacity") !default;
|
|
16
16
|
/* @docs */
|
|
17
17
|
|
|
18
18
|
.o-timepicker {
|
|
19
|
-
|
|
19
|
+
@include h.defineVar("timepicker-color", $timepicker-color);
|
|
20
|
+
@include h.defineVar("timepicker-font-size", $timepicker-font-size);
|
|
21
|
+
@include h.defineVar("timepicker-font-weight", $timepicker-font-weight);
|
|
22
|
+
@include h.defineVar("timepicker-line-height", $timepicker-line-height);
|
|
23
|
+
@include h.defineVar("timepicker-box-padding", $timepicker-box-padding);
|
|
24
|
+
|
|
25
|
+
@include h.defineVar(
|
|
26
|
+
"timepicker-footer-padding",
|
|
27
|
+
$timepicker-footer-padding
|
|
28
|
+
);
|
|
20
29
|
|
|
21
|
-
@
|
|
30
|
+
@include h.defineVar(
|
|
31
|
+
"timepicker-select-padding",
|
|
32
|
+
$timepicker-select-padding
|
|
33
|
+
);
|
|
34
|
+
@include h.defineVar(
|
|
35
|
+
"timepicker-select-placeholder-opacity",
|
|
36
|
+
$timepicker-select-placeholder-opacity
|
|
37
|
+
);
|
|
38
|
+
|
|
39
|
+
font-size: h.useVar("timepicker-font-size");
|
|
40
|
+
font-weight: h.useVar("timepicker-font-weight");
|
|
41
|
+
line-height: h.useVar("timepicker-line-height");
|
|
42
|
+
color: h.useVar("timepicker-color");
|
|
43
|
+
|
|
44
|
+
// size variants
|
|
45
|
+
@each $name, $value in vars.$sizes {
|
|
22
46
|
&--#{$name} {
|
|
23
|
-
|
|
47
|
+
@include h.defineVar(
|
|
48
|
+
"timepicker-font-size",
|
|
49
|
+
h.useVar("size-#{$name}")
|
|
50
|
+
);
|
|
24
51
|
}
|
|
25
52
|
}
|
|
26
53
|
|
|
27
54
|
&__dropdown {
|
|
28
55
|
width: 100%;
|
|
56
|
+
|
|
57
|
+
.o-dropdown__menu {
|
|
58
|
+
min-width: 12rem;
|
|
59
|
+
}
|
|
29
60
|
}
|
|
30
61
|
|
|
31
62
|
&__box {
|
|
32
63
|
display: flex;
|
|
33
64
|
justify-content: center;
|
|
34
65
|
align-items: center;
|
|
35
|
-
|
|
36
|
-
--#{$prefix}timepicker-box-line-height,
|
|
37
|
-
$timepicker-box-line-height
|
|
38
|
-
);
|
|
39
|
-
padding: var(
|
|
40
|
-
--#{$prefix}timepicker-box-padding,
|
|
41
|
-
$timepicker-box-padding
|
|
42
|
-
);
|
|
66
|
+
padding: h.useVar("timepicker-box-padding");
|
|
43
67
|
}
|
|
44
68
|
|
|
45
69
|
&__select {
|
|
46
|
-
|
|
47
|
-
|
|
70
|
+
// remove default appearance
|
|
71
|
+
@include h.removeAppearance;
|
|
72
|
+
// add clickable cursor
|
|
73
|
+
@include h.clickable;
|
|
74
|
+
|
|
48
75
|
display: inline-block;
|
|
49
76
|
position: relative;
|
|
50
77
|
vertical-align: top;
|
|
51
|
-
cursor: pointer;
|
|
52
78
|
justify-content: flex-start;
|
|
53
79
|
align-items: center;
|
|
54
80
|
border: 0;
|
|
81
|
+
|
|
55
82
|
font-size: inherit;
|
|
56
|
-
font-weight:
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
);
|
|
60
|
-
line-height: var(
|
|
61
|
-
--#{$prefix}timepicker-select-line-height,
|
|
62
|
-
$timepicker-select-line-height
|
|
63
|
-
);
|
|
64
|
-
color: var(
|
|
65
|
-
--#{$prefix}timepicker-select-color,
|
|
66
|
-
$timepicker-select-color
|
|
67
|
-
);
|
|
68
|
-
padding: var(
|
|
69
|
-
--#{$prefix}timepicker-select-padding,
|
|
70
|
-
$timepicker-select-padding
|
|
71
|
-
);
|
|
72
|
-
}
|
|
83
|
+
font-weight: inherit;
|
|
84
|
+
line-height: inherit;
|
|
85
|
+
color: inherit;
|
|
73
86
|
|
|
74
|
-
|
|
75
|
-
opacity: var(
|
|
76
|
-
--#{$prefix}timepicker-select-placeholder-opacity,
|
|
77
|
-
$timepicker-select-placeholder-opacity
|
|
78
|
-
);
|
|
87
|
+
padding: h.useVar("timepicker-select-padding");
|
|
79
88
|
}
|
|
80
89
|
|
|
81
|
-
&
|
|
82
|
-
|
|
83
|
-
--#{$prefix}timepicker-separator-font-weight,
|
|
84
|
-
$timepicker-separator-font-weight
|
|
85
|
-
);
|
|
90
|
+
&__select-placeholder {
|
|
91
|
+
opacity: h.useVar("timepicker-select-placeholder-opacity");
|
|
86
92
|
}
|
|
87
93
|
|
|
88
94
|
&__footer {
|
|
89
|
-
padding:
|
|
90
|
-
--#{$prefix}timepicker-header-padding,
|
|
91
|
-
$timepicker-footer-padding
|
|
92
|
-
);
|
|
93
|
-
margin: var(
|
|
94
|
-
--#{$prefix}timepicker-header-margin,
|
|
95
|
-
$timepicker-footer-margin
|
|
96
|
-
);
|
|
95
|
+
padding: h.useVar("timepicker-header-padding");
|
|
97
96
|
}
|
|
98
97
|
}
|