♻️ refactor: generate-typo-class updated
This commit is contained in:
parent
6274d4d814
commit
03e117b77e
|
@ -13,22 +13,24 @@
|
|||
}
|
||||
|
||||
// Mixin to generate typography css classes
|
||||
@mixin generate-typo-class($map) {
|
||||
@each $name, $value in $map {
|
||||
@if $name == "family" {
|
||||
font-family: $value;
|
||||
} @else if $name == "size" {
|
||||
font-size: $value;
|
||||
} @else if $name == "weight" {
|
||||
font-weight: $value;
|
||||
} @else if $name == "line-height" {
|
||||
line-height: $value;
|
||||
} @else if $name == "style" {
|
||||
font-style: $value;
|
||||
} @else if $name == "text-transform" {
|
||||
text-transform: $value;
|
||||
} @else if $name == "text-decoration" {
|
||||
text-decoration: $value;
|
||||
@mixin generate-typo-class($prefix, $name, $map) {
|
||||
.#{$prefix}-#{$name} {
|
||||
@each $key, $value in $map {
|
||||
@if $key == "family" {
|
||||
font-family: $value;
|
||||
} @else if $key == "size" {
|
||||
font-size: $value;
|
||||
} @else if $key == "weight" {
|
||||
font-weight: $value;
|
||||
} @else if $key == "line-height" {
|
||||
line-height: $value;
|
||||
} @else if $key == "style" {
|
||||
font-style: $value;
|
||||
} @else if $key == "text-transform" {
|
||||
text-transform: $value;
|
||||
} @else if $key == "text-decoration" {
|
||||
text-decoration: $value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user