summaryrefslogtreecommitdiffstats
path: root/src/scopes/_headings.scss
diff options
context:
space:
mode:
Diffstat (limited to 'src/scopes/_headings.scss')
-rw-r--r--src/scopes/_headings.scss27
1 files changed, 25 insertions, 2 deletions
diff --git a/src/scopes/_headings.scss b/src/scopes/_headings.scss
index 7a9f088..362b116 100644
--- a/src/scopes/_headings.scss
+++ b/src/scopes/_headings.scss
@@ -1,4 +1,5 @@
1@use 'sass:map'; 1@use 'sass:map';
2@use 'sass:string';
2@use 'iro-sass/src/bem'; 3@use 'iro-sass/src/bem';
3@use 'iro-sass/src/props'; 4@use 'iro-sass/src/props';
4@use '../objects/heading.vars' as heading; 5@use '../objects/heading.vars' as heading;
@@ -40,30 +41,52 @@
40 transparent .6em); 41 transparent .6em);
41 } 42 }
42 43
43 @each $mod, $font-family, $line-height, $font-size, $font-weight, $letter-spacing, $feature-settings, $text-transform in heading.$sizes { 44 @each $mod, $font-family, $line-height, $font-size, $font-weight, $letter-spacing, $feature-settings, $text-transform, $text-color in heading.$sizes {
44 #{map.get($-size-map, $mod)} { 45 #{map.get($-size-map, $mod)} {
45 font-family: props.get($font-family); 46 font-family: props.get($font-family);
46 font-size: props.get($font-size); 47 font-size: props.get($font-size);
47 font-weight: props.get($font-weight); 48 font-weight: props.get($font-weight);
48 font-feature-settings: props.get($feature-settings); 49 font-feature-settings: props.get($feature-settings);
49 line-height: props.get($line-height); 50 line-height: props.get($line-height);
51 color: props.get($text-color);
50 text-transform: props.get($text-transform); 52 text-transform: props.get($text-transform);
51 letter-spacing: props.get($letter-spacing); 53 letter-spacing: props.get($letter-spacing);
52 } 54 }
53 } 55 }
54 56
55 @include bem.modifier('display') { 57 @include bem.modifier('display') {
56 @each $mod, $font-family, $line-height, $font-size, $font-weight, $letter-spacing, $feature-settings, $text-transform in heading.$display--sizes { 58 @each $mod, $font-family, $line-height, $font-size, $font-weight, $letter-spacing, $feature-settings, $text-transform, $text-color in heading.$display--sizes {
57 #{map.get($-size-map, $mod)} { 59 #{map.get($-size-map, $mod)} {
58 font-family: props.get($font-family); 60 font-family: props.get($font-family);
59 font-size: props.get($font-size); 61 font-size: props.get($font-size);
60 font-weight: props.get($font-weight); 62 font-weight: props.get($font-weight);
61 font-feature-settings: props.get($feature-settings); 63 font-feature-settings: props.get($feature-settings);
62 line-height: props.get($line-height); 64 line-height: props.get($line-height);
65 color: props.get($text-color);
63 text-transform: props.get($text-transform); 66 text-transform: props.get($text-transform);
64 letter-spacing: props.get($letter-spacing); 67 letter-spacing: props.get($letter-spacing);
65 } 68 }
66 } 69 }
67 } 70 }
71
72 @each $theme in map.keys(props.get(heading.$static-themes)) {
73 @include bem.modifier(string.slice($theme, 3)) {
74 color: props.get(heading.$static-themes, $theme, --text-color);
75
76 @each $mod, $value in heading.$sizes {
77 #{map.get($-size-map, $mod)} {
78 color: props.get(heading.$static-themes, $theme, --#{$mod}, --text-color);
79 }
80 }
81
82 @include bem.modifier('display') {
83 @each $mod, $value in heading.$sizes {
84 #{map.get($-size-map, $mod)} {
85 color: props.get(heading.$static-themes, $theme, --display, --#{$mod}, --text-color);
86 }
87 }
88 }
89 }
90 }
68 } 91 }
69} 92}