Skip to content

Instantly share code, notes, and snippets.

@MichaelArestad
Created March 3, 2015 19:12
Show Gist options
  • Save MichaelArestad/20f11687e4abc10e008f to your computer and use it in GitHub Desktop.
Save MichaelArestad/20f11687e4abc10e008f to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
// ----
// Sass (v3.4.12)
// Compass (v1.0.3)
// ----
$scheme-one:(
primary: red,
secondary: blue,
tertiary: green
);
$scheme-two:(
primary: #fff,
secondary: #ff0000,
tertiary: #222
);
@mixin colors( $colors ) {
$c-primary: map-get( $colors, primary ) !global;
$c-secondary: map-get( $colors, secondary ) !global;
$c-tertiary: map-get( $colors, tertiary ) !global;
}
@include colors( $scheme-one );
.scheme-one {
primary: $c-primary;
secondary: $c-secondary;
tertiary: $c-tertiary;
}
@include colors( $scheme-two );
.scheme-two {
primary: $c-primary;
secondary: $c-secondary;
tertiary: $c-tertiary;
}
.scheme-one {
primary: red;
secondary: blue;
tertiary: green;
}
.scheme-two {
primary: #fff;
secondary: #ff0000;
tertiary: #222;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment