blob: 0762d07004d8fb538539a176946ae1d574f11eab (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
let style = document.createElement("style");
if (window.MistAndroid) {
style.innerHTML =
`:root {
--android-navigation-bar: ${window.MistAndroid.getNavigationBarHeight()}px;
--android-status-bar: ${window.MistAndroid.getStatusBarHeight()}px;
}`;
} else {
style.innerHTML =
`:root {
--android-navigation-bar: 0px;
--android-status-bar: 0px;
}`;
}
document.head.append(style);
if (navigator.userAgent.includes("MistNative/darwin")) {
if (document.getElementById("native-css")) document.getElementById("native-css").disabled = false;
if (document.body) document.body.classList.remove("crossplatform");
}
|