Skip to content

Commit cebd5e7

Browse files
authored
Merge pull request #1574 from santigl/spellcheck-en-gb-dict
Spellcheck: add en_GB dictionary
2 parents 135c4ef + 1585abd commit cebd5e7

File tree

4 files changed

+24
-0
lines changed

4 files changed

+24
-0
lines changed

package-lock.json

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,7 @@
121121
"dictionary-de": "^2.0.3",
122122
"dictionary-de-at": "^2.0.3",
123123
"dictionary-de-ch": "^2.0.3",
124+
"dictionary-en-gb": "^2.2.2",
124125
"doctoc": "~1.4.0",
125126
"ejs-loader": "~0.3.1",
126127
"exports-loader": "~0.7.0",

public/js/lib/editor/spellcheck.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,18 @@ export const supportLanguages = [
1818
cdnUrl: `${serverurl}/vendor/codemirror-spell-checker/en_US.dic`
1919
}
2020
},
21+
{
22+
name: 'English (United Kingdom)',
23+
value: 'en_GB',
24+
aff: {
25+
url: `${serverurl}/build/dictionary-en-gb/index.aff`,
26+
cdnUrl: 'https://cdn.jsdelivr.net/npm/dictionary-en-gb@2.2.2/index.aff'
27+
},
28+
dic: {
29+
url: `${serverurl}/build/dictionary-en-gb/index.dic`,
30+
cdnUrl: 'https://cdn.jsdelivr.net/npm/dictionary-en-gb@2.2.2/index.dic'
31+
}
32+
},
2133
{
2234
name: 'German',
2335
value: 'de',

webpack.common.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,11 @@ module.exports = {
181181
from: '*',
182182
to: 'dictionary-de-ch/'
183183
},
184+
{
185+
context: path.join(__dirname, 'node_modules/dictionary-en-gb'),
186+
from: '*',
187+
to: 'dictionary-en-gb/'
188+
},
184189
{
185190
context: path.join(__dirname, 'node_modules/leaflet'),
186191
from: 'dist',

0 commit comments

Comments
 (0)