Commit Graph

33 Commits

Author SHA1 Message Date
toasted-nutbread
ef333b6d72
Dictionary data structure improvements (#877)
* Simplify object structure of deinflections

* Modify existing array when removing duplicates

* Update _sortDefinitions to not return a value

* Use explicit argument value

* Use a Collator for string comparisons

* Simplify order comparison

* Improve tag creation and sanitization

* Switch .map to a for loop, skip null meta

* Add _createKanjiStat

* Move _sortDefinitions definition

* Fix kanji stat sorting

* Remove return value from _sortTags

* Add _sortKanji

* Add fast exits for sorting

* Add _sortDefinitionsByIndex

* Combine sort function

* Improve creation of kanji definition data

* Use "databaseDefinitions" instead of "definitions" to disambiguate

* Simplify

* Simplify further

* Simplify max length calculation

* More destructuring

* Use databaseDefinitions variable name

* Move _mergeBySequence body into _getSequencedDefinitions

* Use databaseDefinitions field name

* Move maxLength calculation

* Use shared _createTermDefinitionFromDatabaseDefinition

* Simplify map

* Move definition sorts for better consistency and less redundancy

* Move _createExpression function

* Update setup of sequenced definitions

* Simplify for loop
2020-10-02 17:59:14 -04:00
4e5029f7ec Update license author field to broader to explicitly reflect that
Yomichan is an ongoing community project. It really does take a village,
and everyone who contributes code owns a part of it :)
2020-04-10 11:10:21 -07:00
toasted-nutbread
3795af6cb5 Use Object.entries rather than for in 2020-02-25 19:54:59 -05:00
toasted-nutbread
f23e0c9c95 Validate Deinflector.ruleTypes 2020-02-02 10:09:19 -05:00
toasted-nutbread
0d7ccf25b8 Update license info URL 2020-01-01 12:00:31 -05:00
toasted-nutbread
899ef167d1 Update copyright 2020-01-01 12:00:00 -05:00
toasted-nutbread
df9e697fca Remove trailing commas 2019-11-26 22:06:27 -05:00
toasted-nutbread
cf18e3b42e Replace string.substr and string.slice with string.substring
Improves semantic clarity, and it's recommended to not use substr.
2019-11-24 11:02:52 -05:00
toasted-nutbread
50a47348a7 Optimize internal data structure used by the Deinflector class 2019-10-05 18:28:30 -04:00
toasted-nutbread
1286b5115f Use bulk database searches 2019-09-28 22:05:10 -04:00
bdf231082f lots of fixes to backend 2017-08-14 21:43:09 -07:00
49352c5fa1 move deinflector to async 2017-07-10 14:30:34 -07:00
ff3315ebf1 fixing reason sorting 2017-03-25 12:09:57 -07:00
0d2e9be0ce wip 2017-02-26 11:12:54 -08:00
8efe5b1fbf workaround for broken const in firefox 2017-01-28 18:46:15 -08:00
dd3db8faad fixing various deinflection issues 2016-12-20 21:54:01 -08:00
28b8bae6a7 deinflector optimizations 2016-12-19 21:23:17 -08:00
0aa603694c Fixing deinflection 2016-12-19 20:03:06 -08:00
d98f4566bc WIP 2016-12-17 18:45:19 -08:00
adfc9b7f2a Cleanup 2016-09-19 21:12:45 -07:00
c05f7a7c1c Work on progress bar 2016-09-16 20:28:59 -07:00
d5ea03171e Working with IndexDb 2016-09-11 12:29:18 -07:00
0587399883 WIP 2016-09-10 19:44:54 -07:00
05ac931285 Work on deinflector 2016-09-10 18:57:00 -07:00
18fc8d9865 Performance improvements 2016-08-20 19:15:30 -07:00
9649a83181 Better control over result ordering. This fixes #12 2016-08-20 13:04:59 -07:00
3c9f2c6a2e Cleanup 2016-08-07 13:01:27 -07:00
d3272efef7 Get rid of addon hack 2016-08-07 12:41:09 -07:00
024ec83251 Reduce file size 2016-08-06 23:16:55 -07:00
ad61722130 Use let instead of const in for loops. 2016-06-14 20:44:38 -07:00
7ef0f4e881 Handle intermediate tags through addons 2016-04-19 22:04:55 -07:00
9ceef4649f Fixes to deinflection logic 2016-04-16 20:11:27 -07:00
37ffcbf3ee File reorg 2016-04-04 22:02:26 -07:00