lol-constants 0.4.0 → 0.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (41) hide show
  1. package/dist/Constants/ChampionKeys.d.ts +2 -0
  2. package/dist/Constants/ChampionKeys.js +8 -0
  3. package/dist/Constants/ChampionNames.d.ts +2 -0
  4. package/dist/Constants/ChampionNames.js +8 -0
  5. package/dist/Constants/ItemKeys.d.ts +2 -0
  6. package/dist/Constants/ItemKeys.js +8 -0
  7. package/dist/Constants/ItemNames.d.ts +2 -0
  8. package/dist/Constants/ItemNames.js +8 -0
  9. package/dist/Constants/RuneIds.d.ts +2 -0
  10. package/dist/Constants/RuneIds.js +12 -0
  11. package/dist/Constants/RuneNames.d.ts +2 -0
  12. package/dist/Constants/RuneNames.js +8 -0
  13. package/dist/Constants/StatRunes.d.ts +11 -0
  14. package/dist/Constants/StatRunes.js +14 -0
  15. package/dist/Constants/SummonerIds.d.ts +2 -0
  16. package/dist/Constants/SummonerIds.js +8 -0
  17. package/dist/Constants/SummonerKeys.d.ts +2 -0
  18. package/dist/Constants/SummonerKeys.js +8 -0
  19. package/dist/Constants/SummonerNames.d.ts +2 -0
  20. package/dist/Constants/SummonerNames.js +8 -0
  21. package/dist/Helpers/generateItemsByName.d.ts +1 -0
  22. package/dist/Helpers/generateItemsByName.js +25 -0
  23. package/dist/Helpers/generateRunesById.d.ts +1 -0
  24. package/dist/Helpers/generateRunesById.js +20 -0
  25. package/dist/Helpers/generateRunesByName.d.ts +1 -0
  26. package/dist/Helpers/generateRunesByName.js +20 -0
  27. package/dist/Helpers/generateSummonersByKey.d.ts +1 -0
  28. package/dist/Helpers/generateSummonersByKey.js +24 -0
  29. package/dist/Helpers/generateSummonersByName.d.ts +1 -0
  30. package/dist/Helpers/generateSummonersByName.js +24 -0
  31. package/dist/generated/itemByKey.json +1 -0
  32. package/dist/generated/itemByName.json +1 -0
  33. package/dist/generated/runesById.json +1 -0
  34. package/dist/generated/runesByName.json +1 -0
  35. package/dist/generated/summonerByKey.json +1 -0
  36. package/dist/generated/summonerByName.json +1 -0
  37. package/dist/index.d.ts +11117 -0
  38. package/dist/index.js +31 -1
  39. package/dist/scripts/generate-all.js +10 -0
  40. package/dist/types/index.d.ts +18 -1
  41. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -17,7 +17,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
17
17
  return (mod && mod.__esModule) ? mod : { "default": mod };
18
18
  };
19
19
  Object.defineProperty(exports, "__esModule", { value: true });
20
- exports.championByName = exports.championByKey = exports.DDPaths = exports.summoner = exports.runesReforged = exports.item = exports.champion = void 0;
20
+ exports.summonerByName = exports.summonerByKey = exports.runesByName = exports.runesById = exports.itemByName = exports.championByName = exports.championByKey = exports.SummonerNames = exports.SummonerKeys = exports.SummonerIds = exports.StatRunes = exports.RuneNames = exports.RuneIds = exports.ItemNames = exports.ItemKeys = exports.DDPaths = exports.ChampionNames = exports.ChampionKeys = exports.summoner = exports.runesReforged = exports.item = exports.champion = void 0;
21
21
  const champion_json_1 = __importDefault(require("./assets/champion.json"));
22
22
  const item_json_1 = __importDefault(require("./assets/item.json"));
23
23
  const runesReforged_json_1 = __importDefault(require("./assets/runesReforged.json"));
@@ -26,11 +26,41 @@ exports.champion = champion_json_1.default;
26
26
  exports.item = item_json_1.default;
27
27
  exports.runesReforged = runesReforged_json_1.default;
28
28
  exports.summoner = summoner_json_1.default;
29
+ var ChampionKeys_1 = require("./Constants/ChampionKeys");
30
+ Object.defineProperty(exports, "ChampionKeys", { enumerable: true, get: function () { return ChampionKeys_1.ChampionKeys; } });
31
+ var ChampionNames_1 = require("./Constants/ChampionNames");
32
+ Object.defineProperty(exports, "ChampionNames", { enumerable: true, get: function () { return ChampionNames_1.ChampionNames; } });
29
33
  var DDPaths_1 = require("./Constants/DDPaths");
30
34
  Object.defineProperty(exports, "DDPaths", { enumerable: true, get: function () { return DDPaths_1.DDPaths; } });
35
+ var ItemKeys_1 = require("./Constants/ItemKeys");
36
+ Object.defineProperty(exports, "ItemKeys", { enumerable: true, get: function () { return ItemKeys_1.ItemKeys; } });
37
+ var ItemNames_1 = require("./Constants/ItemNames");
38
+ Object.defineProperty(exports, "ItemNames", { enumerable: true, get: function () { return ItemNames_1.ItemNames; } });
39
+ var RuneIds_1 = require("./Constants/RuneIds");
40
+ Object.defineProperty(exports, "RuneIds", { enumerable: true, get: function () { return RuneIds_1.RuneIds; } });
41
+ var RuneNames_1 = require("./Constants/RuneNames");
42
+ Object.defineProperty(exports, "RuneNames", { enumerable: true, get: function () { return RuneNames_1.RuneNames; } });
43
+ var StatRunes_1 = require("./Constants/StatRunes");
44
+ Object.defineProperty(exports, "StatRunes", { enumerable: true, get: function () { return StatRunes_1.StatRunes; } });
45
+ var SummonerIds_1 = require("./Constants/SummonerIds");
46
+ Object.defineProperty(exports, "SummonerIds", { enumerable: true, get: function () { return SummonerIds_1.SummonerIds; } });
47
+ var SummonerKeys_1 = require("./Constants/SummonerKeys");
48
+ Object.defineProperty(exports, "SummonerKeys", { enumerable: true, get: function () { return SummonerKeys_1.SummonerKeys; } });
49
+ var SummonerNames_1 = require("./Constants/SummonerNames");
50
+ Object.defineProperty(exports, "SummonerNames", { enumerable: true, get: function () { return SummonerNames_1.SummonerNames; } });
31
51
  const championByKey_json_1 = __importDefault(require("./generated/championByKey.json"));
32
52
  const championByName_json_1 = __importDefault(require("./generated/championByName.json"));
53
+ const itemByName_json_1 = __importDefault(require("./generated/itemByName.json"));
54
+ const runesById_json_1 = __importDefault(require("./generated/runesById.json"));
55
+ const runesByName_json_1 = __importDefault(require("./generated/runesByName.json"));
56
+ const summonerByKey_json_1 = __importDefault(require("./generated/summonerByKey.json"));
57
+ const summonerByName_json_1 = __importDefault(require("./generated/summonerByName.json"));
33
58
  exports.championByKey = championByKey_json_1.default;
34
59
  exports.championByName = championByName_json_1.default;
60
+ exports.itemByName = itemByName_json_1.default;
61
+ exports.runesById = runesById_json_1.default;
62
+ exports.runesByName = runesByName_json_1.default;
63
+ exports.summonerByKey = summonerByKey_json_1.default;
64
+ exports.summonerByName = summonerByName_json_1.default;
35
65
  __exportStar(require("./types"), exports);
36
66
  __exportStar(require("./types/Meta"), exports);
@@ -2,8 +2,18 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const generateChampionsByKey_1 = require("../Helpers/generateChampionsByKey");
4
4
  const generateChampionsByName_1 = require("../Helpers/generateChampionsByName");
