Skip to content

Instantly share code, notes, and snippets.

@lunelson
Last active December 16, 2015 19:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lunelson/5487365 to your computer and use it in GitHub Desktop.
Save lunelson/5487365 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com, the Sass playground.
// HTML5 section-heading outline style generation
// not actually the right way of dealing with doc outline but just a test
$heading-font-sizes: 12px 14px 16px 20px 24px 30px;
$s: h1;
@for $n from 0 through 5 {
#{$s} { font-size: nth($heading-font-sizes, length($heading-font-sizes) - $n); }
$s: append((section), $s);
}
h1 {
font-size: 30px;
}
section h1 {
font-size: 24px;
}
section section h1 {
font-size: 20px;
}
section section section h1 {
font-size: 16px;
}
section section section section h1 {
font-size: 14px;
}
section section section section section h1 {
font-size: 12px;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment