diff --git a/index.html b/index.html index fe738c3..b4d4be0 100644 --- a/index.html +++ b/index.html @@ -22,6 +22,14 @@ if (dark) document.documentElement.classList.add("dark"); const locale = localStorage.getItem("hezarfen.locale"); if (locale === "en" || locale === "tr") document.documentElement.lang = locale; + // Android reports only the display cutout through CSS env(), so the + // gesture bar is invisible to the page. The Tauri shell exposes its + // height here; read before first paint so nothing renders under it. + // Absent in a browser, where env(safe-area-inset-bottom) is enough. + const shell = window.HezarfenShell; + if (shell && typeof shell.bottomInsetPx === "function") { + document.documentElement.style.setProperty("--android-nav-inset", shell.bottomInsetPx() + "px"); + } } catch {} })(); diff --git a/src/components/layout/mobile-nav-sheet.tsx b/src/components/layout/mobile-nav-sheet.tsx index 1441991..f91d1d7 100644 --- a/src/components/layout/mobile-nav-sheet.tsx +++ b/src/components/layout/mobile-nav-sheet.tsx @@ -82,8 +82,11 @@ export function MobileNavSheet(props: { />