Skip to content

Instantly share code, notes, and snippets.

@BPScott
Created August 12, 2015 09:51
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 BPScott/5c0edab529abe941049c to your computer and use it in GitHub Desktop.
Save BPScott/5c0edab529abe941049c to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
// ----
// libsass (v3.2.5)
// ----
// Sass is really dumb about creating literal backslashes, such as when
// creating codepoints for icon fonts.
// This works in LibSass 3.2 and Ruby Sass 3.4
@mixin icon-content($codepoint) {
content: #{"\"\\"}#{$codepoint + "\""};
}
$icons: (
copy: e604,
more: e600,
unpublish: e601,
);
@each $name, $codepoint in $icons {
.icon-#{$name} { @include icon-content($codepoint); }
}
.icon-copy {
content: "\e604";
}
.icon-more {
content: "\e600";
}
.icon-unpublish {
content: "\e601";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment