Upgrade dependencies (#996)
* Upgrade Electron to 5.0.4 * Fix spellcheck provider * npm audit fix
This commit is contained in:

committed by
Harrison Healey

parent
2cfc735d6d
commit
04c03c3baf
@@ -186,10 +186,14 @@ function resetMisspelledState() {
|
||||
|
||||
function setSpellChecker() {
|
||||
const spellCheckerLocale = ipcRenderer.sendSync('get-spellchecker-locale');
|
||||
webFrame.setSpellCheckProvider(spellCheckerLocale, false, {
|
||||
spellCheck(text) {
|
||||
const res = ipcRenderer.sendSync('checkspell', text);
|
||||
return res === null ? true : res;
|
||||
webFrame.setSpellCheckProvider(spellCheckerLocale, {
|
||||
spellCheck(words, callback) {
|
||||
const misspeltWords = words.filter((text) => {
|
||||
const res = ipcRenderer.sendSync('checkspell', text);
|
||||
const isCorrect = (res === null) ? true : res;
|
||||
return !isCorrect;
|
||||
});
|
||||
callback(misspeltWords);
|
||||
},
|
||||
});
|
||||
resetMisspelledState();
|
||||
|
@@ -43,6 +43,10 @@ function createMainWindow(config, options) {
|
||||
minWidth: minimumWindowWidth,
|
||||
minHeight: minimumWindowHeight,
|
||||
fullscreen: false,
|
||||
webPreferences: {
|
||||
nodeIntegration: true,
|
||||
webviewTag: true,
|
||||
},
|
||||
});
|
||||
|
||||
const mainWindow = new BrowserWindow(windowOptions);
|
||||
|
6
src/package-lock.json
generated
6
src/package-lock.json
generated
@@ -370,9 +370,9 @@
|
||||
"integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ=="
|
||||
},
|
||||
"js-yaml": {
|
||||
"version": "3.12.1",
|
||||
"resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.12.1.tgz",
|
||||
"integrity": "sha512-um46hB9wNOKlwkHgiuyEVAybXBjwFUV0Z/RaHJblRd9DXltue9FTYvzCr9ErQrK9Adz5MU4gHWVaNUfdmrC8qA==",
|
||||
"version": "3.13.1",
|
||||
"resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.13.1.tgz",
|
||||
"integrity": "sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==",
|
||||
"requires": {
|
||||
"argparse": "^1.0.7",
|
||||
"esprima": "^4.0.0"
|
||||
|
Reference in New Issue
Block a user