5
+ const generateItemsByName_1 = require("../Helpers/generateItemsByName");
6
+ const generateRunesById_1 = require("../Helpers/generateRunesById");
7
+ const generateRunesByName_1 = require("../Helpers/generateRunesByName");
8
+ const generateSummonersByKey_1 = require("../Helpers/generateSummonersByKey");
9
+ const generateSummonersByName_1 = require("../Helpers/generateSummonersByName");
5
10
  const generateJSONs = () => {
6
11
  (0, generateChampionsByKey_1.generateChampionsByKey)();
7
12
  (0, generateChampionsByName_1.generateChampionsByName)();
13
+ (0, generateItemsByName_1.generateItemsByName)();
14
+ (0, generateRunesById_1.generateRunesById)();
15
+ (0, generateRunesByName_1.generateRunesByName)();
16
+ (0, generateSummonersByKey_1.generateSummonersByKey)();
17
+ (0, generateSummonersByName_1.generateSummonersByName)();
8
18
  };
9
19
  generateJSONs();
@@ -1,9 +1,26 @@
1
1
  import championByKey from '../generated/championByKey.json';
2
2
  import championByName from '../generated/championByName.json';
3
- export declare type ChampionName = keyof typeof championByName.data;
3
+ import item from '../assets/item.json';
4
+ import itemByName from '../generated/itemByName.json';
5
+ import summoner from '../assets/summoner.json';
6
+ import summonerByKey from '../generated/summonerByKey.json';
7
+ import summonerByName from '../generated/summonerByName.json';
8
+ import runesById from '../generated/runesById.json';
9
+ import { StatRunes } from '../Constants/StatRunes';
10
+ import runesByName from '../generated/runesByName.json';
4
11
  export declare type ChampionKey = keyof typeof championByKey.data;
12
+ export declare type ChampionName = keyof typeof championByName.data;
13
+ export declare type ItemKey = keyof typeof item.data;
14
+ export declare type ItemName = keyof typeof itemByName.data;
15
+ export declare type SummonerId = keyof typeof summoner.data;
16
+ export declare type SummonerKey = keyof typeof summonerByKey.data;
17
+ export declare type SummonerName = keyof typeof summonerByName.data;
18
+ export declare type RuneId = keyof typeof runesById | keyof typeof StatRunes;
19
+ export declare type RuneName = keyof typeof runesByName;
5
20
  export declare type XP = number;
6
21
  export declare type Minute = number;
7
22
  export declare type TPosition = 'TOP' | 'JUNGLE' | 'MIDDLE' | 'BOTTOM' | 'UTILITY';
8
23
  export declare type TLane = 'TOP' | 'JUNGLE' | 'MIDDLE' | 'BOTTOM';
9
24
  export declare type TRole = 'NONE' | 'SOLO' | 'CARRY' | 'SUPPORT';
25
+ export declare type Level = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18;
26
+ export declare type Skill = 'Q' | 'W' | 'E' | 'R';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lol-constants",
3
- "version": "0.4.0",
3
+ "version": "0.7.0",
4
4
  "description": "League of Legends constants and data resources, such as champion, item, runes reforged, summoner.",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -10,9 +10,9 @@
10
10
  ],
11
11
  "scripts": {
12
12
  "clean-build": "rmdir /s /q dist && tsc",
13
- "publish-new-major": "npm run build && npm version major && npm publish",
14
- "publish-new-minor": "npm run build && npm version minor && npm publish",
15
- "publish-new-patch": "npm run build && npm version patch && npm publish",
13
+ "publish-new-major": "tsc && npm version major && npm publish",
14
+ "publish-new-minor": "tsc && npm version minor && npm publish",
15
+ "publish-new-patch": "tsc && npm version patch && npm publish",
16
16
  "generate": "node dist/scripts/generate-all && tsc"
17
17
  },
18
18
  "devDependencies": {