lol-constants 2.3.1 → 2.5.0
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +17 -0
- package/assets/constants/BootsItemNames.d.ts +1 -1
- package/assets/constants/BootsItemNames.js +1 -1
- package/assets/constants/Champion.d.ts +164 -164
- package/assets/constants/Champion.js +1 -1
- package/assets/constants/Item.d.ts +1051 -647
- package/assets/constants/Item.js +1 -1
- package/assets/constants/LegendaryItemNames.d.ts +1 -1
- package/assets/constants/LegendaryItemNames.js +4 -4
- package/assets/constants/MythicItemNames.d.ts +1 -1
- package/assets/constants/MythicItemNames.js +34 -3
- package/assets/constants/RunesReforged.d.ts +1 -1
- package/assets/constants/RunesReforged.js +1 -1
- package/assets/constants/Summoner.d.ts +2 -2
- package/assets/constants/Summoner.js +1 -1
- package/assets/scripts/constants/RuneIdComment.d.ts +1 -1
- package/assets/scripts/constants/RuneIdComment.js +14 -6
- package/assets/scripts/generate-all.d.ts +3 -3
- package/assets/scripts/generate-all.js +3 -3
- package/assets/scripts/generate-non-stat-rune-ids-num.d.ts +1 -0
- package/assets/scripts/generate-non-stat-rune-ids-num.js +23 -0
- package/assets/scripts/generate-non-stat-rune-ids.d.ts +1 -0
- package/assets/scripts/generate-non-stat-rune-ids.js +24 -0
- package/assets/scripts/generate-non-stat-rune-names.d.ts +1 -0
- package/assets/scripts/generate-non-stat-rune-names.js +22 -0
- package/assets/scripts/generate-rune-sets-by-rune-names-num.js +16 -11
- package/assets/scripts/generate-rune-sets-by-rune-names.js +11 -11
- package/assets/scripts/generate-rune-sets.js +11 -11
- package/core/constants/Continents.d.ts +8 -0
- package/core/constants/Continents.js +13 -0
- package/core/constants/DataDragonUrls.d.ts +11 -0
- package/core/constants/DataDragonUrls.js +14 -2
- package/core/constants/Items/ItemKeys.d.ts +10 -0
- package/core/constants/Items/ItemKeys.js +1 -1
- package/core/constants/Items/ItemKeysNum.d.ts +10 -0
- package/core/constants/Items/ItemKeysNum.js +1 -1
- package/core/constants/Items/ItemNames.d.ts +10 -0
- package/core/constants/Items/ItemNames.js +1 -1
- package/core/constants/Items/LegendaryItemKeys.d.ts +4 -4
- package/core/constants/Items/LegendaryItemKeys.js +1 -1
- package/core/constants/Items/LegendaryItemKeysNum.d.ts +4 -4
- package/core/constants/Items/LegendaryItemKeysNum.js +1 -1
- package/core/constants/Items/LegendaryItemNames.d.ts +4 -4
- package/core/constants/Items/LegendaryItemNames.js +1 -1
- package/core/constants/Items/MythicItemKeys.d.ts +33 -3
- package/core/constants/Items/MythicItemKeys.js +1 -1
- package/core/constants/Items/MythicItemKeysNum.d.ts +33 -3
- package/core/constants/Items/MythicItemKeysNum.js +1 -1
- package/core/constants/Items/MythicItemNames.d.ts +33 -3
- package/core/constants/Items/MythicItemNames.js +1 -1
- package/core/constants/Locales.d.ts +29 -1
- package/core/constants/Locales.js +29 -1
- package/core/constants/MapIds.d.ts +17 -0
- package/core/constants/MapIds.js +22 -0
- package/core/constants/ParticipantIds.d.ts +14 -0
- package/core/constants/ParticipantIds.js +19 -0
- package/core/constants/PlatformApiUris.d.ts +20 -0
- package/core/constants/PlatformApiUris.js +25 -0
- package/core/constants/PlatformIds.d.ts +8 -0
- package/core/constants/PlatformIds.js +11 -1
- package/core/constants/QueueIds.d.ts +56 -0
- package/core/constants/QueueIds.js +61 -0
- package/core/constants/RegionalApiUris.d.ts +8 -0
- package/core/constants/RegionalApiUris.js +13 -0
- package/core/constants/Regions.d.ts +8 -0
- package/core/constants/Regions.js +11 -8
- package/core/constants/Runes/NonStatRuneIds.d.ts +88 -0
- package/core/constants/Runes/NonStatRuneIds.js +4 -0
- package/core/constants/Runes/NonStatRuneIdsNum.d.ts +66 -0
- package/core/constants/Runes/NonStatRuneIdsNum.js +4 -0
- package/core/constants/Runes/NonStatRuneNames.d.ts +66 -0
- package/core/constants/Runes/NonStatRuneNames.js +4 -0
- package/core/constants/Runes/RuneSets.d.ts +2 -2
- package/core/constants/Runes/RuneSets.js +3 -3
- package/core/constants/Runes/RuneSetsByRuneNames.d.ts +30 -14
- package/core/constants/Runes/RuneSetsByRuneNames.js +3 -3
- package/core/constants/Runes/RuneSetsByRuneNamesNum.d.ts +48 -2
- package/core/constants/Runes/RuneSetsByRuneNamesNum.js +3 -3
- package/core/constants/Runes/TreeRuneIds.d.ts +5 -5
- package/core/constants/SkillSlots.d.ts +1 -1
- package/core/constants/SkillSlots.js +1 -1
- package/core/constants/TeamIds.d.ts +6 -0
- package/core/constants/TeamIds.js +11 -0
- package/core/helpers/Champions/isChampionKeyNum.d.ts +2 -0
- package/core/helpers/Champions/isChampionKeyNum.js +8 -0
- package/core/helpers/Items/isItemKeyNum.d.ts +2 -0
- package/core/helpers/Items/isItemKeyNum.js +8 -0
- package/core/helpers/Runes/getNonStatRuneIdByName.d.ts +3 -0
- package/core/helpers/Runes/getNonStatRuneIdByName.js +8 -0
- package/core/helpers/Runes/getNonStatRuneNameById.d.ts +3 -0
- package/core/helpers/Runes/getNonStatRuneNameById.js +8 -0
- package/core/helpers/Runes/isDominationRuneId.d.ts +2 -0
- package/core/helpers/Runes/isDominationRuneId.js +8 -0
- package/core/helpers/Runes/isDominationRuneIdNum.d.ts +2 -0
- package/core/helpers/Runes/isDominationRuneIdNum.js +8 -0
- package/core/helpers/Runes/isDominationRuneName.d.ts +2 -0
- package/core/helpers/Runes/isDominationRuneName.js +8 -0
- package/core/helpers/Runes/isInspirationRuneId.d.ts +2 -0
- package/core/helpers/Runes/isInspirationRuneId.js +8 -0
- package/core/helpers/Runes/isInspirationRuneIdNum.d.ts +2 -0
- package/core/helpers/Runes/isInspirationRuneIdNum.js +8 -0
- package/core/helpers/Runes/isInspirationRuneName.d.ts +2 -0
- package/core/helpers/Runes/isInspirationRuneName.js +8 -0
- package/core/helpers/Runes/isKeystoneRuneIdNum.d.ts +2 -0
- package/core/helpers/Runes/isKeystoneRuneIdNum.js +8 -0
- package/core/helpers/Runes/isKeystoneRuneName.d.ts +2 -0
- package/core/helpers/Runes/isKeystoneRuneName.js +8 -0
- package/core/helpers/Runes/isNonStatRuneId.d.ts +2 -0
- package/core/helpers/Runes/isNonStatRuneId.js +8 -0
- package/core/helpers/Runes/isNonStatRuneIdNum.d.ts +2 -0
- package/core/helpers/Runes/isNonStatRuneIdNum.js +8 -0
- package/core/helpers/Runes/isNonStatRuneName.d.ts +2 -0
- package/core/helpers/Runes/isNonStatRuneName.js +8 -0
- package/core/helpers/Runes/isPrecisionRuneId.d.ts +2 -0
- package/core/helpers/Runes/isPrecisionRuneId.js +8 -0
- package/core/helpers/Runes/isPrecisionRuneIdNum.d.ts +2 -0
- package/core/helpers/Runes/isPrecisionRuneIdNum.js +8 -0
- package/core/helpers/Runes/isPrecisionRuneName.d.ts +2 -0
- package/core/helpers/Runes/isPrecisionRuneName.js +8 -0
- package/core/helpers/Runes/isResolveRuneId.d.ts +2 -0
- package/core/helpers/Runes/isResolveRuneId.js +8 -0
- package/core/helpers/Runes/isResolveRuneIdNum.d.ts +2 -0
- package/core/helpers/Runes/isResolveRuneIdNum.js +8 -0
- package/core/helpers/Runes/isResolveRuneName.d.ts +2 -0
- package/core/helpers/Runes/isResolveRuneName.js +8 -0
- package/core/helpers/Runes/isRuneIdNum.d.ts +2 -0
- package/core/helpers/Runes/isRuneIdNum.js +8 -0
- package/core/helpers/Runes/isSorceryRuneId.d.ts +2 -0
- package/core/helpers/Runes/isSorceryRuneId.js +8 -0
- package/core/helpers/Runes/isSorceryRuneIdNum.d.ts +2 -0
- package/core/helpers/Runes/isSorceryRuneIdNum.js +8 -0
- package/core/helpers/Runes/isSorceryRuneName.d.ts +2 -0
- package/core/helpers/Runes/isSorceryRuneName.js +8 -0
- package/core/helpers/Runes/isStatRuneIdNum.d.ts +2 -0
- package/core/helpers/Runes/isStatRuneIdNum.js +8 -0
- package/core/helpers/Spells/isSpellKeyNum.d.ts +2 -0
- package/core/helpers/Spells/isSpellKeyNum.js +8 -0
- package/core/index.d.ts +33 -12
- package/core/index.js +33 -12
- package/core/types/types.d.ts +199 -82
- package/package.json +1 -1
package/README.md
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
Provides constants and types for League of Legends related stuff within the context of [Riot APIs](https://developer.riotgames.com/docs/lol). Types such as [ChampionId](asd), [ChampionName](asd), [ItemKey](asd), [RuneId](asd), [SpellName](asd), [Position](asd), [Queue](asd), [RankedTier](asd), [Region](asd) and more are provided. Certain URLs and URIs are available as constants as well in [DataDragonUrls](asd), [PlatformApiUris](asd), [RegionalApiUris](asd).
|
2
|
+
|
3
|
+
Advantages:
|
4
|
+
- Four categories — champions, items, runes, summoner spells — are armed with getter functions that exchange between id–key–name such as [getChampionNameByKey](asd)–[getChampionIdByName](asd)–[getChampionKeyById](asd)
|
5
|
+
- Types can be validated through type validating functions such as [isChampionName](asd)
|
6
|
+
- Type validation functions such as [isChampionName](asd) and getter functions such as [getChampionNameByKey](asd) are instantaneous $O(1)$ and do not iterate over many elements
|
7
|
+
|
8
|
+
<!-- - Runes and items are also provided in a categorized way: [StatRuneId](asd), [NonStatRuneId](asd), [DominationRuneId](asd) etc. and [MythicItemName](asd), [LegendaryItemName](asd), [BootsItemName](asd) etc. -->
|
9
|
+
|
10
|
+
# Champions
|
11
|
+
| constants | types | getters
|
12
|
+
| --- | --- |
|
13
|
+
| `ChampionIds`, `ChampionKeys` | `ChampionId`, `ChampionKey`, `ChampionKeyNum`, `ChampionName` |
|
14
|
+
# Items
|
15
|
+
# Runes
|
16
|
+
# Summoner spells
|
17
|
+
# Other
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/**
|
2
|
-
* Last updated on patch: `13.
|
2
|
+
* Last updated on patch: `13.10`
|
3
3
|
*/
|
4
4
|
export declare const BootsItemNames: readonly ["Boots", "Berserker's Greaves", "Boots of Swiftness", "Ionian Boots of Lucidity", "Mercury's Treads", "Mobility Boots", "Plated Steelcaps", "Sorcerer's Shoes", "Slightly Magical Footwear"];
|
5
5
|
export type BootsItemName = typeof BootsItemNames[number];
|