Skip to content

Instantly share code, notes, and snippets.

@jruz
Created July 8, 2014 11:12
Show Gist options
  • Save jruz/e7a45d3c77c0531fb4ce to your computer and use it in GitHub Desktop.
Save jruz/e7a45d3c77c0531fb4ce to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
// ----
// Sass (v3.3.9)
// Compass (v1.0.0.alpha.20)
// ----
$class-name: percent !default;
$percent-numbers: "50", "33", "25", "20", "16.6";
$i: 1;
@each $percent-number in $percent-numbers {
.#{$class-name}-#{$i} {
width: $percent-number + '%';
}
$i: $i + 1;
}
.percent-1 {
width: "50%";
}
.percent-2 {
width: "33%";
}
.percent-3 {
width: "25%";
}
.percent-4 {
width: "20%";
}
.percent-5 {
width: "16.6%";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment