Vibrancy (fixes #5) (#383)

This commit is contained in:
Eugene Pankov
2018-08-02 10:34:46 -07:00
committed by GitHub
parent 7e253d72ea
commit cc9c66c4a9
13 changed files with 120 additions and 59 deletions

View File

@@ -9,7 +9,7 @@ html
script(src='./preload.js')
script(src='./bundle.js', defer)
style#custom-css
body(style='background: ; min-height: 100vh; overflow: hidden')
body(style='min-height: 100vh; overflow: hidden')
app-root
.preload-logo
div

View File

@@ -1,5 +1,7 @@
if (process.platform == 'win32' && require('electron-squirrel-startup')) process.exit(0)
const electron = require('electron')
if (process.argv.indexOf('--debug') !== -1) {
require('electron-debug')({enabled: true, showDevTools: 'undocked'})
}
@@ -217,7 +219,7 @@ start = () => {
//- background to avoid the flash of unstyled window
backgroundColor: '#131d27',
frame: false,
//type: 'toolbar',
show: false,
}
Object.assign(options, windowConfig.get('windowBoundaries'))
@@ -229,18 +231,24 @@ start = () => {
}
}
if (['darwin', 'win32'].includes(process.platform)) {
options.transparent = true
delete options.backgroundColor
}
app.commandLine.appendSwitch('disable-http-cache')
app.window = new electron.BrowserWindow(options)
app.window.once('ready-to-show', () => {
app.window.show()
app.window.focus()
})
app.window.loadURL(`file://${app.getAppPath()}/dist/index.html`, {extraHeaders: "pragma: no-cache\n"})
if (process.platform != 'darwin') {
app.window.setMenu(null)
}
app.window.show()
app.window.focus()
setupWindowManagement()
if (process.platform == 'darwin') {

View File

@@ -66,3 +66,7 @@
[ngbradiogroup] input[type="radio"] {
display: none;
}
body {
background: #131d27;
}