diff --git a/README.md b/README.md index 0f036a4e..b3afa487 100644 --- a/README.md +++ b/README.md @@ -34,7 +34,7 @@ electronim ## Features - ⚛ Multi-platform: ElectronIM is available for Linux 🐧, Mac 🍏 and Windows. -- 🌍 Based on Chromium 126 +- 🌍 Based on Chromium 128 - 🔔 Desktop notifications: ElectronIM will notify you using your native system notifications. - 🧐 Spellchecker: ElectronIM contains spellchecker dictionaries for many languages, if your language is not supported, just [file an issue](https://github.com/manusa/electronim/issues/new). diff --git a/build-config/electronim.nuspec b/build-config/electronim.nuspec index c1d8dd18..ee962ddd 100644 --- a/build-config/electronim.nuspec +++ b/build-config/electronim.nuspec @@ -24,7 +24,7 @@ Improve your productivity by combining all your instant messaging applications ( ### Features - ⚛ Multi-platform: ElectronIM is available for Linux 🐧, Mac 🍏 and Windows. -- 🌍 Based on Chromium 126 +- 🌍 Based on Chromium 128 - 🔔 Desktop notifications: ElectronIM will notify you using your native system notifications. - 🧐 Spellchecker: ElectronIM contains spellchecker dictionaries for many languages, if your language is not supported, just [file an issue](https://github.com/manusa/electronim/issues/new). diff --git a/package-lock.json b/package-lock.json index a343aead..d3edd374 100644 --- a/package-lock.json +++ b/package-lock.json @@ -29,7 +29,7 @@ "dictionary-sv": "^3.0.1", "dictionary-tr": "^1.3.3", "dictionary-uk": "^2.1.1", - "electron": "31.7.5", + "electron": "32.2.6", "htm": "3.1.1", "markdown-it": "14.1.0", "nodehun": "3.0.2", @@ -4809,9 +4809,9 @@ } }, "node_modules/electron": { - "version": "31.7.5", - "resolved": "https://registry.npmjs.org/electron/-/electron-31.7.5.tgz", - "integrity": "sha512-8zFzVJdhxTRmoPcRiKkEmPW0bJHAUsTQJwEX2YJ8X0BVFIJLwSvHkSlpCjEExVbNCAk+gHnkIYX+2OyCXrRwHQ==", + "version": "32.2.6", + "resolved": "https://registry.npmjs.org/electron/-/electron-32.2.6.tgz", + "integrity": "sha512-aGG1MLvWCf+ECUFBCmaCF52F8312OPAJfph2D0FSsFmlbfnJuNevZCbty2lFzsiIMtU7/QRo6d0ksbgR4s7y3w==", "hasInstallScript": true, "dependencies": { "@electron/get": "^2.0.0", @@ -14238,9 +14238,9 @@ } }, "electron": { - "version": "31.7.5", - "resolved": "https://registry.npmjs.org/electron/-/electron-31.7.5.tgz", - "integrity": "sha512-8zFzVJdhxTRmoPcRiKkEmPW0bJHAUsTQJwEX2YJ8X0BVFIJLwSvHkSlpCjEExVbNCAk+gHnkIYX+2OyCXrRwHQ==", + "version": "32.2.6", + "resolved": "https://registry.npmjs.org/electron/-/electron-32.2.6.tgz", + "integrity": "sha512-aGG1MLvWCf+ECUFBCmaCF52F8312OPAJfph2D0FSsFmlbfnJuNevZCbty2lFzsiIMtU7/QRo6d0ksbgR4s7y3w==", "requires": { "@electron/get": "^2.0.0", "@types/node": "^20.9.0", diff --git a/package.json b/package.json index 13c00c68..bdcf2ffb 100644 --- a/package.json +++ b/package.json @@ -222,7 +222,7 @@ "dictionary-sv": "^3.0.1", "dictionary-tr": "^1.3.3", "dictionary-uk": "^2.1.1", - "electron": "31.7.5", + "electron": "32.2.6", "htm": "3.1.1", "markdown-it": "14.1.0", "nodehun": "3.0.2", diff --git a/src/__tests__/electron.js b/src/__tests__/electron.js index 8c4673de..8feede3b 100644 --- a/src/__tests__/electron.js +++ b/src/__tests__/electron.js @@ -30,10 +30,12 @@ const mockWebContentsViewInstance = () => { executeJavaScript: jest.fn(async () => {}), focus: jest.fn(), getURL: jest.fn(), - goBack: jest.fn(), loadURL: jest.fn(url => { instance.webContents.loadedUrl = url; }), + navigationHistory: { + goBack: jest.fn() + }, on: jest.fn((...args) => instance.on(...args)), openDevTools: jest.fn(), paste: jest.fn(), diff --git a/src/tab-manager/__tests__/context-menu.test.js b/src/tab-manager/__tests__/context-menu.test.js index b60c2539..c64e6eb8 100644 --- a/src/tab-manager/__tests__/context-menu.test.js +++ b/src/tab-manager/__tests__/context-menu.test.js @@ -40,7 +40,7 @@ describe('Tab Manager context-menu test suite', () => { })); jest.mock('../../spell-check'); electron = require('electron'); - electron.webContentsViewInstance.webContents.canGoBack = jest.fn(() => false); + electron.webContentsViewInstance.webContents.navigationHistory.canGoBack = jest.fn(() => false); listeners = electron.webContentsViewInstance.listeners; event = new Event(''); params = {x: 13, y: 37}; @@ -122,7 +122,7 @@ describe('Tab Manager context-menu test suite', () => { })); }); test('enabled when canGoBack returns true', async () => { - electron.webContentsViewInstance.webContents.canGoBack = jest.fn(() => true); + electron.webContentsViewInstance.webContents.navigationHistory.canGoBack = jest.fn(() => true); await listeners['context-menu'](event, params); expect(electron.MenuItem).toHaveBeenCalledWith(expect.objectContaining({ enabled: false, @@ -133,7 +133,7 @@ describe('Tab Manager context-menu test suite', () => { // When electron.MenuItem.mock.calls.filter(c => c[0].label === 'Back')[0][0].click(); // Then - expect(electron.webContentsViewInstance.webContents.goBack).toHaveBeenCalledTimes(1); + expect(electron.webContentsViewInstance.webContents.navigationHistory.goBack).toHaveBeenCalledTimes(1); }); }); test('Reload click, should trigger reload', async () => { diff --git a/src/tab-manager/context-menu.js b/src/tab-manager/context-menu.js index 49c389cf..1131141c 100644 --- a/src/tab-manager/context-menu.js +++ b/src/tab-manager/context-menu.js @@ -20,8 +20,8 @@ const entries = ({webContents, params}) => { return [ [{ label: 'Back', - enabled: webContents.canGoBack(), - click: () => webContents.goBack() + enabled: webContents.navigationHistory.canGoBack(), + click: () => webContents.navigationHistory.goBack() }, { label: 'Reload', click: () => webContents.reload()