Skip to content

Instantly share code, notes, and snippets.

@quattromani
Created August 26, 2014 01:42
Show Gist options
  • Save quattromani/e9896054262fdbf49243 to your computer and use it in GitHub Desktop.
Save quattromani/e9896054262fdbf49243 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
<span class="icn-toggle"></span>
// ----
// Sass (v3.4.0)
// Compass (v1.0.0)
// ----
// Breakpoints
$bp-big: 68.75em;
$bp-medium: 62em;
$bp-small: 40em;
// Breakpoint
@mixin bp($point) {
@if $point == bp-medium {
@media (max-width: $bp-medium) { @content; }
}
@else if $point == bp-small {
@media (max-width: $bp-small) { @content; }
}
}
// Font Size
@mixin font-size($value, $base: $base-font-size) {
@if $support-legacy {
font-size: $value * 1px;
}
font-size: $value * .1rem;
}
@mixin font-family($font, $size: $base-font-size, $style: normal, $weight: normal) {
font-family: $font,Arial,Sans-Serif;
font-style: $style;
font-weight: $weight;
}
// Typography
// Fonts
$base-font-size: 18;
$base-line-height: 1.443;
// Declare mixin need for px
$support-legacy: true;
// Font Weights
$font-weight-light: 300;
$font-weight-normal: 400;
$font-weight-semibold: 700;
$font-weight-bold: 900;
// Font Families
$base-font: 'OswaldLight', 'Helvetica Neue', Helvetica, Arial, sans-serif;
$arial: Arial, 'Helvetica Neue', Helvetica, sans-serif;
$base-font-alt: $arial;
$arial-bold: 'Arial Rounded MT Bold', 'Helvetica Rounded', Arial, sans-serif;
$heading-font: 'BebasNeueRegular', 'Helvetica Neue', Helvetica, Arial, sans-serif;
$heading-font-alt: 'BebasNeueRegular', 'Helvetica Neue', Helvetica, Arial, sans-serif;
$fontawesome: 'FontAwesome';
$pre: Inconsolata,Monaco,Consolas,'Andale Mono','Bitstream Vera Sans Mono','Courier New',Courier,monospace;
$heading-list: (
h1 42 200 $heading-font,
h2 36 200 $heading-font,
h3 30 700 $heading-font-alt,
h4 24 200 $heading-font,
h5 18 700 $heading-font-alt,
h6 18 100 $heading-font
);
%headings {
clear: inherit;
vertical-align: middle;
line-height: normal;
& + p {
margin-top: 1em;
}
}
// Build Headings
$i: 1;
@each $value in $heading-list {
#{nth($value, 1)},
.#{nth($value, 1)} {
font-family: nth($value, 4);
@include font-size(nth($value, 2));
font-weight: nth($value, 3);
@extend %headings;
@if $i <= 3 {
@include bp(bp-medium) {
@include font-size(nth($value, 2) * .875)
}
@include bp(bp-small) {
@include font-size(nth($value, 2) * .75)
}
}
}
$i: $i + 1 !global;
}
h1,
.h1, h2,
.h2, h3,
.h3, h4,
.h4, h5,
.h5, h6,
.h6 {
clear: inherit;
vertical-align: middle;
line-height: normal;
}
h1 + p,
.h1 + p, h2 + p,
.h2 + p, h3 + p,
.h3 + p, h4 + p,
.h4 + p, h5 + p,
.h5 + p, h6 + p,
.h6 + p {
margin-top: 1em;
}
h1,
.h1 {
font-family: "BebasNeueRegular", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 42px;
font-size: 4.2rem;
font-weight: 200;
}
@media (max-width: 62em) {
h1,
.h1 {
font-size: 36.75px;
font-size: 3.675rem;
}
}
@media (max-width: 40em) {
h1,
.h1 {
font-size: 31.5px;
font-size: 3.15rem;
}
}
h2,
.h2 {
font-family: "BebasNeueRegular", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 36px;
font-size: 3.6rem;
font-weight: 200;
}
@media (max-width: 62em) {
h2,
.h2 {
font-size: 31.5px;
font-size: 3.15rem;
}
}
@media (max-width: 40em) {
h2,
.h2 {
font-size: 27px;
font-size: 2.7rem;
}
}
h3,
.h3 {
font-family: "BebasNeueRegular", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 30px;
font-size: 3rem;
font-weight: 700;
}
@media (max-width: 62em) {
h3,
.h3 {
font-size: 26.25px;
font-size: 2.625rem;
}
}
@media (max-width: 40em) {
h3,
.h3 {
font-size: 22.5px;
font-size: 2.25rem;
}
}
h4,
.h4 {
font-family: "BebasNeueRegular", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 24px;
font-size: 2.4rem;
font-weight: 200;
}
h5,
.h5 {
font-family: "BebasNeueRegular", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 18px;
font-size: 1.8rem;
font-weight: 700;
}
h6,
.h6 {
font-family: "BebasNeueRegular", "Helvetica Neue", Helvetica, Arial, sans-serif;
font-size: 18px;
font-size: 1.8rem;
font-weight: 100;
}
<span class="icn-toggle"></span>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment