From 4390f6ebc2c2cd6126a7358898acade1269f4fbd Mon Sep 17 00:00:00 2001 From: s1gnate-sync <139636216+s1gnate-sync@users.noreply.github.com> Date: Tue, 14 May 2024 10:49:10 +0100 Subject: [PATCH] Window controls overlay (#837) * Update main.scss Make page header a title bar * Update manifest.json Allow custom titlebar * Resize page header so it won't overlap titlebar controls --- web/manifest.json | 1 + web/styles/main.scss | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/web/manifest.json b/web/manifest.json index 66b7d71e..d7811553 100644 --- a/web/manifest.json +++ b/web/manifest.json @@ -11,6 +11,7 @@ "capture_links": "new-client", "start_url": "/#boot", "display": "standalone", + "display_override": ["window-controls-overlay"], "scope": "/", "theme_color": "#e1e1e1", "description": "Markdown as a platform" diff --git a/web/styles/main.scss b/web/styles/main.scss index ba19f5e6..61ffffe3 100644 --- a/web/styles/main.scss +++ b/web/styles/main.scss @@ -70,7 +70,7 @@ body { flex-direction: row; .wrapper { - width: 100%; + width: env(titlebar-area-width, 100%); padding: 0 20px; display: flex; box-sizing: border-box; @@ -103,6 +103,8 @@ body { text-align: left; display: block; + -webkit-app-region: drag; + .cm-scroller { font-family: var(--ui-font); } @@ -227,4 +229,4 @@ body { margin: 0; } } -} \ No newline at end of file +}