perf: ♻️ Optimize dark mode

This commit is contained in:
viarotel 2024-05-15 14:03:06 +08:00
parent 7c55e50edc
commit 2f2e1cfcd6
3 changed files with 4 additions and 6 deletions

View File

@ -56,7 +56,7 @@ export default () => {
...(theme.isDark
? {
boxShadowColor: '#4C4D4F',
boxBgColor: '#262727',
boxBgColor: '#262626',
inputColor: '#CFD3DC',
inputBgColor: '#141414',
textColor: '#CFD3DC',
@ -65,8 +65,6 @@ export default () => {
: {}),
})
console.log('findInPage', findInPage)
return findInPage
}

View File

@ -2,7 +2,7 @@ import path from 'node:path'
import { createRequire } from 'node:module'
import { fileURLToPath } from 'node:url'
import { BrowserWindow, app, shell } from 'electron'
import { BrowserWindow, app, nativeTheme, shell } from 'electron'
import { electronApp, optimizer } from '@electron-toolkit/utils'
import contextMenu from 'electron-context-menu'
import remote from '@electron/remote/main'
@ -89,7 +89,7 @@ function createWindow() {
sandbox: false,
spellcheck: false,
},
backgroundColor: 'white',
backgroundColor: nativeTheme.shouldUseDarkColors ? 'black' : 'white',
})
remote.enable(mainWindow.webContents)

View File

@ -4,7 +4,7 @@
class=""
circle
size="small"
:title="$t('common.search')"
:title="`${$t('common.search')}Command/Ctrl + F`"
@click="openSearchModal"
>
<el-icon size="12">