Last active
April 7, 2019 20:52
-
-
Save VFDan/79f98e887eb8beaba1b1baba291f4993 to your computer and use it in GitHub Desktop.
A LESS function to add emphasis, and also an if operator.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.if(@condition, @property, @value) when (@condition = true){ | |
@{property}: @value; | |
} | |
.emphasis(@bold: false, @italic: false, @underline: false, @overline: false){ | |
.if(@bold, font-weight, bold); | |
.if(@italic, font-style, italic); | |
.if(@underline, text-decoration, underline); | |
.if(@overline, text-decoration, overline); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment