aboutsummaryrefslogtreecommitdiff
path: root/ext/js/language
Commit message (Collapse)AuthorAge
* Add Option for Scanning Alt Text (#1169)marv2024-07-03
| | | | | | | | | | | | | * Add Option for Scanning Alt Text * Don't scan alt text if option disabled * Add scanAltText to Options Schema * Add `scanning.scanAltText` Update Function * Bump Options Test Version * Remove Param Annotation
* fix korean transforms (#1147)Cashew2024-06-28
|
* Add Mongolian (#1146)Michael Nock2024-06-27
|
* add lingua libre audio source (#1129)StefanVukovic992024-06-27
| | | | | | | | | | | | | | | * add lingua libre audio source * mvp * run file requests in parallel * remove redundant language var * redundant api function --------- Co-authored-by: Cashew <52880648+cashewnuttynuts@users.noreply.github.com>
* Add support for halfwidth nakaguro (#1139)Kuuuube2024-06-26
|
* Add normalization of combining dakuten and handakuten to ja preprocessors ↵Kuuuube2024-06-26
| | | | | | | | | | | | | (#1136) * Add normalization of combining dakuten and handakuten to ja preprocessors * Fix typo * Remove redundant variable assignment * Fix first character processed incorrectly when it is a character that gets combined * Add test for combining dakuten and handakuten
* More Spanish transforms (#1100)James Maa2024-06-24
| | | | | | | * Preterite and spanish bench * More spanish forms * Rename
* add cn reading processors (#1120)Cashew2024-06-24
| | | | | | | | | | | | | | | | | | | | | * add cn reading processors * remove meow * fix lint * add cn reading processors * remove meow * fix lint * wip * update names * update test * remove vestigial code
* Add diacritics normalization preprocessors for Vietnamese (#1107)Cashew2024-06-21
| | | | | | | | | | | | | * add viet diacritics normalization * move regexp construction outside of function * fix eslint * add 'off' option * fix lint * fix type
* Add auto option to body theme (#1086)Kuuuube2024-06-19
| | | | | * Add auto option to body theme * Fix firefox bug where themes do not set correctly in settings due to getOptions failing
* [ja] Refactor Japanese transforms names and add English descriptions (#1007)24.6.17.0Lyroxide2024-06-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * add -rya -cha -n * add tests * fix typos * resolve merge conflicts * add tests * change to -ya with chaining * fix -ge and add -garu * add descriptions * descriptions done * add back imperative negative * fix description * add string var * remove form * revert back to volitional * -ku * remove new causative * revert to negative and clarify -n * fix tests * clarify some desc * fix test
* use only longest substring that deinflects to headword (#1075)StefanVukovic992024-06-17
| | | | | | | * show only deinflection for longest matched text * cleanup * cleanup
* Change spanish sample word to 'leer' in language-descriptors.js (#1056)louisv202024-06-12
|
* [ro] preprocess romanian diacritics (#1057)Iurco Tiberiu-Iulian2024-06-12
| | | | | | | * remove romanian diacritics * linting fix * fixed redundancy
* fix -masen verbs being deinflected as negative potential polite (#1046)StefanVukovic992024-06-10
| | | | | | | * test * fix * positive test
* Add context menu interface for Yomitan (#1028)James Maa2024-06-10
| | | | | | | | | | | | | | | | | | | | | | | | | * --wip-- [skip ci] * Draft * Remove weird code * Use existing API instead of dulpicating * Small improvements * remove console.log * remove console.log * Add setting for contextMenu * Fix test * Address comments * Add option-util upgrade * fix option-utils
* [ko] Fix irregular ㄴ deinflection (#1010)24.6.10.0Lyroxide2024-06-09
| | | | | | | | | * fix * resolve conflict --------- Signed-off-by: Lyroxide <33834537+Lyroxide@users.noreply.github.com>
* Add text length check to isTextLookupWorthy (#1026)James Maa2024-06-03
|
* [sh] preprocess accent marks (#1024)StefanVukovic992024-06-03
|
* display inflection rule descriptions (#1000)24.6.3.0StefanVukovic992024-06-03
| | | | | | | | | | | | | | | | | | | | | * load descriptions in deinflector * description functions in deinflectors * show descriptions in title * use toaster * use names without internal * css lint * reformat transform descriptors * fix merge errors * done? * rename method
* Add isTextLookupWorthy function for Chinese (#743)Cashew2024-05-31
| | | | | | | | | | | | | | * add is Chinese check move * fix lint * fix lint * fixes --------- Co-authored-by: Darius Jahandarie <djahandarie@gmail.com> Co-authored-by: Stefan Vukovic <stefanvukovic44@gmail.com>
* Allow trailing commas in ESLint (#1013)James Maa2024-05-31
| | | | | * Update comma-dangle rule * Fix dangling commas
* Clear mouse position on popup close (#997)Kuuuube2024-05-27
|
* Basic Spanish Transforms (#908)James Maa2024-05-23
| | | | | | | | | | | * Spanish transforms * Add more spanish transforms * Address comments * Fix types * Undo prefix change
* Fix detection of modifiers on Firefox in textarea or input and modifiers ↵Kuuuube2024-05-23
| | | | | | | | | | | sent through virtual keycodes (#986) * Fix firefox modifiers in textarea and input * Fix modifiers sent through virtual keycodes * Styling fix * Fix wording in comment
* [ja] add preprocessor for width of alphabetic characters (#964)StefanVukovic992024-05-22
| | | | | | | | | | | | | | | | | | | | | | * add japanese text preprocessor for variants in width of alphabetic characters * try combining with numeric to improve performance * Update ext/js/language/ja/japanese.js Co-authored-by: Kuuuube <61125188+Kuuuube@users.noreply.github.com> Signed-off-by: StefanVukovic99 <stefanvukovic44@gmail.com> * Update ext/js/language/ja/japanese.js Co-authored-by: Kuuuube <61125188+Kuuuube@users.noreply.github.com> Signed-off-by: StefanVukovic99 <stefanvukovic44@gmail.com> * fix tests --------- Signed-off-by: StefanVukovic99 <stefanvukovic44@gmail.com> Co-authored-by: Kuuuube <61125188+Kuuuube@users.noreply.github.com>
* improve preprocessing performance (#973)StefanVukovic992024-05-22
| | | | | | | | | | | * mvp * cleanup * cleanup types * descriptive variable * type
* Allow ordering term dictionaries with the same priority using the ui order ↵Kuuuube2024-05-21
| | | | | | | | | | | | | | | | | | | (#981) * Remove score from dictionary sorting * Update tests * Allow score sorting after dict order * Update tests * Sort by score before index * Move headwordIndices and headwords below score * Update tests * Move definition count back under headwords
* Add Cantonese (#976)marv2024-05-21
| | | | | * Add Cantonese * Revert Mandarin Name Change
* Add Lao language (#963)Pathompong Kwangtong2024-05-18
| | | | | * Add Lao language * Remove last comma in lang-d.js and bring lo out of la nest at lang-des.s.ts
* Disallow scanning while mouse is not moving if input, textarea, or editable ↵Kuuuube2024-05-17
| | | | | | | elements are active (#958) * Disallow scanning while mouse is not moving if input, textarea, or editable elements are active * Move to _inputtingText method
* Fix -ge and add -garu transforms (#952)Lyroxide2024-05-16
| | | | | | | | | | | | | | | * add -rya -cha -n * add tests * fix typos * resolve merge conflicts * add tests * change to -ya with chaining * fix -ge and add -garu
* fix search resolution infinite loop (#938)StefanVukovic992024-05-14
|
* Cache mousemove and hook keyboard to allow scanning at mouse position while ↵Kuuuube2024-05-14
| | | | mouse is no longer moving (#917)
* add korean (#787)StefanVukovic992024-05-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * prepare preprocessors * add postprocessors * add hangul functions (#13) * move hangul to lib, add test (#14) * add hangul functions * hangul lib * fix tests * test inputs * fix hangul disassemble, fix postprocessing * rename test * reset transformedText for multiple postprocessors * add credits * fix conflict --------- Co-authored-by: Stefan Vukovic <stefanvukovic44@gmail.com> * Vetting done (#16) * add hangul functions * hangul lib * fix tests * test inputs * fix hangul disassemble, fix postprocessing * rename test * reset transformedText for multiple postprocessors * add credits * fix conflict * add transforms * move substring * textprocessing function * mostly fixed * delete comment * mostly fixed (cherry picked from commit 268c8968ec64bf9d1fbd7d448a96d590399265c4) * prepare preprocessors (cherry picked from commit d139258398de9285396db31c6d46795ee95eb01a) * (reset) remove textSourceMap * rawSource before textreplacements * update tests * fix transforms * fix transforms * 100% vetted * add link to dict --------- Co-authored-by: Stefan Vukovic <stefanvukovic44@gmail.com> * update unit tests * update test --------- Co-authored-by: Lyroxide <33834537+Lyroxide@users.noreply.github.com>
* added Dutch language option (#913)Kajal Goel2024-05-11
|
* Write english transform tests (#907)Daniel Chapman2024-05-11
| | | | | | | * Write transforms tests for English Wrote transforms tests for English to cover all implemented transforms and fixed code that was failing the tests. * Fix linter errors
* add a few deinflections for Latin (#901)StefanVukovic992024-05-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * abstract deinflections * undo redundant changes * remove cast * switch to js * MultiLanguageTransformer * comments * comments * fix test * suffixInflection * fix bench * substring instead of replace * without heuristic * suffixMap * add other language deinflections * wip * catch cycles * fix tests * uninflect to deinflect * use less regex * start * organize language transform test by language * simpler folders * wip * wip * delete german test * cleanup
* Update eslint unsafe rule (#887)James Maa2024-05-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * Enable @typescript-eslint/no-unsafe-assignment * Updates * Add missing import * Updates * Fix types? * Fix tests * Address comments * Move TextProcessorVariant to types * Update types/ext/translation-internal.d.ts Co-authored-by: StefanVukovic99 <stefanvukovic44@gmail.com> Signed-off-by: James Maa <jmaa@berkeley.edu> --------- Signed-off-by: James Maa <jmaa@berkeley.edu> Co-authored-by: toasted-nutbread <toasted-nutbread@users.noreply.github.com> Co-authored-by: StefanVukovic99 <stefanvukovic44@gmail.com>
* add some Japanese transforms (#833)Lyroxide2024-05-04
| | | | | | | | | | | | | * add -rya -cha -n * add tests * fix typos * resolve merge conflicts * add tests * change to -ya with chaining
* add finnish language option (#867)StefanVukovic992024-04-29
|
* move Albanian grammar comments to test (#852)StefanVukovic992024-04-22
| | | | | * move albanian grammar comments to test * redundant line
* rework text processors (#793)24.4.21.0StefanVukovic992024-04-21
| | | | | | | | | | | | | | | | | | | | | | | | | * rework text processors * rename text-preprocessors file * Fix search header left margins on small screens (#839) * Refocuses search input on backspace (#840) Fixes #775. Note that this behavior gets overridden if backspace is set as a shortcut action. * Change hotkey triggering condition to account for IME usage (#837) _isKeyCharacterInput only worked when not using an IME, as inside of an IME when a keydown event is fired, the key is reported as "Process", which does not have a key.length equal to 1. This resulted in hotkeys being triggered while typing, which this commit fixes. --------- Co-authored-by: James Maa <jmaa@berkeley.edu> Co-authored-by: Kuuuube <61125188+Kuuuube@users.noreply.github.com> Co-authored-by: Andrew Thomas Sartor <andrew@sartor.net>
* start using german deinflections (#848)24.4.20.0StefanVukovic992024-04-20
| | | | | * use german transforms * fix test
* Added Old Irish (#831)Matttttt2024-04-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * added Old Irish (SGA) * Merge Yomitan Updates (#1) * fix (#811) * Add scanOnTouchTap and improve touch scanning defaults (#791) * Add scanOnTouchTap * Update version to 30 * Cleanup if statement * log anki error when hiding button (#821) * Fix noteInfos not getting assigned (#819) * improve term sorting (#806) * improve term sorting * edge case * fix: add missing handlebar entry (#823) * fix: add missing handlebar entry * fix: add new handlebar to tests * Revert to using canAddNotes (#827) Fix #818 * Remove unused canAdd (#824) Co-authored-by: James Maa <jamesmaa@Jamess-MacBook-Pro.local> * Fix duplicate check not working across note types (#830) * Fix duplicate check not working across note types * Add invalidNoteId --------- Co-authored-by: James Maa <jmaa@berkeley.edu> --------- Co-authored-by: StefanVukovic99 <stefanvukovic44@gmail.com> Co-authored-by: Kuuuube <61125188+Kuuuube@users.noreply.github.com> Co-authored-by: m-edlund <me@fwegmann.com> Co-authored-by: Eloy Robillard <eloy.robillard@gmail.com> Co-authored-by: James Maa <jmaa@berkeley.edu> Co-authored-by: James Maa <jamesmaa@Jamess-MacBook-Pro.local> * Revert "Merge Yomitan Updates (#1)" This reverts commit 748dc2202b3ea9e0a028ebae5ecf51208b422c2b. * Fix Static Analysis Error * Fix eslint erro --------- Co-authored-by: martholomew <martholomew@users.noreply.github.com> Co-authored-by: StefanVukovic99 <stefanvukovic44@gmail.com> Co-authored-by: Kuuuube <61125188+Kuuuube@users.noreply.github.com> Co-authored-by: m-edlund <me@fwegmann.com> Co-authored-by: Eloy Robillard <eloy.robillard@gmail.com> Co-authored-by: James Maa <jmaa@berkeley.edu> Co-authored-by: James Maa <jamesmaa@Jamess-MacBook-Pro.local>
* improve term sorting (#806)24.4.15.0StefanVukovic992024-04-15
| | | | | * improve term sorting * edge case
* Add scanOnTouchTap and improve touch scanning defaults (#791)24.4.14.0Kuuuube2024-04-14
| | | | | | | * Add scanOnTouchTap * Update version to 30 * Cleanup if statement
* fix deinflection on past simple of english phrasal verbs (#808)StefanVukovic992024-04-09
|
* english grammar: adverb form of some adjectives (#803)StefanVukovic992024-04-09
|
* Simplify diacratic removal; modify Latin & Greek preprocessors (#724)Matttttt2024-04-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Simplified diacratic removal and added preprocessors to LA and GRC * linted * Clarified the name of removeAlphabeticDiacritics * Add comment to removeAlphabeticDiacritics Signed-off-by: Darius Jahandarie <djahandarie@gmail.com> * Change to NFD Signed-off-by: Matttttt <18152455+martholomew@users.noreply.github.com> * Remove trailing spaces in comment Signed-off-by: Darius Jahandarie <djahandarie@gmail.com> * Remove latin preprocessors .eslintrc.json Signed-off-by: Matttttt <18152455+martholomew@users.noreply.github.com> * fix tests --------- Signed-off-by: Darius Jahandarie <djahandarie@gmail.com> Signed-off-by: Matttttt <18152455+martholomew@users.noreply.github.com> Co-authored-by: martholomew <martholomew@users.noreply.github.com> Co-authored-by: Darius Jahandarie <djahandarie@gmail.com> Co-authored-by: Stefan Vukovic <stefanvukovic44@gmail.com>