fix: increase top reserve so tab panel fully clears content webview

This commit is contained in:
2026-08-16 21:38:01 +08:00
parent b901afc901
commit 0154ebc999
@@ -51,11 +51,11 @@ class MainActivity : Activity() {
// Placeholder manifest/catalog URLs; replace with the real server on device // Placeholder manifest/catalog URLs; replace with the real server on device
private const val MANIFEST_URL = "https://example.com/hearth/manifest.json" private const val MANIFEST_URL = "https://example.com/hearth/manifest.json"
private const val CATALOG_URL = "https://example.com/hearth/catalog.json" private const val CATALOG_URL = "https://example.com/hearth/catalog.json"
// 内容 WebView 顶部预留高度(dp):顶栏(约 54dp)+ 横向标签面板(约 40dp), // 内容 WebView 顶部预留高度(dp):顶栏(约 54dp)+ 横向标签面板(约 45dp),
// 取 96dp 留余量,避免内容 WebView 覆盖顶栏与标签面板 // 取 104dp 留余量,确保标签面板完全不被内容 WebView 覆盖
// Content WebView top reserve (dp): topbar (~54dp) + horizontal tab panel // Content WebView top reserve (dp): topbar (~54dp) + horizontal tab panel
// (~40dp); use 96dp with margin so the content WebView covers neither // (~45dp); use 104dp with margin so the tab panel is never covered
private const val TOPBAR_HEIGHT_DP = 96 private const val TOPBAR_HEIGHT_DP = 104
// 全局侧边栏收起宽度(dp),内容 WebView 左侧预留,避免挡住侧边栏 // 全局侧边栏收起宽度(dp),内容 WebView 左侧预留,避免挡住侧边栏
// Global sidebar collapsed width (dp); content WebViews reserve it on the // Global sidebar collapsed width (dp); content WebViews reserve it on the
// left to avoid covering the sidebar // left to avoid covering the sidebar