henkan 2.2.1 → 2.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +3 -5
- package/dist/index.cjs.js.map +2 -2
- package/dist/index.mjs +3 -5
- package/dist/index.mjs.map +2 -2
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -2198,7 +2198,7 @@ function getWordDefinitions(entryList, jmDict) {
|
|
|
2198
2198
|
const defCount = definitionMap.get(
|
|
2199
2199
|
pair.definitions[j].definition
|
|
2200
2200
|
);
|
|
2201
|
-
if (defCount && defCount.count >
|
|
2201
|
+
if (defCount && defCount.count > 1)
|
|
2202
2202
|
pair.definitions[j].mayNotBeAccurate = true;
|
|
2203
2203
|
}
|
|
2204
2204
|
japaneseDefinitions[i] = pair;
|
|
@@ -2461,9 +2461,7 @@ function getWord(word, dict, kanjiDic, examples, definitions, noteTypeName, deck
|
|
|
2461
2461
|
}
|
|
2462
2462
|
}
|
|
2463
2463
|
}
|
|
2464
|
-
if (glossSpecificExamples.length
|
|
2465
|
-
wordExamples = glossSpecificExamples;
|
|
2466
|
-
else if (glossSpecificExamples.length > 0) {
|
|
2464
|
+
if (glossSpecificExamples.length > 0) {
|
|
2467
2465
|
const exes = glossSpecificExamples;
|
|
2468
2466
|
if (exes.length < 5) {
|
|
2469
2467
|
wordExamples = wordExamples.filter(
|
|
@@ -2478,7 +2476,7 @@ function getWord(word, dict, kanjiDic, examples, definitions, noteTypeName, deck
|
|
|
2478
2476
|
wordExamples = exes;
|
|
2479
2477
|
}
|
|
2480
2478
|
if (wordExamples.length > 0) {
|
|
2481
|
-
word2.phrases = (
|
|
2479
|
+
word2.phrases = (glossSpecificExamples.length === 0 ? wordExamples.slice(0, 5) : wordExamples).map((ex) => {
|
|
2482
2480
|
var _a2;
|
|
2483
2481
|
return {
|
|
2484
2482
|
phrase: (_a2 = ex.ex.furigana) != null ? _a2 : ex.ex.phrase,
|