mirror of
https://github.com/Foundry376/Mailspring.git
synced 2024-12-27 02:23:28 +08:00
Update electron to v10
- Remove the electron-spelllchecker package as it does not work anymore - Remove the spellchecker temporarily - Manually set enableRemoteModule to true
This commit is contained in:
parent
9ee21cf2b9
commit
6dc0e82509
7 changed files with 85 additions and 16040 deletions
247
app/package-lock.json
generated
247
app/package-lock.json
generated
|
@ -1,12 +1,12 @@
|
|||
{
|
||||
"name": "mailspring",
|
||||
"version": "1.9.2",
|
||||
"version": "1.9.3",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "mailspring",
|
||||
"version": "1.9.2",
|
||||
"version": "1.9.3",
|
||||
"license": "GPL-3.0",
|
||||
"dependencies": {
|
||||
"@bengotow/slate-edit-list": "github:bengotow/slate-edit-list#b868e108",
|
||||
|
@ -19,7 +19,6 @@
|
|||
"collapse-whitespace": "^1.1.6",
|
||||
"debug": "github:emorikawa/debug#nylas",
|
||||
"deep-extend": "0.6.0",
|
||||
"electron-spellchecker": "github:bengotow/electron-spellchecker#267df08",
|
||||
"emoji-data": "^0.2.0",
|
||||
"enzyme": "^3.8.0",
|
||||
"enzyme-adapter-react-16": "^1.9.0",
|
||||
|
@ -97,15 +96,6 @@
|
|||
"node_modules/@bengotow/slate-edit-list": {
|
||||
"resolved": "git+ssh://git@github.com/bengotow/slate-edit-list.git#b868e1088b44ad1adb2cb06bbbb847a2fef7edb5"
|
||||
},
|
||||
"node_modules/@felixrieseberg/spellchecker": {
|
||||
"version": "4.0.12",
|
||||
"resolved": "https://registry.npmjs.org/@felixrieseberg/spellchecker/-/spellchecker-4.0.12.tgz",
|
||||
"integrity": "sha512-jLAPnRALB1I6Un8ldHVJfJid7m2R1qXoafFF/95sdm7R5VPOsZ3xTreZ/wLKO5x9AdsD2t9zpOcjDFTsCf3VzQ==",
|
||||
"hasInstallScript": true,
|
||||
"dependencies": {
|
||||
"nan": "2.14.0"
|
||||
}
|
||||
},
|
||||
"node_modules/@icons/material": {
|
||||
"version": "0.2.4",
|
||||
"resolved": "https://registry.npmjs.org/@icons/material/-/material-0.2.4.tgz",
|
||||
|
@ -406,14 +396,6 @@
|
|||
"resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.3.1.tgz",
|
||||
"integrity": "sha512-mLQ4i2QO1ytvGWFWmcngKO//JXAQueZvwEKtjgQFM4jIK0kU+ytMfplL8j+n5mspOfjHwoAg+9yhb7BwAHm36g=="
|
||||
},
|
||||
"node_modules/bcp47": {
|
||||
"version": "1.1.2",
|
||||
"resolved": "https://registry.npmjs.org/bcp47/-/bcp47-1.1.2.tgz",
|
||||
"integrity": "sha1-NUvjMH/9CEM6ePXh4glYRfifx/4=",
|
||||
"engines": {
|
||||
"node": ">=0.10"
|
||||
}
|
||||
},
|
||||
"node_modules/bcrypt-pbkdf": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz",
|
||||
|
@ -1097,51 +1079,6 @@
|
|||
"node": ">=0.8"
|
||||
}
|
||||
},
|
||||
"node_modules/electron-spellchecker": {
|
||||
"resolved": "git+ssh://git@github.com/bengotow/electron-spellchecker.git#267df085fa4c1a5f5631e5f0ebd627890d59d670",
|
||||
"dependencies": {
|
||||
"@felixrieseberg/spellchecker": "4.0.12",
|
||||
"bcp47": "1.1.2",
|
||||
"cld": "2.6.0",
|
||||
"debug": "4.3.1",
|
||||
"keyboard-layout": "2.0.17",
|
||||
"lru-cache": "5.1.1",
|
||||
"mkdirp": "0.5.1",
|
||||
"pify": "4.0.1",
|
||||
"rxjs": "5.5.12",
|
||||
"rxjs-serial-subscription": "0.1.1",
|
||||
"spawn-rx": "2.0.12"
|
||||
}
|
||||
},
|
||||
"node_modules/electron-spellchecker/node_modules/debug": {
|
||||
"version": "4.3.1",
|
||||
"resolved": "https://registry.npmjs.org/debug/-/debug-4.3.1.tgz",
|
||||
"integrity": "sha512-doEwdvm4PCeK4K3RQN2ZC2BYUBaxwLARCqZmMjtF8a51J2Rb0xpVloFRnCODwqjpwnAoao4pelN8l3RJdv3gRQ==",
|
||||
"dependencies": {
|
||||
"ms": "2.1.2"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=6.0"
|
||||
}
|
||||
},
|
||||
"node_modules/electron-spellchecker/node_modules/lru-cache": {
|
||||
"version": "5.1.1",
|
||||
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz",
|
||||
"integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==",
|
||||
"dependencies": {
|
||||
"yallist": "3.1.1"
|
||||
}
|
||||
},
|
||||
"node_modules/electron-spellchecker/node_modules/ms": {
|
||||
"version": "2.1.2",
|
||||
"resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
|
||||
"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w=="
|
||||
},
|
||||
"node_modules/electron-spellchecker/node_modules/yallist": {
|
||||
"version": "3.1.1",
|
||||
"resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz",
|
||||
"integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g=="
|
||||
},
|
||||
"node_modules/emissary": {
|
||||
"version": "1.3.3",
|
||||
"resolved": "https://registry.npmjs.org/emissary/-/emissary-1.3.3.tgz",
|
||||
|
@ -2390,21 +2327,6 @@
|
|||
"node": ">= 6"
|
||||
}
|
||||
},
|
||||
"node_modules/keyboard-layout": {
|
||||
"version": "2.0.17",
|
||||
"resolved": "https://registry.npmjs.org/keyboard-layout/-/keyboard-layout-2.0.17.tgz",
|
||||
"integrity": "sha512-W9LL+1e8CS9fi0s8ZHINDN1HZ6QpYjE4yLi4+faed7ozppNOAxINjv5w16zG9tJv8Jp5LJrCfO5PZ9aV1m5d4g==",
|
||||
"hasInstallScript": true,
|
||||
"dependencies": {
|
||||
"event-kit": "2.5.3",
|
||||
"nan": "2.14.0"
|
||||
}
|
||||
},
|
||||
"node_modules/keyboard-layout/node_modules/event-kit": {
|
||||
"version": "2.5.3",
|
||||
"resolved": "https://registry.npmjs.org/event-kit/-/event-kit-2.5.3.tgz",
|
||||
"integrity": "sha512-b7Qi1JNzY4BfAYfnIRanLk0DOD1gdkWHT4GISIn8Q2tAf3LpU8SP2CMwWaq40imYoKWbtN4ZhbSRxvsnikooZQ=="
|
||||
},
|
||||
"node_modules/keytar": {
|
||||
"version": "5.5.0",
|
||||
"resolved": "https://registry.npmjs.org/keytar/-/keytar-5.5.0.tgz",
|
||||
|
@ -2624,11 +2546,6 @@
|
|||
"resolved": "https://registry.npmjs.org/lodash-es/-/lodash-es-4.17.20.tgz",
|
||||
"integrity": "sha512-JD1COMZsq8maT6mnuz1UMV0jvYD0E0aUsSOdrr1/nAG3dhqQXwRRgeW0cSqH1U43INKcqxaiVIQNOUDld7gRDA=="
|
||||
},
|
||||
"node_modules/lodash.assign": {
|
||||
"version": "4.2.0",
|
||||
"resolved": "https://registry.npmjs.org/lodash.assign/-/lodash.assign-4.2.0.tgz",
|
||||
"integrity": "sha1-DZnzzNem0mHRm9rrkkUAXShYCOc="
|
||||
},
|
||||
"node_modules/lodash.escape": {
|
||||
"version": "4.0.1",
|
||||
"resolved": "https://registry.npmjs.org/lodash.escape/-/lodash.escape-4.0.1.tgz",
|
||||
|
@ -3141,14 +3058,6 @@
|
|||
"svg-attributes": "1.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/pify": {
|
||||
"version": "4.0.1",
|
||||
"resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz",
|
||||
"integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==",
|
||||
"engines": {
|
||||
"node": ">=6"
|
||||
}
|
||||
},
|
||||
"node_modules/postcss": {
|
||||
"version": "6.0.23",
|
||||
"resolved": "https://registry.npmjs.org/postcss/-/postcss-6.0.23.tgz",
|
||||
|
@ -3539,25 +3448,6 @@
|
|||
"resolved": "https://registry.npmjs.org/rx-lite/-/rx-lite-4.0.8.tgz",
|
||||
"integrity": "sha1-Cx4Rr4vESDbwSmQH6S2kJGe3lEQ="
|
||||
},
|
||||
"node_modules/rxjs": {
|
||||
"version": "5.5.12",
|
||||
"resolved": "https://registry.npmjs.org/rxjs/-/rxjs-5.5.12.tgz",
|
||||
"integrity": "sha512-xx2itnL5sBbqeeiVgNPVuQQ1nC8Jp2WfNJhXWHmElW9YmrpS9UVnNzhP3EH3HFqexO5Tlp8GhYY+WEcqcVMvGw==",
|
||||
"dependencies": {
|
||||
"symbol-observable": "1.0.1"
|
||||
},
|
||||
"engines": {
|
||||
"npm": ">=2.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/rxjs-serial-subscription": {
|
||||
"version": "0.1.1",
|
||||
"resolved": "https://registry.npmjs.org/rxjs-serial-subscription/-/rxjs-serial-subscription-0.1.1.tgz",
|
||||
"integrity": "sha1-pCsdsL8QlLCSMRkeJ3jKP8+e0Uc=",
|
||||
"dependencies": {
|
||||
"rxjs": "5.5.12"
|
||||
}
|
||||
},
|
||||
"node_modules/safe-buffer": {
|
||||
"version": "5.1.2",
|
||||
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
|
||||
|
@ -3819,16 +3709,6 @@
|
|||
"node": ">=0.8.0"
|
||||
}
|
||||
},
|
||||
"node_modules/spawn-rx": {
|
||||
"version": "2.0.12",
|
||||
"resolved": "https://registry.npmjs.org/spawn-rx/-/spawn-rx-2.0.12.tgz",
|
||||
"integrity": "sha512-gOPXiQQFQ9lTOLuys0iMn3jfxxv9c7zzwhbYLOEbQGvEShHVJ5sSR1oD3Daj88os7jKArDYT7rbOKdvNhe7iEg==",
|
||||
"dependencies": {
|
||||
"debug": "github:emorikawa/debug#29685485665b44c42d33ebd7ed62570b21c6e4bd",
|
||||
"lodash.assign": "4.2.0",
|
||||
"rxjs": "5.5.12"
|
||||
}
|
||||
},
|
||||
"node_modules/sprintf-js": {
|
||||
"version": "1.0.3",
|
||||
"resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz",
|
||||
|
@ -4085,14 +3965,6 @@
|
|||
"npm": ">=1.4.3"
|
||||
}
|
||||
},
|
||||
"node_modules/symbol-observable": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/symbol-observable/-/symbol-observable-1.0.1.tgz",
|
||||
"integrity": "sha1-g0D8RwLDEi310iKI+IKD9RPT/dQ=",
|
||||
"engines": {
|
||||
"node": ">=0.10.0"
|
||||
}
|
||||
},
|
||||
"node_modules/tar": {
|
||||
"version": "6.1.0",
|
||||
"resolved": "https://registry.npmjs.org/tar/-/tar-6.1.0.tgz",
|
||||
|
@ -4519,14 +4391,6 @@
|
|||
"version": "git+ssh://git@github.com/bengotow/slate-edit-list.git#b868e1088b44ad1adb2cb06bbbb847a2fef7edb5",
|
||||
"from": "@bengotow/slate-edit-list@github:bengotow/slate-edit-list#b868e108"
|
||||
},
|
||||
"@felixrieseberg/spellchecker": {
|
||||
"version": "4.0.12",
|
||||
"resolved": "https://registry.npmjs.org/@felixrieseberg/spellchecker/-/spellchecker-4.0.12.tgz",
|
||||
"integrity": "sha512-jLAPnRALB1I6Un8ldHVJfJid7m2R1qXoafFF/95sdm7R5VPOsZ3xTreZ/wLKO5x9AdsD2t9zpOcjDFTsCf3VzQ==",
|
||||
"requires": {
|
||||
"nan": "2.14.0"
|
||||
}
|
||||
},
|
||||
"@icons/material": {
|
||||
"version": "0.2.4",
|
||||
"resolved": "https://registry.npmjs.org/@icons/material/-/material-0.2.4.tgz",
|
||||
|
@ -4768,11 +4632,6 @@
|
|||
"resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.3.1.tgz",
|
||||
"integrity": "sha512-mLQ4i2QO1ytvGWFWmcngKO//JXAQueZvwEKtjgQFM4jIK0kU+ytMfplL8j+n5mspOfjHwoAg+9yhb7BwAHm36g=="
|
||||
},
|
||||
"bcp47": {
|
||||
"version": "1.1.2",
|
||||
"resolved": "https://registry.npmjs.org/bcp47/-/bcp47-1.1.2.tgz",
|
||||
"integrity": "sha1-NUvjMH/9CEM6ePXh4glYRfifx/4="
|
||||
},
|
||||
"bcrypt-pbkdf": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz",
|
||||
|
@ -5317,51 +5176,6 @@
|
|||
"semver": "5.7.0"
|
||||
}
|
||||
},
|
||||
"electron-spellchecker": {
|
||||
"version": "git+ssh://git@github.com/bengotow/electron-spellchecker.git#267df085fa4c1a5f5631e5f0ebd627890d59d670",
|
||||
"from": "electron-spellchecker@github:bengotow/electron-spellchecker#267df08",
|
||||
"requires": {
|
||||
"@felixrieseberg/spellchecker": "4.0.12",
|
||||
"bcp47": "1.1.2",
|
||||
"cld": "2.6.0",
|
||||
"debug": "4.3.1",
|
||||
"keyboard-layout": "2.0.17",
|
||||
"lru-cache": "5.1.1",
|
||||
"mkdirp": "0.5.1",
|
||||
"pify": "4.0.1",
|
||||
"rxjs": "5.5.12",
|
||||
"rxjs-serial-subscription": "0.1.1",
|
||||
"spawn-rx": "2.0.12"
|
||||
},
|
||||
"dependencies": {
|
||||
"debug": {
|
||||
"version": "4.3.1",
|
||||
"resolved": "https://registry.npmjs.org/debug/-/debug-4.3.1.tgz",
|
||||
"integrity": "sha512-doEwdvm4PCeK4K3RQN2ZC2BYUBaxwLARCqZmMjtF8a51J2Rb0xpVloFRnCODwqjpwnAoao4pelN8l3RJdv3gRQ==",
|
||||
"requires": {
|
||||
"ms": "2.1.2"
|
||||
}
|
||||
},
|
||||
"lru-cache": {
|
||||
"version": "5.1.1",
|
||||
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz",
|
||||
"integrity": "sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==",
|
||||
"requires": {
|
||||
"yallist": "3.1.1"
|
||||
}
|
||||
},
|
||||
"ms": {
|
||||
"version": "2.1.2",
|
||||
"resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
|
||||
"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w=="
|
||||
},
|
||||
"yallist": {
|
||||
"version": "3.1.1",
|
||||
"resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz",
|
||||
"integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g=="
|
||||
}
|
||||
}
|
||||
},
|
||||
"emissary": {
|
||||
"version": "1.3.3",
|
||||
"resolved": "https://registry.npmjs.org/emissary/-/emissary-1.3.3.tgz",
|
||||
|
@ -6343,22 +6157,6 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"keyboard-layout": {
|
||||
"version": "2.0.17",
|
||||
"resolved": "https://registry.npmjs.org/keyboard-layout/-/keyboard-layout-2.0.17.tgz",
|
||||
"integrity": "sha512-W9LL+1e8CS9fi0s8ZHINDN1HZ6QpYjE4yLi4+faed7ozppNOAxINjv5w16zG9tJv8Jp5LJrCfO5PZ9aV1m5d4g==",
|
||||
"requires": {
|
||||
"event-kit": "2.5.3",
|
||||
"nan": "2.14.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"event-kit": {
|
||||
"version": "2.5.3",
|
||||
"resolved": "https://registry.npmjs.org/event-kit/-/event-kit-2.5.3.tgz",
|
||||
"integrity": "sha512-b7Qi1JNzY4BfAYfnIRanLk0DOD1gdkWHT4GISIn8Q2tAf3LpU8SP2CMwWaq40imYoKWbtN4ZhbSRxvsnikooZQ=="
|
||||
}
|
||||
}
|
||||
},
|
||||
"keytar": {
|
||||
"version": "5.5.0",
|
||||
"resolved": "https://registry.npmjs.org/keytar/-/keytar-5.5.0.tgz",
|
||||
|
@ -6542,11 +6340,6 @@
|
|||
"resolved": "https://registry.npmjs.org/lodash-es/-/lodash-es-4.17.20.tgz",
|
||||
"integrity": "sha512-JD1COMZsq8maT6mnuz1UMV0jvYD0E0aUsSOdrr1/nAG3dhqQXwRRgeW0cSqH1U43INKcqxaiVIQNOUDld7gRDA=="
|
||||
},
|
||||
"lodash.assign": {
|
||||
"version": "4.2.0",
|
||||
"resolved": "https://registry.npmjs.org/lodash.assign/-/lodash.assign-4.2.0.tgz",
|
||||
"integrity": "sha1-DZnzzNem0mHRm9rrkkUAXShYCOc="
|
||||
},
|
||||
"lodash.escape": {
|
||||
"version": "4.0.1",
|
||||
"resolved": "https://registry.npmjs.org/lodash.escape/-/lodash.escape-4.0.1.tgz",
|
||||
|
@ -6975,11 +6768,6 @@
|
|||
"svg-attributes": "1.0.0"
|
||||
}
|
||||
},
|
||||
"pify": {
|
||||
"version": "4.0.1",
|
||||
"resolved": "https://registry.npmjs.org/pify/-/pify-4.0.1.tgz",
|
||||
"integrity": "sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g=="
|
||||
},
|
||||
"postcss": {
|
||||
"version": "6.0.23",
|
||||
"resolved": "https://registry.npmjs.org/postcss/-/postcss-6.0.23.tgz",
|
||||
|
@ -7328,22 +7116,6 @@
|
|||
"resolved": "https://registry.npmjs.org/rx-lite/-/rx-lite-4.0.8.tgz",
|
||||
"integrity": "sha1-Cx4Rr4vESDbwSmQH6S2kJGe3lEQ="
|
||||
},
|
||||
"rxjs": {
|
||||
"version": "5.5.12",
|
||||
"resolved": "https://registry.npmjs.org/rxjs/-/rxjs-5.5.12.tgz",
|
||||
"integrity": "sha512-xx2itnL5sBbqeeiVgNPVuQQ1nC8Jp2WfNJhXWHmElW9YmrpS9UVnNzhP3EH3HFqexO5Tlp8GhYY+WEcqcVMvGw==",
|
||||
"requires": {
|
||||
"symbol-observable": "1.0.1"
|
||||
}
|
||||
},
|
||||
"rxjs-serial-subscription": {
|
||||
"version": "0.1.1",
|
||||
"resolved": "https://registry.npmjs.org/rxjs-serial-subscription/-/rxjs-serial-subscription-0.1.1.tgz",
|
||||
"integrity": "sha1-pCsdsL8QlLCSMRkeJ3jKP8+e0Uc=",
|
||||
"requires": {
|
||||
"rxjs": "5.5.12"
|
||||
}
|
||||
},
|
||||
"safe-buffer": {
|
||||
"version": "5.1.2",
|
||||
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
|
||||
|
@ -7597,16 +7369,6 @@
|
|||
}
|
||||
}
|
||||
},
|
||||
"spawn-rx": {
|
||||
"version": "2.0.12",
|
||||
"resolved": "https://registry.npmjs.org/spawn-rx/-/spawn-rx-2.0.12.tgz",
|
||||
"integrity": "sha512-gOPXiQQFQ9lTOLuys0iMn3jfxxv9c7zzwhbYLOEbQGvEShHVJ5sSR1oD3Daj88os7jKArDYT7rbOKdvNhe7iEg==",
|
||||
"requires": {
|
||||
"debug": "github:emorikawa/debug#29685485665b44c42d33ebd7ed62570b21c6e4bd",
|
||||
"lodash.assign": "4.2.0",
|
||||
"rxjs": "5.5.12"
|
||||
}
|
||||
},
|
||||
"sprintf-js": {
|
||||
"version": "1.0.3",
|
||||
"resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz",
|
||||
|
@ -7789,11 +7551,6 @@
|
|||
"resolved": "https://registry.npmjs.org/svg-attributes/-/svg-attributes-1.0.0.tgz",
|
||||
"integrity": "sha1-tcWWjzYke32+OFMgfyqcaK2Aa/w="
|
||||
},
|
||||
"symbol-observable": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/symbol-observable/-/symbol-observable-1.0.1.tgz",
|
||||
"integrity": "sha1-g0D8RwLDEi310iKI+IKD9RPT/dQ="
|
||||
},
|
||||
"tar": {
|
||||
"version": "6.1.0",
|
||||
"resolved": "https://registry.npmjs.org/tar/-/tar-6.1.0.tgz",
|
||||
|
|
|
@ -21,7 +21,6 @@
|
|||
"collapse-whitespace": "^1.1.6",
|
||||
"debug": "github:emorikawa/debug#nylas",
|
||||
"deep-extend": "0.6.0",
|
||||
"electron-spellchecker": "github:bengotow/electron-spellchecker#267df08",
|
||||
"emoji-data": "^0.2.0",
|
||||
"enzyme": "^3.8.0",
|
||||
"enzyme-adapter-react-16": "^1.9.0",
|
||||
|
|
|
@ -100,6 +100,7 @@ export default class MailspringWindow extends EventEmitter {
|
|||
nodeIntegration: true,
|
||||
contextIsolation: false,
|
||||
webviewTag: true,
|
||||
enableRemoteModule: true,
|
||||
},
|
||||
autoHideMenuBar,
|
||||
};
|
||||
|
|
|
@ -112,7 +112,7 @@ export class MailsyncProcess extends EventEmitter {
|
|||
maximizable: false,
|
||||
closable: false,
|
||||
fullscreenable: false,
|
||||
webPreferences: { nodeIntegration: false, javascript: false, contextIsolation: false },
|
||||
webPreferences: { nodeIntegration: false, javascript: false, contextIsolation: false, enableRemoteModule: true },
|
||||
});
|
||||
this._win.setContentSize(350, 90);
|
||||
this._win.once('ready-to-show', () => {
|
||||
|
|
|
@ -7,28 +7,27 @@ import { localized } from './intl';
|
|||
const { app, MenuItem } = remote;
|
||||
const customDictFilePath = path.join(AppEnv.getConfigDirPath(), 'custom-dict.json');
|
||||
|
||||
const { webFrame } = require('electron');
|
||||
|
||||
class Spellchecker {
|
||||
private _customDictLoaded = false;
|
||||
private _saveOnLoad = false;
|
||||
private _savingCustomDict = false;
|
||||
private _saveAgain = false;
|
||||
private _win;
|
||||
|
||||
private _customDict = {};
|
||||
|
||||
public handler: import('electron-spellchecker').SpellCheckHandler;
|
||||
|
||||
constructor() {
|
||||
this.handler = null;
|
||||
|
||||
// Nobody will notice if spellcheck isn't available for a few seconds and it
|
||||
// takes a considerable amount of time to startup (212ms in dev mode on my 2017 MBP)
|
||||
const initHandler = () => {
|
||||
this._win = AppEnv.getCurrentWindow();
|
||||
this._loadCustomDict();
|
||||
|
||||
const initialLanguage = AppEnv.config.get('core.composing.spellcheckDefaultLanguage');
|
||||
const { SpellCheckHandler } = require('electron-spellchecker'); //eslint-disable-line
|
||||
this.handler = new SpellCheckHandler(initialLanguage);
|
||||
this.handler['isMisspelledCache'] = new LRUCache({ max: 5000 });
|
||||
this._switchToLanguage(initialLanguage);
|
||||
|
||||
// Monitor language setting for changes. Note that as the user types in a draft we
|
||||
// change spellcheck to that language.
|
||||
|
@ -42,17 +41,23 @@ class Spellchecker {
|
|||
} else {
|
||||
setTimeout(initHandler, 5000);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
_switchToLanguage = lang => {
|
||||
if (lang === null || lang === undefined || lang === '') {
|
||||
lang = app.getLocale() || 'en-US';
|
||||
}
|
||||
this.handler.switchLanguage(lang);
|
||||
this.handler['isMisspelledCache'].reset();
|
||||
|
||||
// Only switch to a language that is supported by the system.
|
||||
// Otherwise stay at the current language. Default language is the OS language.
|
||||
if (this._win.webContents.session.availableSpellCheckerLanguages.includes(lang)) {
|
||||
this._win.webContents.session.setSpellCheckerLanguages([lang])
|
||||
}
|
||||
};
|
||||
|
||||
_loadCustomDict = () => {
|
||||
/*
|
||||
fs.readFile(customDictFilePath, (err, data) => {
|
||||
let fileData: any = data;
|
||||
if (err) {
|
||||
|
@ -72,9 +77,11 @@ class Spellchecker {
|
|||
this._saveOnLoad = false;
|
||||
}
|
||||
});
|
||||
*/
|
||||
};
|
||||
|
||||
_saveCustomDict = () => {
|
||||
/*
|
||||
// If we haven't loaded the dict yet, saving could overwrite all the things.
|
||||
// Wait until the loaded dict is merged with our working copy before saving
|
||||
if (this._customDictLoaded) {
|
||||
|
@ -99,16 +106,20 @@ class Spellchecker {
|
|||
} else {
|
||||
this._saveOnLoad = true;
|
||||
}
|
||||
*/
|
||||
};
|
||||
|
||||
provideHintText = text => {
|
||||
/*
|
||||
if (!this.handler) {
|
||||
return false;
|
||||
}
|
||||
this.handler.provideHintText(text);
|
||||
*/
|
||||
};
|
||||
|
||||
isMisspelled = (word: string) => {
|
||||
/*
|
||||
if (!this.handler) {
|
||||
return false;
|
||||
}
|
||||
|
@ -116,21 +127,32 @@ class Spellchecker {
|
|||
return false;
|
||||
}
|
||||
return !(this.handler as any).handleElectronSpellCheck([word]);
|
||||
*/
|
||||
};
|
||||
|
||||
learnWord = word => {
|
||||
/*
|
||||
this._customDict[word] = '';
|
||||
this._saveCustomDict();
|
||||
*/
|
||||
};
|
||||
|
||||
unlearnWord = word => {
|
||||
/*
|
||||
if (word in this._customDict) {
|
||||
delete this._customDict[word];
|
||||
this._saveCustomDict();
|
||||
}
|
||||
*/
|
||||
};
|
||||
|
||||
appendSpellingItemsToMenu = async ({ menu, word, onCorrect, onDidLearn }) => {
|
||||
//console.log(this._win.webContents.session.availableSpellCheckerLanguages);
|
||||
|
||||
// TODO: Re-Add Spellchecking
|
||||
//console.log(webFrame.isWordMisspelled(word));
|
||||
//console.log(webFrame.getWordSuggestions(word));
|
||||
/*
|
||||
if (this.isMisspelled(word)) {
|
||||
const corrections = await this.handler.currentSpellchecker.getCorrectionsForMisspelling(word);
|
||||
if (corrections.length > 0) {
|
||||
|
@ -161,6 +183,7 @@ class Spellchecker {
|
|||
menu.append(new MenuItem({ type: 'separator' }));
|
||||
}
|
||||
};
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
export default new Spellchecker();
|
||||
|
|
15830
package-lock.json
generated
15830
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
@ -16,7 +16,6 @@
|
|||
"@types/better-sqlite3": "^5.4.0",
|
||||
"@types/debug": "^4.1.2",
|
||||
"@types/deep-extend": "^0.4.31",
|
||||
"@types/electron-spellchecker": "^1.1.1",
|
||||
"@types/enzyme": "^3.9.0",
|
||||
"@types/enzyme-adapter-react-16": "^1.0.5",
|
||||
"@types/event-kit": "^2.4.0",
|
||||
|
@ -53,7 +52,7 @@
|
|||
"@typescript-eslint/parser": "^4.7.0",
|
||||
"chalk": "1.x.x",
|
||||
"devtron": "^1.4.0",
|
||||
"electron": "8.5.5",
|
||||
"electron": "10.4.7",
|
||||
"electron-installer-dmg": "^3.0.0",
|
||||
"electron-packager": "15.2.x",
|
||||
"electron-winstaller": "2.x.x",
|
||||
|
|
Loading…
Reference in a new issue