Comment: | [core][js] conditional requires and variable renaming to avoid overridding |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | core | webext2 |
Files: | files | file ages | folders |
SHA3-256: |
7e545790c388950734fee675858de868 |
User & Date: | olr on 2017-08-02 06:12:02 |
Other Links: | branch diff | manifest | tags |
2017-08-02
| ||
06:26 | [core][js] variable renaming again check-in: e35b6e2bbd user: olr tags: core, webext2 | |
06:12 | [core][js] conditional requires and variable renaming to avoid overridding check-in: 7e545790c3 user: olr tags: core, webext2 | |
2017-08-01
| ||
09:44 | [core][js] gc_engine as object check-in: 2163dd1535 user: olr tags: core, webext2 | |
Modified gc_core/js/ibdawg.js from [e748c8288e] to [81ed21aafb].
1 2 3 4 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | + + - - + + + | //// IBDAWG "use strict"; if (typeof(exports) !== 'undefined') { |
︙ | |||
37 38 39 40 41 42 43 | 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | - + - + - + | throw RangeError("# Error. Unknown dictionary version: " + this.nVersion); } this.dChar = helpers.objectToMap(this.dChar); //this.byDic = new Uint8Array(this.byDic); // not quicker, even slower if (this.cStemming == "S") { |
︙ |
Modified gc_core/js/lang_core/gc_engine.js from [bd03577ac7] to [57156dedce].
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | + + + + + + + + + + + - - - - - - - | // Grammar checker engine ${string} ${regex} ${map} if (typeof(exports) !== 'undefined') { var ibdawg = require("resource://grammalecte/ibdawg.js"); var helpers = require("resource://grammalecte/helpers.js"); var gc_options = require("resource://grammalecte/${lang}/gc_options.js"); var gc_rules = require("resource://grammalecte/${lang}/gc_rules.js"); var cregex = require("resource://grammalecte/${lang}/cregex.js"); var text = require("resource://grammalecte/text.js"); var echo = require("resource://grammalecte/helpers.js").echo; } function capitalizeArray (aArray) { // can’t map on user defined function?? let aNew = []; for (let i = 0; i < aArray.length; i = i + 1) { aNew[i] = aArray[i].gl_toCapitalize(); } return aNew; } |
︙ |
Modified gc_core/js/str_transform.js from [9b41fc7a14] to [33525a019a].
1 2 3 4 | 1 2 3 4 5 6 7 8 9 10 11 12 | - + | //// STRING TRANSFORMATION // Note: 48 is the ASCII code for "0" |
︙ |
Modified gc_core/js/tests.js from [f2f737b523] to [373a8fcfff].
1 2 3 4 5 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | + - + + | // JavaScript "use strict"; if (typeof(exports) !== 'undefined') { |
︙ |
Modified gc_core/js/text.js from [b502e53f4f] to [2c268f1b5e].
1 2 3 4 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | + + - - - + + + + + | // JavaScript "use strict"; if (typeof(exports) !== 'undefined') { |
︙ |
Modified gc_core/js/tokenizer.js from [a6594366c3] to [02266194ef].
1 2 3 4 5 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | + + - - - + + + + + | // JavaScript // Very simple tokenizer "use strict"; if (typeof(exports) !== 'undefined') { |
︙ | |||
38 39 40 41 42 43 44 | 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 | - + - + | } class Tokenizer { constructor (sLang) { this.sLang = sLang; |
︙ |
Modified gc_lang/fr/modules-js/gce_analyseur.js from [673094989d] to [973aa5af1d].
︙ | |||
18 19 20 21 22 23 24 | 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 | - + - + - + - + - + - + - + - + - + - + - + | return "vous"; } if (s2 == "eux") { return "ils"; } if (s2 == "elle" || s2 == "elles") { // We don’t check if word exists in _dAnalyses, for it is assumed it has been done before |
︙ |
Modified gc_lang/fr/modules-js/gce_suggestions.js from [d46530bfae] to [7f7dced66d].
1 2 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 | + - - - + + + + | //// GRAMMAR CHECKING ENGINE PLUGIN: Suggestion mechanisms if (typeof(exports) !== 'undefined') { |
︙ | |||
193 194 195 196 197 198 199 | 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 | - + | function suggPlur (sFlex, sWordToAgree=null) { // returns plural forms assuming sFlex is singular if (sWordToAgree) { if (!_dAnalyses.has(sWordToAgree) && !_storeMorphFromFSA(sWordToAgree)) { return ""; } |
︙ | |||
259 260 261 262 263 264 265 | 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 | - + - + | let aSugg = new Set(); for (let sMorph of _dAnalyses.gl_get(sFlex, [])) { if (!sMorph.includes(":V")) { // not a verb if (sMorph.includes(":m") || sMorph.includes(":e")) { aSugg.add(suggSing(sFlex)); } else { |
︙ | |||
295 296 297 298 299 300 301 | 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 | - + - + | let aSugg = new Set(); for (let sMorph of _dAnalyses.gl_get(sFlex, [])) { if (!sMorph.includes(":V")) { // not a verb if (sMorph.includes(":m") || sMorph.includes(":e")) { aSugg.add(suggPlur(sFlex)); } else { |
︙ | |||
336 337 338 339 340 341 342 | 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 | - + - + | let aSugg = new Set(); for (let sMorph of _dAnalyses.gl_get(sFlex, [])) { if (!sMorph.includes(":V")) { // not a verb if (sMorph.includes(":f") || sMorph.includes(":e")) { aSugg.add(suggSing(sFlex)); } else { |
︙ | |||
370 371 372 373 374 375 376 | 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 | - + - + | let aSugg = new Set(); for (let sMorph of _dAnalyses.gl_get(sFlex, [])) { if (!sMorph.includes(":V")) { // not a verb if (sMorph.includes(":f") || sMorph.includes(":e")) { aSugg.add(suggPlur(sFlex)); } else { |
︙ |
Modified gc_lang/fr/modules-js/lexicographe.js from [5e8c9037a7] to [8f5fca9732].
1 2 3 4 5 6 7 8 9 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | + - + - - + | // Grammalecte - Lexicographe // License: MPL 2 "use strict"; ${string} ${map} if (typeof(exports) !== 'undefined') { |
︙ |
Modified gc_lang/fr/modules-js/mfsp.js from [6dafeac5dd] to [8827303ea6].
1 2 3 4 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | + + - + + + | // Grammalecte "use strict"; if (typeof(exports) !== 'undefined') { |
︙ |
Modified gc_lang/fr/modules-js/phonet.js from [17494340df] to [c49188f2a5].
1 2 | 1 2 3 4 5 6 7 8 9 10 11 12 13 | + - + + + | // Grammalecte - Suggestion phonétique if (typeof(exports) !== 'undefined') { |
︙ |
Modified gc_lang/fr/modules-js/textformatter.js from [7314bcd9a1] to [6dfa91f96e].
︙ | |||
194 195 196 197 198 199 200 | 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 | - + | [/^(qu|lorsqu|puisqu|quoiqu|presqu|jusqu|aujourd|entr|quelqu|prud) /ig, "$1’"] ], "ma_1letter_lowercase": [ [/[ ]([ldjnmtscç]) (?=[aàeéêiîoôuyhAÀEÉÊIÎOÔUYH])/g, "$1’"] ], "ma_1letter_uppercase": [ [/[ ]([LDJNMTSCÇ]) (?=[aàeéêiîoôuyhAÀEÉÊIÎOÔUYH])/g, "$1’"], [/^([LDJNMTSCÇ]) (?=[aàeéêiîoôuyhAÀEÉÊIÎOÔUYH])/g, "$1’"] ] }; |
︙ | |||
247 248 249 250 251 252 253 | 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 | - + - + - + - + | ["etc", true], ["missing_hyphens", true], ["ma_word", true], ["ma_1letter_lowercase", false], ["ma_1letter_uppercase", false] ]); |
Modified gc_lang/fr/webext/gce_worker.js from [8fda2777a3] to [245798772a].
|
Modified gc_lang/fr/webext/manifest.json from [53ddc564c6] to [f93daca40b].
︙ | |||
26 27 28 29 30 31 32 | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | + - + + + + + | "browser_action": { "default_icon": "img/logo-32.png", "default_popup": "panel/main.html", "default_title": "Grammalecte [fr]", "browser_style": false }, "background": { "scripts": [ |
︙ |