Overview
Comment: | Mise au féminin des informations des locutions + Fix |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | fr | Lexicographe |
Files: | files | file ages | folders |
SHA3-256: |
a7c1a8771ba45981bd6a556a5af70440 |
User & Date: | IllusionPerdu on 2017-11-01 09:23:30 |
Other Links: | branch diff | manifest | tags |
Context
2017-11-01
| ||
10:04 | [fr] locutions: màj des fichiers json/py check-in: 896e89f0d9 user: olr tags: fr, Lexicographe | |
09:23 | Mise au féminin des informations des locutions + Fix check-in: a7c1a8771b user: IllusionPerdu tags: fr, Lexicographe | |
09:20 | [fr] data: locutions check-in: 144b46f14c user: olr tags: fr, Lexicographe | |
Changes
Modified gc_lang/fr/modules-js/lexicographe.js from [d63c8f768b] to [c64e56ddcf].
︙ | ︙ | |||
106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 | ['/M', ""], ['/R', " {réforme}"], ['/A', ""], ['/X', ""] ]); const _dLocTAGS = new Map([ [':LN', "locution nominale"], [':LA', "locution adjectivale"], [':LV', "locution verbale"], [':LW', "locution adverbiale"], [':LR', "locution prépositive"], [':LO', "locution pronominale"], [':LC', "locution conjonctive"], [':LJ', "locution interjective"], | > | | | | | > | 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 | ['/M', ""], ['/R', " {réforme}"], ['/A', ""], ['/X', ""] ]); const _dLocTAGS = new Map([ [':L', "locution"], [':LN', "locution nominale"], [':LA', "locution adjectivale"], [':LV', "locution verbale"], [':LW', "locution adverbiale"], [':LR', "locution prépositive"], [':LO', "locution pronominale"], [':LC', "locution conjonctive"], [':LJ', "locution interjective"], [':B', " cardinale"], [':e', " épicène"], [':m', " masculine"], [':f', " féminine"], [':s', " singulière"], [':p', " plurielle"], [':i', " invariable"], ['/L', " {latin}"] ]); const _dLocVERB = new Map([ ['i', " intransitif"], ['n', " transitif indirect"], ['t', " transitif direct"], ['p', " pronominal"], ['m', " impersonnel"], ]); |
︙ | ︙ | |||
227 228 229 230 231 232 233 | this.oDict = oDict; this.oTokenizer = oTokenizer; this.oLocGraph = JSON.parse(oLocGraph); this._zElidedPrefix = new RegExp("^([dljmtsncç]|quoiqu|lorsqu|jusqu|puisqu|qu)['’](.+)", "i"); this._zCompoundWord = new RegExp("([a-zA-Zà-ö0-9À-Öø-ÿØ-ßĀ-ʯ]+)-((?:les?|la)-(?:moi|toi|lui|[nv]ous|leur)|t-(?:il|elle|on)|y|en|[mts][’'](?:y|en)|les?|l[aà]|[mt]oi|leur|lui|je|tu|ils?|elles?|on|[nv]ous)$", "i"); this._zTag = new RegExp("[:;/][a-zA-Zà-ö0-9À-Öø-ÿØ-ßĀ-ʯ*Ṽ][^:;/]*", "g"); | | | 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 | this.oDict = oDict; this.oTokenizer = oTokenizer; this.oLocGraph = JSON.parse(oLocGraph); this._zElidedPrefix = new RegExp("^([dljmtsncç]|quoiqu|lorsqu|jusqu|puisqu|qu)['’](.+)", "i"); this._zCompoundWord = new RegExp("([a-zA-Zà-ö0-9À-Öø-ÿØ-ßĀ-ʯ]+)-((?:les?|la)-(?:moi|toi|lui|[nv]ous|leur)|t-(?:il|elle|on)|y|en|[mts][’'](?:y|en)|les?|l[aà]|[mt]oi|leur|lui|je|tu|ils?|elles?|on|[nv]ous)$", "i"); this._zTag = new RegExp("[:;/][a-zA-Zà-ö0-9À-Öø-ÿØ-ßĀ-ʯ*Ṽ][^:;/]*", "g"); this._zLocTag = new RegExp("((:L)([A-Z])?)([a-z].?)?(:.*)?"); } getInfoForToken (oToken) { // Token: .sType, .sValue, .nStart, .nEnd // return a object {sType, sValue, aLabel} let m = null; try { |
︙ | ︙ | |||
342 343 344 345 346 347 348 | } return sRes.gl_trimRight(","); } _formatTagsLoc (sTags) { let sRes = ""; let oTagsVerb = this._zLocTag.exec(sTags); | < < < | | | | | | > > > > | | > | 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 | } return sRes.gl_trimRight(","); } _formatTagsLoc (sTags) { let sRes = ""; let oTagsVerb = this._zLocTag.exec(sTags); sRes += _dLocTAGS.get(oTagsVerb[1]); if (oTagsVerb[4] && oTagsVerb[1] === ':LV'){ oTagsVerb[4].split(/(?!$)/u).forEach(function(sKey) { sRes += _dLocVERB.get(sKey); }); } if (oTagsVerb[5]){ let m; while ((m = this._zTag.exec(oTagsVerb[5])) !== null) { sRes += _dLocTAGS.get(m[0]); if (sRes.length > 100) { break; } } } if (!sRes) { sRes = "#Erreur. Étiquette inconnue : [" + sTags + "]"; helpers.echo(sRes); return sRes; } |
︙ | ︙ |