@tedi-design-system/core 2.1.0 → 2.2.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/_base.scss +3 -4
- package/_mixins.scss +4 -25
- package/_typography.scss +28 -29
- package/index.css +1 -1
- package/index.scss +1 -0
- package/package.json +5 -5
- package/variables/_dimensional-variables-legacy.scss +1236 -0
- package/variables/_dimensional-variables.scss +1092 -1234
- package/variables/themes/default/font-variables__default.scss +93 -89
- package/variables/themes/rit/font-variables__rit.scss +2 -2
package/_base.scss
CHANGED
|
@@ -14,11 +14,10 @@ html {
|
|
|
14
14
|
|
|
15
15
|
body {
|
|
16
16
|
box-sizing: border-box;
|
|
17
|
+
font-family: var(--family-default);
|
|
18
|
+
font-size: var(--body-regular-size);
|
|
19
|
+
line-height: var(--body-regular-line-height);
|
|
17
20
|
color: var(--general-text-primary);
|
|
18
|
-
|
|
19
|
-
@include mixins.responsive-styles(font-family, family-primary, $exclude: tablet);
|
|
20
|
-
@include mixins.responsive-styles(line-height, body-regular-line-height, $exclude: tablet);
|
|
21
|
-
@include mixins.responsive-styles(font-size, body-regular-size, $exclude: tablet);
|
|
22
21
|
}
|
|
23
22
|
|
|
24
23
|
*,
|
package/_mixins.scss
CHANGED
|
@@ -15,36 +15,15 @@ $breakpoints: (
|
|
|
15
15
|
$result: '';
|
|
16
16
|
|
|
17
17
|
@each $name in $variable-names {
|
|
18
|
-
$
|
|
18
|
+
$prefixed: var(--#{$name});
|
|
19
|
+
$result: #{$result} #{$prefixed};
|
|
19
20
|
}
|
|
20
21
|
|
|
21
22
|
@return $result;
|
|
22
23
|
}
|
|
23
24
|
|
|
24
|
-
@mixin responsive-styles($property, $
|
|
25
|
-
$
|
|
26
|
-
|
|
27
|
-
@if meta.type-of($names) == 'string' {
|
|
28
|
-
$variable-names: (string.slice($names, 1, -1));
|
|
29
|
-
} @else {
|
|
30
|
-
$variable-names: $names;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
& {
|
|
34
|
-
#{$property}: #{construct-variables($variable-names, mobile)};
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
@if $exclude != 'tablet' {
|
|
38
|
-
@media (min-width: map.get($breakpoints, sm)) {
|
|
39
|
-
#{$property}: #{construct-variables($variable-names, tablet)};
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
@if $exclude != 'desktop' {
|
|
44
|
-
@media (min-width: map.get($breakpoints, lg)) {
|
|
45
|
-
#{$property}: #{construct-variables($variable-names, desktop)};
|
|
46
|
-
}
|
|
47
|
-
}
|
|
25
|
+
@mixin responsive-styles($property, $name, $exclude: null) {
|
|
26
|
+
#{$property}: var(--#{$name});
|
|
48
27
|
}
|
|
49
28
|
|
|
50
29
|
@mixin print-grayscale {
|
package/_typography.scss
CHANGED
|
@@ -2,13 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
$headings: (h1, h2, h3, h4, h5, h6);
|
|
4
4
|
|
|
5
|
-
// Mixin for heading styles
|
|
5
|
+
// Mixin for heading styles (simplified variable usage)
|
|
6
6
|
@mixin heading-styles($level) {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
font-size: var(--heading-#{$level}-size);
|
|
8
|
+
font-weight: var(--heading-#{$level}-weight);
|
|
9
|
+
line-height: var(--heading-#{$level}-line-height);
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
+
// Apply heading styles to semantic and utility selectors
|
|
12
13
|
@each $level in $headings {
|
|
13
14
|
#{$level},
|
|
14
15
|
.#{$level},
|
|
@@ -27,57 +28,54 @@ $headings: (h1, h2, h3, h4, h5, h6);
|
|
|
27
28
|
}
|
|
28
29
|
|
|
29
30
|
&--default {
|
|
31
|
+
font-family: var(--family-default);
|
|
32
|
+
font-size: var(--body-regular-size);
|
|
33
|
+
font-weight: var(--body-regular-weight);
|
|
34
|
+
line-height: var(--body-regular-line-height);
|
|
30
35
|
color: var(--general-text-primary);
|
|
31
|
-
|
|
32
|
-
@include mixins.responsive-styles(font-family, family-primary, $exclude: tablet);
|
|
33
|
-
@include mixins.responsive-styles(font-size, body-regular-size, $exclude: tablet);
|
|
34
|
-
@include mixins.responsive-styles(font-weight, body-regular-weight, $exclude: tablet);
|
|
35
|
-
@include mixins.responsive-styles(line-height, body-regular-line-height, $exclude: tablet);
|
|
36
36
|
}
|
|
37
37
|
|
|
38
38
|
&--small {
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
39
|
+
font-size: var(--body-small-regular-size);
|
|
40
|
+
font-weight: var(--body-small-regular-weight);
|
|
41
|
+
line-height: var(--body-small-regular-line-height);
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
|
|
45
45
|
.text-subtitle {
|
|
46
|
+
font-size: var(--heading-subtitle-regular-size);
|
|
47
|
+
font-weight: var(--heading-subtitle-regular-weight);
|
|
48
|
+
line-height: var(--heading-subtitle-regular-line-height);
|
|
46
49
|
text-transform: uppercase;
|
|
47
50
|
|
|
48
|
-
@include mixins.responsive-styles(font-size, heading-subtitle-regular-size, $exclude: tablet);
|
|
49
|
-
@include mixins.responsive-styles(font-weight, heading-subtitle-regular-weight, $exclude: tablet);
|
|
50
|
-
@include mixins.responsive-styles(line-height, heading-subtitle-regular-line-height, $exclude: tablet);
|
|
51
|
-
|
|
52
51
|
&.text-small {
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
52
|
+
font-size: var(--heading-subtitle-small-size);
|
|
53
|
+
font-weight: var(--heading-subtitle-small-weight);
|
|
54
|
+
line-height: var(--heading-subtitle-small-line-height);
|
|
56
55
|
}
|
|
57
56
|
}
|
|
58
57
|
|
|
59
58
|
label {
|
|
59
|
+
line-height: var(--body-regular-line-height);
|
|
60
60
|
color: var(--general-text-secondary);
|
|
61
|
-
|
|
62
|
-
@include mixins.responsive-styles(line-height, body-regular-line-height);
|
|
63
61
|
}
|
|
64
62
|
|
|
65
63
|
.text-normal {
|
|
64
|
+
font-family: var(--family-default);
|
|
65
|
+
font-size: var(--body-regular-size);
|
|
66
|
+
font-weight: var(--body-regular-weight);
|
|
67
|
+
line-height: var(--body-regular-line-height);
|
|
66
68
|
color: var(--general-text-primary);
|
|
67
|
-
|
|
68
|
-
@include mixins.responsive-styles(font-family, family-primary, $exclude: tablet);
|
|
69
|
-
@include mixins.responsive-styles(font-size, body-regular-size, $exclude: tablet);
|
|
70
|
-
@include mixins.responsive-styles(font-weight, body-regular-weight, $exclude: tablet);
|
|
71
|
-
@include mixins.responsive-styles(line-height, body-regular-line-height, $exclude: tablet);
|
|
72
69
|
}
|
|
73
70
|
|
|
74
71
|
small,
|
|
75
72
|
.text-small {
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
73
|
+
font-size: var(--body-small-regular-size);
|
|
74
|
+
font-weight: var(--body-small-regular-weight);
|
|
75
|
+
line-height: var(--body-small-regular-line-height);
|
|
79
76
|
}
|
|
80
77
|
|
|
78
|
+
// Text color variants
|
|
81
79
|
@each $color,
|
|
82
80
|
$var
|
|
83
81
|
in (
|
|
@@ -100,6 +98,7 @@ small,
|
|
|
100
98
|
}
|
|
101
99
|
}
|
|
102
100
|
|
|
101
|
+
// Text utilities
|
|
103
102
|
.text-nowrap {
|
|
104
103
|
white-space: nowrap;
|
|
105
104
|
}
|