Skip to content

Commit

Permalink
Add option to disable outputting glyph classes
Browse files Browse the repository at this point in the history
  • Loading branch information
ediblecode committed Jan 25, 2017
1 parent b5ee1d9 commit 27f2c8c
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
18 changes: 10 additions & 8 deletions src/stylesheets/helpers/_helpers-glyphs.scss
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,16 @@ $glyphs: (
@return unquote('\'#{$codes}\'');
}

/// Output a BEM style glyph selector for each glyph in the map.
/// E.g. .glyph.glyph--bullet { content: '\2022'; }
/// @since 0.1.0
.glyph {
@each $key, $value in $glyphs {
&--#{$key} {
&::before {
content: unquote('\'\\#{$value}\'');
@if $output-glyph-classes {
/// Output a BEM style glyph selector for each glyph in the map.
/// E.g. .glyph.glyph--bullet { content: '\2022'; }
/// @since 0.1.0
.glyph {
@each $key, $value in $glyphs {
&--#{$key} {
&::before {
content: unquote('\'\\#{$value}\'');
}
}
}
}
Expand Down
4 changes: 4 additions & 0 deletions src/stylesheets/settings/_settings-variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ $mq-breakpoints: ();
/// @since 0.1.0
$output-default-print-styles: true !default;

/// Whether to output the classes for the UTF-8 glyphs.
/// @since 0.2.0
$output-glyph-classes: false !default;

/// Whether the site is responsive. Setting to false will disable
/// generation of the responsie grid selectors.
/// True by default.
Expand Down

0 comments on commit 27f2c8c

Please sign in to comment.