Add the aspect-ratio mixin

This commit is contained in:
Kevin MacMartin 2018-01-09 22:58:27 -05:00
parent 60241d2ed7
commit 6ce7600ff2
2 changed files with 9 additions and 0 deletions

View file

@ -7,6 +7,7 @@
@import "font-awesome/scss/font-awesome.scss";
// Supplementary
@import "mixins/**/*.scss";
@import "sections/**/*.scss";
@import "pages/**/*.scss";

View file

@ -0,0 +1,8 @@
@mixin aspect-ratio($width, $height) {
&:before {
content: "";
display: block;
width: 100%;
padding-top: ($height / $width) * 100%;
}
}