@siemens/element-theme 51.0.0-rc.6 → 51.0.0-rc.8

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 (54) hide show
  1. package/package.json +1 -1
  2. package/src/styles/_accessibility.scss +4 -2
  3. package/src/styles/_density.scss +144 -0
  4. package/src/styles/_reboot-shadow-dom.scss +5 -0
  5. package/src/styles/_root-font-size.scss +4 -2
  6. package/src/styles/_selectors.scss +3 -0
  7. package/src/styles/_themes.scss +15 -3
  8. package/src/styles/_utilities.scss +5 -0
  9. package/src/styles/_variables.scss +1 -0
  10. package/src/styles/bootstrap/_badges.scss +3 -3
  11. package/src/styles/bootstrap/_button-group.scss +3 -3
  12. package/src/styles/bootstrap/_buttons.scss +2 -3
  13. package/src/styles/bootstrap/_card.scss +18 -11
  14. package/src/styles/bootstrap/_dropdowns.scss +12 -12
  15. package/src/styles/bootstrap/_images.scss +2 -1
  16. package/src/styles/bootstrap/_modals.scss +8 -8
  17. package/src/styles/bootstrap/_nav.scss +10 -1
  18. package/src/styles/bootstrap/_pagination.scss +3 -3
  19. package/src/styles/bootstrap/_popovers.scss +1 -1
  20. package/src/styles/bootstrap/_reboot.scss +9 -3
  21. package/src/styles/bootstrap/_root.scss +2 -1
  22. package/src/styles/bootstrap/_tables.scss +8 -6
  23. package/src/styles/bootstrap/_type.scss +129 -3
  24. package/src/styles/bootstrap/_utilities.scss +40 -45
  25. package/src/styles/bootstrap/_variables.scss +63 -58
  26. package/src/styles/bootstrap/forms/_form-check.scss +13 -11
  27. package/src/styles/bootstrap/forms/_form-control.scss +19 -13
  28. package/src/styles/bootstrap/forms/_form-file.scss +2 -2
  29. package/src/styles/bootstrap/forms/_form-label.scss +1 -1
  30. package/src/styles/bootstrap/forms/_form-layout.scss +36 -0
  31. package/src/styles/bootstrap/forms/_validation.scss +2 -2
  32. package/src/styles/bootstrap/mixins/_badge-text.scss +2 -2
  33. package/src/styles/bootstrap/mixins/_form-layout.scss +7 -5
  34. package/src/styles/bootstrap/mixins/_grid.scss +3 -3
  35. package/src/styles/bootstrap/mixins/_utilities.scss +14 -3
  36. package/src/styles/components/_application-header.scss +8 -8
  37. package/src/styles/components/_datatable.scss +38 -27
  38. package/src/styles/components/_drag_drop.scss +2 -1
  39. package/src/styles/components/_layout.scss +12 -12
  40. package/src/styles/components/_list-item.scss +47 -17
  41. package/src/styles/components/_markdown.scss +8 -8
  42. package/src/styles/components/_pills.scss +3 -3
  43. package/src/styles/components/_scrollbar.scss +2 -1
  44. package/src/styles/components/_search-bar.scss +67 -0
  45. package/src/styles/components/_switch.scss +4 -4
  46. package/src/styles/components/_widgets.scss +9 -7
  47. package/src/styles/mixins/_utilities.scss +259 -0
  48. package/src/styles/variables/_si-vars.scss +13 -7
  49. package/src/styles/variables/_sizing.scss +22 -0
  50. package/src/styles/variables/_spacers.scss +53 -25
  51. package/src/styles/variables/_typography.scss +108 -40
  52. package/src/styles/variables/_utilities.scss +56 -51
  53. package/src/theme-shadow-dom.scss +17 -0
  54. package/src/theme.scss +14 -3
@@ -1,9 +1,10 @@
1
1
  @use './variables';
2
+ @use '../selectors';
2
3
 
3
4
  @use 'sass:meta';
4
5
 
5
6
  // this is _root.scss without the automatic `to-rgb` brain damage
6
- :root {
7
+ #{selectors.$root} {
7
8
  // Note: Use `inspect` for lists so that quoted items keep the quotes.
8
9
  // See https://github.com/sass/sass/issues/2383#issuecomment-336349172
9
10
  --#{variables.$variable-prefix}font-sans-serif: #{meta.inspect(variables.$font-family-sans-serif)};
@@ -18,7 +18,7 @@
18
18
  --#{variables.$variable-prefix}table-hover-bg: #{variables.$table-hover-bg};
19
19
 
20
20
  inline-size: 100%;
21
- margin-block-end: spacers.$spacer;
21
+ margin-block-end: map.get(spacers.$spacers-block, 6);
22
22
  color: variables.$table-color;
23
23
  vertical-align: variables.$table-cell-vertical-align;
24
24
  border-color: variables.$table-border-color;
@@ -55,17 +55,17 @@
55
55
  vertical-align: middle;
56
56
 
57
57
  &:first-child {
58
- padding-inline-start: map.get(spacers.$spacers, 6);
58
+ padding-inline-start: map.get(spacers.$spacers-inline, 6);
59
59
  }
60
60
 
61
61
  &:last-child {
62
- padding-inline-end: map.get(spacers.$spacers, 6);
62
+ padding-inline-end: map.get(spacers.$spacers-inline, 6);
63
63
  }
64
64
  }
65
65
 
66
66
  thead {
67
67
  border-width: 0;
68
- border-block-end: map.get(spacers.$spacers, 2) solid variables.$table-border-color;
68
+ border-block-end: map.get(spacers.$spacers-block, 2) solid variables.$table-border-color;
69
69
 
70
70
  th {
71
71
  vertical-align: baseline;
@@ -96,7 +96,9 @@
96
96
  }
97
97
 
98
98
  :is(th, td) {
99
- block-size: calc(2lh + 2 * map.get(spacers.$spacers, 2) + 2 * map.get(spacers.$spacers, 5));
99
+ block-size: calc(
100
+ 2lh + 2 * map.get(spacers.$spacers-block, 2) + 2 * map.get(spacers.$spacers-block, 5)
101
+ );
100
102
  }
101
103
  }
102
104
  }
@@ -118,7 +120,7 @@
118
120
 
119
121
  tbody {
120
122
  :is(th, td) {
121
- block-size: calc(2lh + 2 * map.get(spacers.$spacers, 4));
123
+ block-size: calc(2lh + 2 * map.get(spacers.$spacers-block, 4));
122
124
  }
123
125
  }
124
126
  }
@@ -93,7 +93,7 @@
93
93
  }
94
94
 
95
95
  .blockquote-footer {
96
- margin-block: -(variables.$blockquote-margin-y) variables.$blockquote-margin-y;
96
+ margin-block: calc(variables.$blockquote-margin-y * -1) variables.$blockquote-margin-y;
97
97
  font-size: variables.$blockquote-footer-font-size;
98
98
  color: variables.$blockquote-footer-color;
99
99
 
@@ -167,9 +167,7 @@ h4,
167
167
  }
168
168
 
169
169
  h5,
170
- h6,
171
170
  .h5,
172
- .h6,
173
171
  .si-h5 {
174
172
  @include typography.si-font(
175
173
  typography.$si-font-size-h5,
@@ -178,6 +176,16 @@ h6,
178
176
  );
179
177
  }
180
178
 
179
+ h6,
180
+ .h6,
181
+ .si-h6 {
182
+ @include typography.si-font(
183
+ typography.$si-font-size-h6,
184
+ typography.$si-line-height-h6,
185
+ typography.$si-font-weight-h6
186
+ );
187
+ }
188
+
181
189
  .si-body-lg {
182
190
  @include typography.si-font(
183
191
  typography.$si-font-size-body-lg,
@@ -186,6 +194,14 @@ h6,
186
194
  );
187
195
  }
188
196
 
197
+ .si-body-lg-sbold {
198
+ @include typography.si-font(
199
+ typography.$si-font-size-body-lg-sbold,
200
+ typography.$si-line-height-body-lg-sbold,
201
+ typography.$si-font-weight-body-lg-sbold
202
+ );
203
+ }
204
+
189
205
  .si-body {
190
206
  @include typography.si-font(
191
207
  typography.$si-font-size-body,
@@ -194,6 +210,46 @@ h6,
194
210
  );
195
211
  }
196
212
 
213
+ .si-body-sbold {
214
+ @include typography.si-font(
215
+ typography.$si-font-size-body-sbold,
216
+ typography.$si-line-height-body-sbold,
217
+ typography.$si-font-weight-body-sbold
218
+ );
219
+ }
220
+
221
+ .si-body-paragraph {
222
+ @include typography.si-font(
223
+ typography.$si-font-size-body-paragraph,
224
+ typography.$si-line-height-body-paragraph,
225
+ typography.$si-font-weight-body-paragraph
226
+ );
227
+ }
228
+
229
+ .si-body-paragraph-sbold {
230
+ @include typography.si-font(
231
+ typography.$si-font-size-body-paragraph-sbold,
232
+ typography.$si-line-height-body-paragraph-sbold,
233
+ typography.$si-font-weight-body-paragraph-sbold
234
+ );
235
+ }
236
+
237
+ .si-body-sm {
238
+ @include typography.si-font(
239
+ typography.$si-font-size-body-sm,
240
+ typography.$si-line-height-body-sm,
241
+ typography.$si-font-weight-body-sm
242
+ );
243
+ }
244
+
245
+ .si-body-sm-sbold {
246
+ @include typography.si-font(
247
+ typography.$si-font-size-body-sm-sbold,
248
+ typography.$si-line-height-body-sm-sbold,
249
+ typography.$si-font-weight-body-sm-sbold
250
+ );
251
+ }
252
+
197
253
  .si-caption {
198
254
  @include typography.si-font(
199
255
  typography.$si-font-size-caption,
@@ -211,6 +267,30 @@ h6,
211
267
  );
212
268
  }
213
269
 
270
+ .si-display-xl-sbold {
271
+ @include typography.si-font(
272
+ typography.$si-font-size-display-xl-sbold,
273
+ typography.$si-line-height-display-xl-sbold,
274
+ typography.$si-font-weight-display-xl-sbold
275
+ );
276
+ }
277
+
278
+ .si-display-xxl {
279
+ @include typography.si-font(
280
+ typography.$si-font-size-display-xxl,
281
+ typography.$si-line-height-display-xxl,
282
+ typography.$si-font-weight-display-xxl
283
+ );
284
+ }
285
+
286
+ .si-display-xxl-sbold {
287
+ @include typography.si-font(
288
+ typography.$si-font-size-display-xxl-sbold,
289
+ typography.$si-line-height-display-xxl-sbold,
290
+ typography.$si-font-weight-display-xxl-sbold
291
+ );
292
+ }
293
+
214
294
  .si-display-lg,
215
295
  .display-2 {
216
296
  @include typography.si-font(
@@ -220,6 +300,14 @@ h6,
220
300
  );
221
301
  }
222
302
 
303
+ .si-display-lg-sbold {
304
+ @include typography.si-font(
305
+ typography.$si-font-size-display-lg-sbold,
306
+ typography.$si-line-height-display-lg-sbold,
307
+ typography.$si-font-weight-display-lg-sbold
308
+ );
309
+ }
310
+
223
311
  .si-display-bold,
224
312
  .display-3 {
225
313
  @include typography.si-font(
@@ -229,6 +317,14 @@ h6,
229
317
  );
230
318
  }
231
319
 
320
+ .si-display-sbold {
321
+ @include typography.si-font(
322
+ typography.$si-font-size-display-sbold,
323
+ typography.$si-line-height-display-sbold,
324
+ typography.$si-font-weight-display-sbold
325
+ );
326
+ }
327
+
232
328
  .si-display,
