Select better threshold for mobile detection
All checks were successful
FarmMaps.Develop/FarmMapsLib/develop This commit looks good
All checks were successful
FarmMaps.Develop/FarmMapsLib/develop This commit looks good
This commit is contained in:
@@ -83,7 +83,7 @@ div.resizegrip > span {
|
||||
top:-1rem;
|
||||
}
|
||||
|
||||
@media screen and (min-width:44rem) {
|
||||
@media screen and (min-width:40rem) {
|
||||
.side-panel {
|
||||
top:0px;
|
||||
width: 22rem;
|
||||
@@ -108,11 +108,11 @@ div.resizegrip > span {
|
||||
|
||||
.side-panel.left.hidden {
|
||||
width: 80%;
|
||||
left:-24rem;
|
||||
left:-80%;
|
||||
height:100%;
|
||||
}
|
||||
|
||||
@media screen and (min-width:44rem) {
|
||||
@media screen and (min-width:40rem) {
|
||||
.side-panel.left {
|
||||
width:22rem;
|
||||
}
|
||||
|
@@ -28,7 +28,7 @@ export class SidePanelComponent implements OnChanges {
|
||||
checkMobile():boolean {
|
||||
let size = parseFloat(getComputedStyle(document.documentElement).width);
|
||||
let rem = parseFloat(getComputedStyle(document.documentElement).fontSize);
|
||||
let threshold = 44 * rem;
|
||||
let threshold = 40 * rem;
|
||||
return !(size>threshold);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user