Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save mattdanielbrown/a4fdea9a4c08217afe5eadeceafbad5d to your computer and use it in GitHub Desktop.
Save mattdanielbrown/a4fdea9a4c08217afe5eadeceafbad5d to your computer and use it in GitHub Desktop.
@mixin for-phone-only {
@media (max-width: 599px) { @content; }
}
@mixin for-tablet-portrait-up {
@media (min-width: 600px) { @content; }
}
@mixin for-tablet-landscape-up {
@media (min-width: 900px) { @content; }
}
@mixin for-desktop-up {
@media (min-width: 1200px) { @content; }
}
@mixin for-big-desktop-up {
@media (min-width: 1800px) { @content; }
}
// usage
.my-box {
padding: 10px;
@include for-desktop-up {
padding: 20px;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment