Created
March 10, 2014 13:03
-
-
Save certainlyakey/9464611 to your computer and use it in GitHub Desktop.
Slanted text highlight (marker-like) effect SASS mixin
This file contains 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
//Adapted for non-italic 13px Arial text | |
@mixin slanted-highlight($bgcolor, $element: span) { | |
#{$element} {background:$bgcolor;} | |
#{$element}:before {border-bottom:15px solid $bgcolor; border-left:4px solid transparent; content:""; display:inline-block; height:0; left:-4px; top:3px; width:0; position:relative;} | |
#{$element}:after {border-top:15px solid $bgcolor; border-right:4px solid transparent; content:""; display:inline-block; height:0; left:4px; top:3px; width:0; position:relative;} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment