-
-
Save mfd/b635e4ca7a6be31f4cbee3959438d5bd to your computer and use it in GitHub Desktop.
Bootstrap Sass Media Query Variables
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//== Media queries breakpoints | |
// Extra small screen / phone | |
$screen-xs: 480px; | |
$screen-xs-min: $screen-xs; | |
// Small screen / tablet | |
$screen-sm: 768px; | |
$screen-sm-min: $screen-sm; | |
// Medium screen / desktop | |
$screen-md: 992px; | |
$screen-md-min: $screen-md; | |
// Large screen / wide desktop | |
$screen-lg: 1200px; | |
$screen-lg-min: $screen-lg; | |
// So media queries don't overlap when required, provide a maximum | |
$screen-xs-max: ($screen-sm-min - 1); | |
$screen-sm-max: ($screen-md-min - 1); | |
$screen-md-max: ($screen-lg-min - 1); | |
$screen: "only screen"; | |
$xs-up: $screen; | |
$xs-only: "#{$screen} and (max-width: #{$screen-xs-max})"; | |
$sm-up: "#{$screen} and (min-width: #{$screen-sm-min})"; | |
$sm-only: "#{$screen} and (min-width: #{$screen-sm-min}) and (max-width: #{$screen-sm-max})"; | |
$md-up: "#{$screen} and (min-width: #{$screen-md-max})"; | |
$md-only: "#{$screen} and (min-width: #{$screen-md-min}) and (max-width: #{$screen-md-max})"; | |
$lg-up: "#{$screen} and (min-width: #{$screen-lg-min})"; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment