Skip to content

Instantly share code, notes, and snippets.

@jasonhodges
Created January 14, 2014 19:06
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 jasonhodges/8423871 to your computer and use it in GitHub Desktop.
Save jasonhodges/8423871 to your computer and use it in GitHub Desktop.
Sass media query break-point mixins
@mixin bplowerthan($point){
@media all and (max-width: $point){
@content;
}
}
@mixin bphigherthan($point){
@media all and (min-width: $point){
@content;
}
}
@mixin bprange($point-from, $point-to){
@media all and (min-width: $point-from) and (max-width: $point-to){
@content;
}
}
@mixin tinyport{
@media screen and (max-width: 320px) and (orientation:portrait){
@content;
}
}
//example
.example{
max-height: 50px;
@include bplowerthan(940px){
max-height: 35px;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment