@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.
Files changed (39) hide show
  1. package/README.md +4 -3
  2. package/dist/oruga.css +2 -2
  3. package/dist/scss/components/_autocomplete.scss +15 -15
  4. package/dist/scss/components/_button.scss +174 -165
  5. package/dist/scss/components/_carousel.scss +199 -177
  6. package/dist/scss/components/_checkbox.scss +130 -122
  7. package/dist/scss/components/_collapse.scss +11 -9
  8. package/dist/scss/components/_datepicker.scss +408 -416
  9. package/dist/scss/components/_datetimepicker.scss +8 -8
  10. package/dist/scss/components/_dropdown.scss +224 -206
  11. package/dist/scss/components/_field.scss +107 -106
  12. package/dist/scss/components/_icon.scss +44 -40
  13. package/dist/scss/components/_input.scss +127 -112
  14. package/dist/scss/components/_loading.scss +27 -24
  15. package/dist/scss/components/_menu.scss +100 -63
  16. package/dist/scss/components/_modal.scss +66 -66
  17. package/dist/scss/components/_notification.scss +146 -134
  18. package/dist/scss/components/_pagination.scss +227 -198
  19. package/dist/scss/components/_radio.scss +95 -74
  20. package/dist/scss/components/_select.scss +143 -120
  21. package/dist/scss/components/_sidebar.scss +120 -104
  22. package/dist/scss/components/_skeleton.scss +55 -55
  23. package/dist/scss/components/_slider.scss +166 -151
  24. package/dist/scss/components/_steps.scss +300 -287
  25. package/dist/scss/components/_switch.scss +115 -128
  26. package/dist/scss/components/_table.scss +363 -330
  27. package/dist/scss/components/_tabs.scss +295 -280
  28. package/dist/scss/components/_taginput.scss +95 -93
  29. package/dist/scss/components/_timepicker.scss +74 -68
  30. package/dist/scss/components/_tooltip.scss +522 -424
  31. package/dist/scss/components/_upload.scss +51 -48
  32. package/dist/scss/oruga.scss +0 -1
  33. package/dist/scss/utils/_animations.scss +97 -97
  34. package/dist/scss/utils/_base.scss +31 -14
  35. package/dist/scss/utils/_helpers.scss +65 -65
  36. package/dist/scss/utils/_root.scss +37 -44
  37. package/dist/scss/utils/_variables.scss +44 -44
  38. package/dist/theme.js +1 -1
  39. package/package.json +20 -19
@@ -2,22 +2,22 @@
2
2
  $autocomplete-item-hover-background-color: #f5f5f5 !default;
3
3
  /* @docs */
4
4
 
5
- .o-acp {
6
- &__item {
7
- white-space: nowrap;
8
- overflow: hidden;
9
- text-overflow: ellipsis;
5
+ .o-autocomplete {
6
+ &__item {
7
+ white-space: nowrap;
8
+ overflow: hidden;
9
+ text-overflow: ellipsis;
10
10
 
11
- &-group-title,
12
- &--empty {
13
- @extend .o-drop--disabled;
14
- }
11
+ &-group-title,
12
+ &--empty {
13
+ @extend .o-dropdown--disabled;
14
+ }
15
15
 
16
- &--hover {
17
- background-color: var(
18
- --#{$prefix}autocomplete-item-hover-background-color,
19
- $autocomplete-item-hover-background-color
20
- );
16
+ &--focused {
17
+ background-color: var(
18
+ --#{$prefix}autocomplete-item-hover-background-color,
19
+ $autocomplete-item-hover-background-color
20
+ );
21
+ }
21
22
  }
22
- }
23
23
  }
@@ -15,7 +15,7 @@ $button-spacer: 0.5rem !default;
15
15
  $button-height: $control-height !default;
16
16
  $button-padding: $control-padding-vertical 0.75em !default;
17
17
  $button-rounded-border-radius: var(
18
- --#{$prefix}#{base-border-radius-rounded}
18
+ --#{$prefix}#{base-border-radius-rounded}
19
19
  ) !default;
20
20
  $button-disabled-opacity: var(--#{$prefix}#{base-disabled-opacity}) !default;
21
21
  $button-outlined-background-color: transparent !default;
@@ -23,200 +23,209 @@ $button-outlined-border-color: var(--#{$prefix}grey-light) !default;
23
23
  /* @docs */
24
24
 
25
25
  @keyframes spinAround {
26
- from {
27
- transform: rotate(0deg);
28
- }
26
+ from {
27
+ transform: rotate(0deg);
28
+ }
29
29
 
30
- to {
31
- transform: rotate(359deg);
32
- }
30
+ to {
31
+ transform: rotate(359deg);
32
+ }
33
33
  }
34
34
 
35
- .o-btn {
36
- position: relative;
37
- display: inline-flex;
38
- cursor: pointer;
39
- text-align: center;
40
- white-space: nowrap;
41
- align-items: center;
42
- justify-content: center;
43
- vertical-align: top;
44
- text-decoration: none;
45
-
46
- @include unselectable;
47
- -moz-appearance: none;
48
- -webkit-appearance: none;
49
-
50
- background-color: var(
51
- --#{$prefix}button-background-color,
52
- $button-background-color
53
- );
54
- color: var(--#{$prefix}button-color, $button-color);
55
- padding: var(--#{$prefix}button-padding, $button-padding);
56
- border: var(--#{$prefix}button-border, $button-border);
57
- border-radius: var(--#{$prefix}button-border-radius, $button-border-radius);
58
- box-shadow: var(--#{$prefix}button-box-shadow, $button-box-shadow);
59
- font-size: var(--#{$prefix}base-font-size, $base-font-size);
60
- font-weight: var(--#{$prefix}button-font-weight, $button-font-weight);
61
- line-height: var(--#{$prefix}button-line-height, $button-line-height);
62
- margin: var(--#{$prefix}button-margin, $button-margin);
63
- height: var(--#{$prefix}button-height, $button-height);
64
-
65
- &__wrapper {
35
+ .o-button {
36
+ @include unselectable;
37
+
38
+ position: relative;
66
39
  display: inline-flex;
40
+ cursor: pointer;
41
+ text-align: center;
42
+ white-space: nowrap;
67
43
  align-items: center;
68
44
  justify-content: center;
69
- position: relative;
70
- width: 100%;
71
-
72
- @include side-flex-gap($button-margin-icon-to-text);
73
- }
74
-
75
- &__label {
76
- width: 100%;
77
- }
78
-
79
- &--expanded {
80
- width: 100%;
81
- }
82
-
83
- &--rounded {
84
- border-radius: var(
85
- --#{$prefix}button-rounded-border-radius,
86
- $button-rounded-border-radius
45
+ vertical-align: top;
46
+ text-decoration: none;
47
+ -moz-appearance: none;
48
+ -webkit-appearance: none;
49
+
50
+ background-color: var(
51
+ --#{$prefix}button-background-color,
52
+ $button-background-color
87
53
  );
88
- }
89
-
90
- &--disabled {
91
- opacity: var(--#{$prefix}button-disabled-opacity, $button-disabled-opacity);
92
- cursor: not-allowed;
93
- pointer-events: none;
94
- }
95
-
96
- /* size variants*/
97
- @each $name, $value in $sizes {
98
- &--#{$name} {
99
- font-size: var(--#{$prefix}button-font-size-#{$name}, $value);
54
+ color: var(--#{$prefix}button-color, $button-color);
55
+ padding: var(--#{$prefix}button-padding, $button-padding);
56
+ border: var(--#{$prefix}button-border, $button-border);
57
+ border-radius: var(--#{$prefix}button-border-radius, $button-border-radius);
58
+ box-shadow: var(--#{$prefix}button-box-shadow, $button-box-shadow);
59
+ font-size: var(--#{$prefix}base-font-size, $base-font-size);
60
+ font-weight: var(--#{$prefix}button-font-weight, $button-font-weight);
61
+ line-height: var(--#{$prefix}button-line-height, $button-line-height);
62
+ margin: var(--#{$prefix}button-margin, $button-margin);
63
+ height: var(--#{$prefix}button-height, $button-height);
64
+
65
+ &__wrapper {
66
+ display: inline-flex;
67
+ align-items: center;
68
+ justify-content: center;
69
+ position: relative;
70
+ width: 100%;
71
+
72
+ @include side-flex-gap($button-margin-icon-to-text);
100
73
  }
101
- }
102
74
 
103
- /* color variants*/
104
- @each $name, $pair in $colors {
105
- $color: list.nth($pair, 1);
106
- $color-invert: list.nth($pair, 2);
75
+ &__label {
76
+ width: 100%;
77
+ }
107
78
 
108
- &--#{$name} {
109
- --#{$prefix}focus: #{createFocus($color)};
79
+ &--expanded {
80
+ width: 100%;
81
+ }
110
82
 
111
- border-color: transparent;
112
- background-color: var(--#{$prefix}variant-#{$name}, $color);
113
- color: var(--#{$prefix}variant-invert-#{$name}, $color-invert);
83
+ &--rounded {
84
+ border-radius: var(
85
+ --#{$prefix}button-rounded-border-radius,
86
+ $button-rounded-border-radius
87
+ );
88
+ }
114
89
 
115
- &:hover {
116
- /* background-color: darken($color, 2.5%)*/
117
- /* IE 11 needs polyfill*/
118
- filter: brightness(97.5%);
119
- }
90
+ &--disabled {
91
+ opacity: var(
92
+ --#{$prefix}button-disabled-opacity,
93
+ $button-disabled-opacity
94
+ );
95
+ cursor: not-allowed;
96
+ pointer-events: none;
120
97
  }
121
- }
122
98
 
123
- &--outlined {
124
- &:focus,
125
- &:hover {
126
- background-color: var(
127
- --#{$prefix}button-border-color,
128
- $button-border-color
129
- );
130
- color: var(--#{$prefix}button-color, $button-color);
99
+ /* size variants*/
100
+ @each $name, $value in $sizes {
101
+ &--#{$name} {
102
+ font-size: var(--#{$prefix}button-font-size-#{$name}, $value);
103
+ }
131
104
  }
132
105
 
106
+ /* color variants*/
133
107
  @each $name, $pair in $colors {
134
- $color: list.nth($pair, 1);
135
- $color-invert: list.nth($pair, 2);
108
+ $color: list.nth($pair, 1);
109
+ $color-invert: list.nth($pair, 2);
136
110
 
137
- &-#{$name} {
138
- --#{$prefix}focus: #{createFocus($color)};
111
+ &--#{$name} {
112
+ --#{$prefix}focus: #{createFocus($color)};
139
113
 
140
- background-color: var(
141
- --#{$prefix}button-outlined-background-color,
142
- $button-outlined-background-color
143
- );
144
- border-color: var(--#{$prefix}variant-#{$name}, $color);
145
- color: var(--#{$prefix}variant-#{$name}, $color);
114
+ border-color: transparent;
115
+ background-color: var(--#{$prefix}variant-#{$name}, $color);
116
+ color: var(--#{$prefix}variant-invert-#{$name}, $color-invert);
146
117
 
118
+ &:hover {
119
+ /* background-color: darken($color, 2.5%)*/
120
+ /* IE 11 needs polyfill*/
121
+ filter: brightness(97.5%);
122
+ }
123
+ }
124
+ }
125
+
126
+ &--outlined {
147
127
  &:focus,
148
128
  &:hover {
149
- border-color: transparent;
150
- background-color: var(--#{$prefix}variant-#{$name}, $color);
151
- color: var(--#{$prefix}variant-invert-#{$name}, $color-invert);
129
+ background-color: var(
130
+ --#{$prefix}button-border-color,
131
+ $button-border-color
132
+ );
133
+ color: var(--#{$prefix}button-color, $button-color);
134
+ }
135
+
136
+ @each $name, $pair in $colors {
137
+ $color: list.nth($pair, 1);
138
+ $color-invert: list.nth($pair, 2);
139
+
140
+ &-#{$name} {
141
+ --#{$prefix}focus: #{createFocus($color)};
142
+
143
+ background-color: var(
144
+ --#{$prefix}button-outlined-background-color,
145
+ $button-outlined-background-color
146
+ );
147
+ border-color: var(--#{$prefix}variant-#{$name}, $color);
148
+ color: var(--#{$prefix}variant-#{$name}, $color);
149
+
150
+ &:focus,
151
+ &:hover {
152
+ border-color: transparent;
153
+ background-color: var(--#{$prefix}variant-#{$name}, $color);
154
+ color: var(
155
+ --#{$prefix}variant-invert-#{$name},
156
+ $color-invert
157
+ );
158
+ }
159
+ }
152
160
  }
153
- }
154
161
  }
155
- }
156
162
 
157
- &--inverted {
158
- background-color: var(--#{$prefix}button-color, $button-color);
159
- border-color: var(--#{$prefix}button-color, $button-color);
160
- color: var(--#{$prefix}button-border-color, $button-border-color);
163
+ &--inverted {
164
+ background-color: var(--#{$prefix}button-color, $button-color);
165
+ border-color: var(--#{$prefix}button-color, $button-color);
166
+ color: var(--#{$prefix}button-border-color, $button-border-color);
161
167
 
162
- &:hover {
163
- /* background-color: darken($color-invert, 5%)*/
164
- /* IE 11 needs polyfill*/
165
- filter: brightness(95%);
168
+ &:hover {
169
+ /* background-color: darken($color-invert, 5%)*/
170
+ /* IE 11 needs polyfill*/
171
+ filter: brightness(95%);
172
+ }
173
+
174
+ @each $name, $pair in $colors {
175
+ $color: list.nth($pair, 1);
176
+ $color-invert: list.nth($pair, 2);
177
+
178
+ &-#{$name} {
179
+ --#{$prefix}focus: #{createFocus($color)};
180
+
181
+ background-color: var(
182
+ --#{$prefix}variant-invert-#{$name},
183
+ $color-invert
184
+ );
185
+ border-color: var(
186
+ --#{$prefix}variant-invert-#{$name},
187
+ $color-invert
188
+ );
189
+ color: var(--#{$prefix}variant-#{$name}, $color);
190
+
191
+ &:focus,
192
+ &:hover {
193
+ /* background-color: darken($color-invert, 5%)*/
194
+ /* IE 11 needs polyfill*/
195
+ filter: brightness(95%);
196
+ }
197
+ }
198
+ }
166
199
  }
167
200
 
168
- @each $name, $pair in $colors {
169
- $color: list.nth($pair, 1);
170
- $color-invert: list.nth($pair, 2);
201
+ /* focus effect*/
202
+ &:focus,
203
+ &:focus-within {
204
+ box-shadow: 0 0 0 0.25rem var(--#{$prefix}focus);
205
+ outline: 0;
206
+ }
171
207
 
172
- &-#{$name} {
173
- --#{$prefix}focus: #{createFocus($color)};
208
+ &--loading {
209
+ color: transparent !important;
210
+ pointer-events: none;
211
+ }
174
212
 
175
- background-color: var(
176
- --#{$prefix}variant-invert-#{$name},
177
- $color-invert
178
- );
179
- border-color: var(--#{$prefix}variant-invert-#{$name}, $color-invert);
180
- color: var(--#{$prefix}variant-#{$name}, $color);
213
+ &--loading::after {
214
+ -webkit-animation: spinAround 500ms infinite linear;
215
+ left: calc(50% - 0.5em);
216
+ top: calc(50% - 0.5em);
217
+ position: absolute !important;
218
+ border: 2px solid #dbdbdb;
219
+ border-radius: 9999px;
220
+ border-right-color: transparent;
221
+ border-top-color: transparent;
222
+ content: "";
223
+ display: block;
224
+ height: 1em;
225
+ width: 1em;
226
+ }
181
227
 
182
- &:focus,
183
- &:hover {
184
- /* background-color: darken($color-invert, 5%)*/
185
- /* IE 11 needs polyfill*/
186
- filter: brightness(95%);
187
- }
188
- }
228
+ .o-icon:not(:last-child) {
229
+ margin-right: var(--#{$prefix}button-spacer, $button-spacer);
189
230
  }
190
- }
191
-
192
- /* focus effect*/
193
- &:focus,
194
- &:focus-within {
195
- box-shadow: 0 0 0 0.25rem var(--#{$prefix}focus);
196
- outline: 0;
197
- }
198
-
199
- &--loading {
200
- color: transparent !important;
201
- pointer-events: none;
202
- }
203
-
204
- &--loading::after {
205
- -webkit-animation: spinAround 500ms infinite linear;
206
- left: calc(50% - 0.5em);
207
- top: calc(50% - 0.5em);
208
- position: absolute !important;
209
- border: 2px solid #dbdbdb;
210
- border-radius: 9999px;
211
- border-right-color: transparent;
212
- border-top-color: transparent;
213
- content: "";
214
- display: block;
215
- height: 1em;
216
- width: 1em;
217
- }
218
-
219
- .o-icon:not(:last-child) {
220
- margin-right: var(--#{$prefix}button-spacer, $button-spacer);
221
- }
222
231
  }