Skip to content

Commit 7614880

Browse files
anuejnpajowu
authored andcommitted
🪟 update electron to 23
sadly this will break linux file-dialog attachment due to an upstream bug
1 parent 5dfc2a5 commit 7614880

6 files changed

Lines changed: 1875 additions & 7469 deletions

File tree

app/main_process/index.ts

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -11,31 +11,21 @@ export const createWindow = (): void => {
1111
const window = new BrowserWindow({
1212
height: 600,
1313
width: 800,
14-
frame: false,
15-
titleBarStyle: 'hiddenInset',
16-
titleBarOverlay: true,
14+
titleBarStyle: 'hidden',
1715
trafficLightPosition: { x: 21, y: 21 },
16+
titleBarOverlay: {
17+
color: '#fff',
18+
symbolColor: '#000',
19+
height: 55,
20+
},
1821
webPreferences: {
1922
nodeIntegration: true,
2023
contextIsolation: false,
2124
enableBlinkFeatures: 'ClipboardCustomFormats',
22-
nativeWindowOpen: true,
2325
},
2426
show: false,
2527
});
2628

27-
window.webContents.on('new-window', (event, url, frameName, disposition, options) => {
28-
if (frameName === 'modal') {
29-
event.preventDefault();
30-
event.newGuest = new BrowserWindow({
31-
...options,
32-
parent: window,
33-
width: 500,
34-
height: 400,
35-
});
36-
}
37-
});
38-
3929
if (process.env.NODE_ENV === 'development') {
4030
installExtension([REDUX_DEVTOOLS, REACT_DEVELOPER_TOOLS])
4131
.then((name: string) => console.log(`Added Extension: ${name}`))

app/main_process/vite_main.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ export default defineConfig({
2323
build: {
2424
lib: {
2525
entry: 'index.ts',
26-
fileName: 'start',
26+
fileName: 'start.cjs',
2727
formats: ['cjs'],
2828
},
2929
outDir: '../build/main_process/',

0 commit comments

Comments
 (0)