Some useful functions
Function to set assets path
.foo {
background-image: image('image.png');
}
@fontface {
src: font('fontfolder/fontfile.eot');
}
.foo {
background-image: url("../assets/images/image.png");
}
@fontface {
src: url("../assets/fonts/fontfolder/fontfile.eot");
}
Black and white opacity shortcut function
.foo--black {
background: black(.5);
}
.foo--white {
background: white(.5);
}
.foo--black {
background: rgba(0, 0, 0, 0.5);
}
.foo--white {
background: rgba(255, 255, 255, 0.5);
}
Named easings to bezier function
.foo {
transition: all .3s ease(in-out-circ);
}
.foo {
transition: all 0.3s cubic-bezier(0.785, 0.135, 0.15, 0.86);
}
.foo {
font-size: em(16px);
width: rem(100);
}
.foo {
font-size: 1em;
width: 6.25rem;
}
.foo {
font-weight: fw(light);
}
.foo {
font-weight: 300;
}
.foo {
background-position: opposite-direction(top right);
}
.foo {
background-position: bottom left;
}