From bed76e0ad85cb76fa3f9010be52cdb9feb9ae04f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=BA=E6=9C=BD?= <107798151+lonelymeko@users.noreply.github.com> Date: Wed, 15 Oct 2025 01:22:23 +0800 Subject: [PATCH] Add custom macOS-style title bar (#1404) Introduces a custom MacOSTitleBar component for macOS, updates the Electron window to use 'hiddenInset' titleBarStyle, and adjusts App.vue to conditionally render the new title bar and add appropriate padding. This improves the native look and feel on macOS platforms. --- src-electron/main.js | 1 + src/App.vue | 15 +++ src/components/TitleBar/MacOSTitleBar.vue | 115 ++++++++++++++++++++++ 3 files changed, 131 insertions(+) create mode 100644 src/components/TitleBar/MacOSTitleBar.vue diff --git a/src-electron/main.js b/src-electron/main.js index c8fa1b69..281969e3 100644 --- a/src-electron/main.js +++ b/src-electron/main.js @@ -316,6 +316,7 @@ function createWindow() { height, icon: path.join(rootDir, 'VRCX.png'), autoHideMenuBar: true, + titleBarStyle: 'hiddenInset', webPreferences: { preload: path.join(__dirname, 'preload.js') } diff --git a/src/App.vue b/src/App.vue index dacdbc5a..df90deaa 100644 --- a/src/App.vue +++ b/src/App.vue @@ -1,9 +1,13 @@