Skip to content

Instantly share code, notes, and snippets.

@pfulton
Created February 13, 2013 21:40
Show Gist options
  • Save pfulton/4948580 to your computer and use it in GitHub Desktop.
Save pfulton/4948580 to your computer and use it in GitHub Desktop.
Compass has a "headings" helper, but based on the docs, figuring out the syntax for it is a little difficult. Here's a quick example of the SCSS and its compiled result. This comes in handy more often than you'd think ;-)
h1, h2, h3, h4, h5, h6 {
text-transform: uppercase;
}
h1, h2, h3 {
font-family: Arial;
font-weight: bold;
margin-bottom: 0.35em;
color: #474747;
}
h1, h2 {
font-style: underline;
}
#{headings(all)}{
text-transform: uppercase;
}
#{headings(1,3)}{
font-family: Arial;
font-weight: bold;
margin-bottom: 0.35em;
color: #474747;
}
#{headings(2)}{
font-style: underline;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment