henkan 0.0.0

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.
Files changed (66) hide show
  1. package/CONTRIBUTING.md +25 -0
  2. package/LICENSE.md +21 -0
  3. package/README.md +82 -0
  4. package/SECURITY.md +20 -0
  5. package/dist/index.cjs.js +2257 -0
  6. package/dist/index.cjs.js.map +7 -0
  7. package/dist/index.mjs +2199 -0
  8. package/dist/index.mjs.map +7 -0
  9. package/dist/types/constants.d.ts +8 -0
  10. package/dist/types/constants.d.ts.map +1 -0
  11. package/dist/types/index.d.ts +4 -0
  12. package/dist/types/index.d.ts.map +1 -0
  13. package/dist/types/types.d.ts +680 -0
  14. package/dist/types/types.d.ts.map +1 -0
  15. package/dist/types/utils.d.ts +135 -0
  16. package/dist/types/utils.d.ts.map +1 -0
  17. package/docs/api/README.md +62 -0
  18. package/docs/api/functions/capitalizeString.md +27 -0
  19. package/docs/api/functions/convertJMdict.md +27 -0
  20. package/docs/api/functions/convertKanjiDic.md +27 -0
  21. package/docs/api/functions/convertKradFile.md +39 -0
  22. package/docs/api/functions/convertRadkFile.md +33 -0
  23. package/docs/api/functions/convertTanakaCorpus.md +33 -0
  24. package/docs/api/functions/generateAnkiNote.md +27 -0
  25. package/docs/api/functions/generateAnkiNotesFile.md +27 -0
  26. package/docs/api/functions/getKanji.md +57 -0
  27. package/docs/api/functions/getKanjiExtended.md +69 -0
  28. package/docs/api/functions/getWord.md +63 -0
  29. package/docs/api/functions/isStringArray.md +27 -0
  30. package/docs/api/functions/isValidArray.md +27 -0
  31. package/docs/api/functions/isValidArrayWithFirstElement.md +27 -0
  32. package/docs/api/functions/makeSSML.md +33 -0
  33. package/docs/api/functions/shuffleArray.md +33 -0
  34. package/docs/api/functions/synthesizeSpeech.md +39 -0
  35. package/docs/api/interfaces/DictKanji.md +43 -0
  36. package/docs/api/interfaces/DictKanjiForm.md +51 -0
  37. package/docs/api/interfaces/DictKanjiMisc.md +61 -0
  38. package/docs/api/interfaces/DictKanjiReading.md +31 -0
  39. package/docs/api/interfaces/DictKanjiReadingMeaning.md +33 -0
  40. package/docs/api/interfaces/DictKanjiReadingMeaningGroup.md +33 -0
  41. package/docs/api/interfaces/DictKanjiWithRadicals.md +33 -0
  42. package/docs/api/interfaces/DictMeaning.md +129 -0
  43. package/docs/api/interfaces/DictRadical.md +41 -0
  44. package/docs/api/interfaces/DictReading.md +61 -0
  45. package/docs/api/interfaces/DictWord.md +53 -0
  46. package/docs/api/interfaces/ExamplePart.md +75 -0
  47. package/docs/api/interfaces/Grammar.md +165 -0
  48. package/docs/api/interfaces/GrammarMeaning.md +31 -0
  49. package/docs/api/interfaces/Kana.md +125 -0
  50. package/docs/api/interfaces/Kanji.md +239 -0
  51. package/docs/api/interfaces/KanjiComponent.md +31 -0
  52. package/docs/api/interfaces/KanjiForm.md +33 -0
  53. package/docs/api/interfaces/Phrase.md +47 -0
  54. package/docs/api/interfaces/Radical.md +165 -0
  55. package/docs/api/interfaces/Reading.md +43 -0
  56. package/docs/api/interfaces/ResultEntry.md +75 -0
  57. package/docs/api/interfaces/TanakaExample.md +51 -0
  58. package/docs/api/interfaces/Translation.md +33 -0
  59. package/docs/api/interfaces/UsefulRegExps.md +93 -0
  60. package/docs/api/interfaces/Word.md +149 -0
  61. package/docs/api/type-aliases/Dict.md +13 -0
  62. package/docs/api/type-aliases/DictName.md +13 -0
  63. package/docs/api/type-aliases/EntryType.md +13 -0
  64. package/docs/api/type-aliases/JLPT.md +13 -0
  65. package/docs/api/type-aliases/Result.md +13 -0
  66. package/package.json +87 -0
@@ -0,0 +1,13 @@
1
+ [**henkan**](../README.md)
2
+
3
+ ***
4
+
5
+ [henkan](../README.md) / EntryType
6
+
7
+ # Type Alias: EntryType
8
+
9
+ > **EntryType** = `"word"` \| `"kanji"` \| `"radical"` \| `"kana"` \| `"grammar"`
10
+
11
+ Defined in: types.ts:345
12
+
13
+ Names of entry types used for the Anki note IDs
@@ -0,0 +1,13 @@
1
+ [**henkan**](../README.md)
2
+
3
+ ***
4
+
5
+ [henkan](../README.md) / JLPT
6
+
7
+ # Type Alias: JLPT
8
+
9
+ > **JLPT** = `"N5"` \| `"N4"` \| `"N3"` \| `"N2"` \| `"N1"`
10
+
11
+ Defined in: types.ts:4
12
+
13
+ JLPT levels
@@ -0,0 +1,13 @@
1
+ [**henkan**](../README.md)
2
+
3
+ ***
4
+
5
+ [henkan](../README.md) / Result
6
+
7
+ # Type Alias: Result
8
+
9
+ > **Result** = [`Word`](../interfaces/Word.md) \| [`Kanji`](../interfaces/Kanji.md) \| [`Radical`](../interfaces/Radical.md) \| [`Kana`](../interfaces/Kana.md) \| [`Grammar`](../interfaces/Grammar.md)
10
+
11
+ Defined in: types.ts:672
12
+
13
+ Any type of converted entry from a [Dict](Dict.md) array + others not from a dictionary
package/package.json ADDED
@@ -0,0 +1,87 @@
1
+ {
2
+ "name": "henkan",
3
+ "version": "0.0.0",
4
+ "description": "A Node.JS library that helps you convert any dictionary from EDRDG, transform their entries into more user-friendly schemas and create Anki notes from the them.",
5
+ "keywords": [
6
+ "fjsd",
7
+ "japanese",
8
+ "japanese-language",
9
+ "anki-cards",
10
+ "anki-deck",
11
+ "anki",
12
+ "katakana",
13
+ "hiragana",
14
+ "kana",
15
+ "kanji",
16
+ "japanese-grammar",
17
+ "jmdict"
18
+ ],
19
+ "author": {
20
+ "name": "Ronokof",
21
+ "email": "ronokoffjsd@gmail.com"
22
+ },
23
+ "repository": {
24
+ "type": "git",
25
+ "url": "git+https://github.com/Ronokof/Henkan.git"
26
+ },
27
+ "homepage": "https://github.com/Ronokof/Henkan",
28
+ "bugs": {
29
+ "url": "https://github.com/Ronokof/Henkan/issues",
30
+ "email": "ronokoffjsd@gmail.com"
31
+ },
32
+ "license": "MIT",
33
+ "main": "dist/index.cjs.js",
34
+ "module": "dist/index.mjs",
35
+ "types": "dist/types/index.d.ts",
36
+ "exports": {
37
+ ".": {
38
+ "types": "./dist/types/index.d.ts",
39
+ "import": "./dist/index.mjs",
40
+ "require": "./dist/index.cjs.js"
41
+ },
42
+ "./package.json": "./package.json"
43
+ },
44
+ "files": [
45
+ "dist/**/*",
46
+ "docs/**/*",
47
+ "README.md",
48
+ "LICENSE.md",
49
+ "CONTRIBUTING.md",
50
+ "SECURITY.md"
51
+ ],
52
+ "scripts": {
53
+ "clean": "rimraf dist",
54
+ "build:types": "tsc -p tsconfig.types.json",
55
+ "build:cjs": "node ./scripts/build-esbuild.cjs cjs",
56
+ "build:esm": "node ./scripts/build-esbuild.cjs esm",
57
+ "build": "npm run clean && npm run build:types && npm run build:esm && npm run build:cjs",
58
+ "lint": "eslint 'src/**/*.{ts,tsx}' --fix",
59
+ "prepare": "npm run lint && npm run build",
60
+ "docs:api": "typedoc --plugin typedoc-plugin-markdown --out docs/api src/index.ts --readme none --excludePrivate --excludeProtected --excludeNotDocumented --hideGenerator"
61
+ },
62
+ "devDependencies": {
63
+ "@types/node": "^24.5.2",
64
+ "@types/xml2js": "^0.4.14",
65
+ "@typescript-eslint/eslint-plugin": "^8.44.0",
66
+ "@typescript-eslint/parser": "^8.44.0",
67
+ "esbuild": "^0.25.10",
68
+ "eslint": "^9.36.0",
69
+ "eslint-plugin-prettier": "^5.5.4",
70
+ "prettier": "^3.6.2",
71
+ "rimraf": "^6.0.1",
72
+ "typedoc": "^0.28.13",
73
+ "typedoc-plugin-markdown": "^4.9.0",
74
+ "typescript": "^5.9.2"
75
+ },
76
+ "dependencies": {
77
+ "@aws-sdk/client-polly": "^3.893.0",
78
+ "iconv-lite": "^0.7.0",
79
+ "kuroshiro": "^1.2.0",
80
+ "kuroshiro-analyzer-kuromoji": "^1.1.0",
81
+ "libxmljs2": "^0.37.0",
82
+ "xml2js": "^0.6.2"
83
+ },
84
+ "engines": {
85
+ "node": ">=22.17.0"
86
+ }
87
+ }