mirror of
https://github.com/nasa/openmct.git
synced 2025-06-23 17:53:28 +00:00
[Mobile] Fix for emu and act
Adds 2 landscape conditions for tablets and phones to check if they are in landscape, in the actual tablet, or in an emulate of the tablet, then it displays.
This commit is contained in:
@ -40,12 +40,15 @@ $tabHeiPorCheck: "(min-height: #{$tabMinH}) and (max-height: #{$tabMaxH})";
|
||||
$tabHeiLanCheck: "(min-width: #{$tabMinH}) and (max-width: #{$tabMaxH})";
|
||||
|
||||
$mobileDevice: "(max-device-width: #{$tabMaxW}) and (max-device-height: #{$tabMaxH})";
|
||||
$mobileDeviceEmu: "(max-device-width: #{$tabMaxH}) and (max-device-height: #{$tabMaxW})";
|
||||
|
||||
$phoneWidth: "screen and #{$phoWidPorCheck} and #{$phoHeiPorCheck} and #{$mobileDevice} and (orientation: portrait)";
|
||||
$phoneHeight: "screen and #{$phoWidLanCheck} and #{$phoHeiLanCheck} and (orientation: landscape)";
|
||||
$phoneHeight: "screen and #{$phoWidLanCheck} and #{$phoHeiLanCheck} and #{$mobileDevice} and (orientation: landscape)";
|
||||
$phoneHeightEmu: "screen and #{$phoWidLanCheck} and #{$phoHeiLanCheck} and #{$mobileDeviceEmu} and (orientation: landscape)";
|
||||
|
||||
$tabletWidth: "screen and #{$tabWidPorCheck} and #{$tabHeiPorCheck} and #{$mobileDevice} and (orientation: portrait)";
|
||||
$tabletHeight: "screen and #{$tabWidLanCheck} and #{$tabHeiLanCheck} and (orientation: landscape)";
|
||||
$tabletHeight: "screen and #{$tabWidLanCheck} and #{$tabHeiLanCheck} and #{$mobileDevice} and (orientation: landscape)";
|
||||
$tabletHeightEmu: "screen and #{$tabWidLanCheck} and #{$tabHeiLanCheck} and #{$mobileDeviceEmu} and (orientation: landscape)";
|
||||
|
||||
$compMinW: 800px;
|
||||
$compMinH: 1025px;
|
||||
|
@ -23,14 +23,16 @@
|
||||
// NOTE: Mixins for devices
|
||||
@mixin phone {
|
||||
@media #{$phoneWidth},
|
||||
#{$phoneHeight} {
|
||||
#{$phoneHeight},
|
||||
#{$phoneHeightEmu}{
|
||||
@content
|
||||
}
|
||||
}
|
||||
|
||||
@mixin tablet {
|
||||
@media #{$tabletWidth},
|
||||
#{$tabletHeight} {
|
||||
#{$tabletHeight},
|
||||
#{$tabletHeightEmu}{
|
||||
@content
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user