mirror of
https://github.com/twbs/bootstrap.git
synced 2024-11-29 11:24:18 +01:00
11a574ce9e
Thanks to @glebm for help refactoring this to use the breakpoint mixins.
70 lines
1.6 KiB
SCSS
70 lines
1.6 KiB
SCSS
//
|
|
// Responsive: Utility classes
|
|
// --------------------------------------------------
|
|
|
|
@each $bp in map-keys($grid-breakpoints) {
|
|
.hidden-#{$bp}-up {
|
|
@include media-breakpoint-up($bp) {
|
|
display: none !important;
|
|
}
|
|
}
|
|
.hidden-#{$bp}-down {
|
|
@include media-breakpoint-down($bp) {
|
|
display: none !important;
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
// IE10 in Windows (Phone) 8
|
|
//
|
|
// Support for responsive views via media queries is kind of borked in IE10, for
|
|
// Surface/desktop in split view and for Windows Phone 8. This particular fix
|
|
// must be accompanied by a snippet of JavaScript to sniff the user agent and
|
|
// apply some conditional CSS to *only* the Surface/desktop Windows 8. Look at
|
|
// our Getting Started page for more information on this bug.
|
|
//
|
|
// For more information, see the following:
|
|
//
|
|
// Issue: https://github.com/twbs/bootstrap/issues/10497
|
|
// Docs: http://getbootstrap.com/getting-started/#support-ie10-width
|
|
// Source: http://timkadlec.com/2013/01/windows-phone-8-and-device-width/
|
|
// Source: http://timkadlec.com/2012/10/ie10-snap-mode-and-responsive-design/
|
|
|
|
@-ms-viewport {
|
|
width: device-width;
|
|
}
|
|
|
|
|
|
// Print utilities
|
|
//
|
|
// Media queries are placed on the inside to be mixin-friendly.
|
|
|
|
.visible-print-block {
|
|
display: none !important;
|
|
|
|
@media print {
|
|
display: block !important;
|
|
}
|
|
}
|
|
.visible-print-inline {
|
|
display: none !important;
|
|
|
|
@media print {
|
|
display: inline !important;
|
|
}
|
|
}
|
|
.visible-print-inline-block {
|
|
display: none !important;
|
|
|
|
@media print {
|
|
display: inline-block !important;
|
|
}
|
|
}
|
|
|
|
.hidden-print {
|
|
@media print {
|
|
@include responsive-invisibility(".hidden-print");
|
|
}
|
|
}
|