233
329
  .display-4 {
234
330
  @include typography.si-font(
@@ -238,6 +334,36 @@ h6,
238
334
  );
239
335
  }
240
336
 
337
+ .si-code-sm,
338
+ .si-code,
339
+ .si-code-lg {
340
+ font-family: typography.$si-font-family-mono;
341
+ }
342
+
343
+ .si-code-sm {
344
+ @include typography.si-font(
345
+ typography.$si-font-size-code-sm,
346
+ typography.$si-line-height-code-sm,
347
+ typography.$si-font-weight-code-sm
348
+ );
349
+ }
350
+
351
+ .si-code {
352
+ @include typography.si-font(
353
+ typography.$si-font-size-code,
354
+ typography.$si-line-height-code,
355
+ typography.$si-font-weight-code
356
+ );
357
+ }
358
+
359
+ .si-code-lg {
360
+ @include typography.si-font(
361
+ typography.$si-font-size-code-lg,
362
+ typography.$si-line-height-code-lg,
363
+ typography.$si-font-weight-code-lg
364
+ );
365
+ }
366
+
241
367
  .text-pre {
242
368
  white-space: pre;
243
369
  }
@@ -1,4 +1,4 @@
1
- @use '../variables/semantic-tokens';
1
+ @use '../variables/system-tokens';
2
2
  @use '../variables/utilities' as variables-utilities;
3
3
  @use 'mixins/breakpoints';
4
4
  @use 'mixins/utilities' as mixins-utilities;
@@ -35,18 +35,12 @@
35
35
  }
36
36
  }
37
37
 
38
+ // Deprecated legacy utilities. Use system-token text utilities instead.
38
39
  $text-colors: (
39
- 'primary': semantic-tokens.$element-text-active,
40
- 'body': semantic-tokens.$element-text-primary,
41
- 'secondary': semantic-tokens.$element-text-secondary,
42
- 'tertiary': semantic-tokens.$element-text-disabled,
43
- 'success': semantic-tokens.$element-text-success,
44
- 'info': semantic-tokens.$element-text-information,
45
- 'warning': semantic-tokens.$element-text-warning,
46
- 'caution': semantic-tokens.$element-text-caution,
47
- 'danger': semantic-tokens.$element-text-danger,
48
- 'inverse': semantic-tokens.$element-text-inverse,
49
- 'muted': semantic-tokens.$element-text-disabled
40
+ 'body': system-tokens.$si-sys-text-primary,
41
+ 'tertiary': system-tokens.$si-sys-text-disabled,
42
+ 'info': system-tokens.$si-sys-text-information,
43
+ 'muted': system-tokens.$si-sys-text-disabled
50
44
  ) !default;
51
45
 
52
46
  @each $color, $value in $text-colors {
@@ -55,27 +49,28 @@ $text-colors: (
55
49
  }
56
50
  }
57
51
 
52
+ // Deprecated legacy utilities. Use system-token background utilities instead.
58
53
  $background-colors: (
59
- 'primary': semantic-tokens.$element-ui-0,
60
- 'secondary': semantic-tokens.$element-text-secondary,
61
- 'tertiary': semantic-tokens.$element-text-disabled,
62
- 'success': semantic-tokens.$element-status-success,
63
- 'info': semantic-tokens.$element-status-information,
64
- 'warning': semantic-tokens.$element-status-warning,
65
- 'danger': semantic-tokens.$element-status-danger,
66
- 'base-0': semantic-tokens.$element-base-0,
67
- 'base-1': semantic-tokens.$element-base-1,
68
- 'base-2': semantic-tokens.$element-base-2,
69
- 'base-3': semantic-tokens.$element-base-3,
70
- 'base-4': semantic-tokens.$element-base-4,
71
- 'base-success': semantic-tokens.$element-base-success,
72
- 'base-info': semantic-tokens.$element-base-information,
73
- 'base-caution': semantic-tokens.$element-base-caution,
74
- 'base-warning': semantic-tokens.$element-base-warning,
75
- 'base-danger': semantic-tokens.$element-base-danger,
76
- 'base-critical': semantic-tokens.$element-base-critical,
77
- 'base-translucent-1': semantic-tokens.$element-base-translucent-1,
78
- 'base-translucent-2': semantic-tokens.$element-base-translucent-2
54
+ 'primary': system-tokens.$si-sys-background-accent,
55
+ 'secondary': system-tokens.$si-sys-text-secondary,
56
+ 'tertiary': system-tokens.$si-sys-text-disabled,
57
+ 'success': system-tokens.$si-sys-background-success,
58
+ 'info': system-tokens.$si-sys-background-information,
59
+ 'warning': system-tokens.$si-sys-background-warning,
60
+ 'danger': system-tokens.$si-sys-background-danger,
61
+ 'base-0': system-tokens.$si-sys-background-0,
62
+ 'base-1': system-tokens.$si-sys-background-1,
63
+ 'base-2': system-tokens.$si-sys-background-2,
64
+ 'base-3': system-tokens.$si-sys-background-3,
65
+ 'base-4': system-tokens.$si-sys-background-4,
66
+ 'base-success': system-tokens.$si-sys-background-success-subtle,
67
+ 'base-info': system-tokens.$si-sys-background-information-subtle,
68
+ 'base-caution': system-tokens.$si-sys-background-caution-subtle,
69
+ 'base-warning': system-tokens.$si-sys-background-warning-subtle,
70
+ 'base-danger': system-tokens.$si-sys-background-danger-subtle,
71
+ 'base-critical': system-tokens.$si-sys-background-critical-subtle,
72
+ 'base-translucent-1': system-tokens.$si-sys-effects-backdrop,
73
+ 'base-translucent-2': system-tokens.$si-sys-background-inverse
79
74
  ) !default;
80
75
 
81
76
  @each $color, $value in $background-colors {
@@ -85,19 +80,19 @@ $background-colors: (
85
80
  }
86
81
 
87
82
  $status-colors: (
88
- 'success': semantic-tokens.$element-status-success,
89
- 'info': semantic-tokens.$element-status-information,
90
- 'caution': semantic-tokens.$element-status-caution,
91
- 'warning': semantic-tokens.$element-status-warning,
92
- 'danger': semantic-tokens.$element-status-danger,
93
- 'critical': semantic-tokens.$element-status-critical,
94
- 'neutral': semantic-tokens.$element-ui-4,
95
- 'success-contrast': semantic-tokens.$element-status-success-contrast,
96
- 'info-contrast': semantic-tokens.$element-status-information-contrast,
97
- 'caution-contrast': semantic-tokens.$element-status-caution-contrast,
98
- 'warning-contrast': semantic-tokens.$element-status-warning-contrast,
99
- 'danger-contrast': semantic-tokens.$element-status-danger-contrast,
100
- 'critical-contrast': semantic-tokens.$element-status-critical-contrast
83
+ 'success': system-tokens.$si-sys-background-success,
84
+ 'info': system-tokens.$si-sys-background-information,
85
+ 'caution': system-tokens.$si-sys-background-caution,
86
+ 'warning': system-tokens.$si-sys-background-warning,
87
+ 'danger': system-tokens.$si-sys-background-danger,
88
+ 'critical': system-tokens.$si-sys-background-critical,
89
+ 'neutral': system-tokens.$si-sys-background-neutral,
90
+ 'success-contrast': system-tokens.$si-sys-text-on-success,
91
+ 'info-contrast': system-tokens.$si-sys-text-on-information,
92
+ 'caution-contrast': system-tokens.$si-sys-text-on-caution,
93
+ 'warning-contrast': system-tokens.$si-sys-text-on-warning,
94
+ 'danger-contrast': system-tokens.$si-sys-text-on-danger,
95
+ 'critical-contrast': system-tokens.$si-sys-text-on-critical
101
96
  ) !default;
102
97
 
103
98
  @each $color, $value in $status-colors {