pokenode-ts 1.13.1 → 1.15.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.
package/CHANGELOG.md CHANGED
@@ -1,7 +1,8 @@
1
- ## [1.13.1](https://github.com/Gabb-c/pokenode-ts/compare/v1.13.0...v1.13.1) (2022-04-28)
1
+ # [1.15.0](https://github.com/Gabb-c/pokenode-ts/compare/v1.14.0...v1.15.0) (2022-07-11)
2
2
 
3
3
 
4
- ### Bug Fixes
4
+ ### Features
5
5
 
6
- * **models:** Move interface typo ([bcd44e7](https://github.com/Gabb-c/pokenode-ts/commit/bcd44e727e7f266073340aa430602cea18efe1b7))
7
- * **models:** namedapiresourcelist result interface [#413](https://github.com/Gabb-c/pokenode-ts/issues/413) ([88787be](https://github.com/Gabb-c/pokenode-ts/commit/88787bedc0ef4838851e2aafdbeff9dd9e7f398b))
6
+ * **constants:** update MoveAilments enum ([d48fa43](https://github.com/Gabb-c/pokenode-ts/commit/d48fa43dcb01ccf2c426f7af78cc98161f90de67))
7
+ * **constants:** update Regions enum ([5e75912](https://github.com/Gabb-c/pokenode-ts/commit/5e759120d6d6de0efcbd5e9a71cd27df37bf189c))
8
+ * **deps:** update pino and pino-pretty ([99e92b5](https://github.com/Gabb-c/pokenode-ts/commit/99e92b5f7a21bdc15d57ac476e4ff527033186e0))
@@ -9,7 +9,7 @@ const base_1 = require("../structures/base");
9
9
  *
10
10
  * Client used to access the Machine Endpoints:
11
11
  * - [Machines](https://pokeapi.co/docs/v2#machines)
12
- * ---
12
+ *
13
13
  * See [PokéAPI Documentation](https://pokeapi.co/docs/v2#machines-section)
14
14
  */
15
15
  class MachineClient extends base_1.BaseClient {
@@ -11,6 +11,7 @@ var Regions;
11
11
  Regions[Regions["KALOS"] = 6] = "KALOS";
12
12
  Regions[Regions["ALOLA"] = 7] = "ALOLA";
13
13
  Regions[Regions["GALAR"] = 8] = "GALAR";
14
+ Regions[Regions["HISUI"] = 9] = "HISUI";
14
15
  })(Regions = exports.Regions || (exports.Regions = {}));
15
16
  var PalParkAreas;
16
17
  (function (PalParkAreas) {
@@ -24,6 +24,7 @@ var MoveAilmtents;
24
24
  MoveAilmtents[MoveAilmtents["PERISH_SONG"] = 20] = "PERISH_SONG";
25
25
  MoveAilmtents[MoveAilmtents["INGRAIN"] = 21] = "INGRAIN";
26
26
  MoveAilmtents[MoveAilmtents["SILENCE"] = 24] = "SILENCE";
27
+ MoveAilmtents[MoveAilmtents["TAR_SHOT"] = 42] = "TAR_SHOT";
27
28
  })(MoveAilmtents = exports.MoveAilmtents || (exports.MoveAilmtents = {}));
28
29
  var MoveBattleStyles;
29
30
  (function (MoveBattleStyles) {
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- // Generated by dts-bundle-generator v6.9.0
1
+ // Generated by dts-bundle-generator v6.12.0
2
2
 
3
3
  import { AxiosInstance } from 'axios';
4
4
  import { IAxiosCacheAdapterOptions } from 'axios-cache-adapter';
@@ -408,7 +408,7 @@ export interface ChainLink {
408
408
  /** The Pokémon species at this point in the evolution chain */
409
409
  species: NamedAPIResource;
410
410
  /** All details regarding the specific details of the referenced Pokémon species evolution */
411
- evolution_detail: EvolutionDetail[];
411
+ evolution_details: EvolutionDetail[];
412
412
  /** A List of chain objects */
413
413
  evolves_to: ChainLink[];
414
414
  }
@@ -484,7 +484,7 @@ export interface PokemonEntry {
484
484
  /** The index of this Pokémon species entry within the Pokédex */
485
485
  entry_number: number;
486
486
  /** The Pokémon species being encountered */
487
- pokemon_species: NamedAPIResource[];
487
+ pokemon_species: NamedAPIResource;
488
488
  }
489
489
  /**
490
490
  * ## Pokedex
@@ -1270,7 +1270,7 @@ export interface PokemonStat {
1270
1270
  /** The stat the Pokémon has */
1271
1271
  stat: NamedAPIResource;
1272
1272
  /** The effort points (EV) the Pokémon has in the stat */
1273
- effort: 0 | 1 | 2 | 3;
1273
+ effort: number;
1274
1274
  /** The base value of the stat */
1275
1275
  base_stat: number;
1276
1276
  }
@@ -1482,7 +1482,7 @@ export interface RubySapphire {
1482
1482
  /** Generation-IV Sprites */
1483
1483
  export interface GenerationIVSprites {
1484
1484
  /** Diamond-pearl Generation sprites of this Pokémon */
1485
- "diamond-perl": DiamondPearl;
1485
+ "diamond-pearl": DiamondPearl;
1486
1486
  /** Heartgold-Soulsilver sprites of this Pokémon */
1487
1487
  "heartgold-soulsilver": HeartgoldSoulsilver;
1488
1488
  /** Platinum sprites of this Pokémon */
@@ -2697,7 +2697,7 @@ export declare class LocationClient extends BaseClient {
2697
2697
  *
2698
2698
  * Client used to access the Machine Endpoints:
2699
2699
  * - [Machines](https://pokeapi.co/docs/v2#machines)
2700
- * ---
2700
+ *
2701
2701
  * See [PokéAPI Documentation](https://pokeapi.co/docs/v2#machines-section)
2702
2702
  */
2703
2703
  export declare class MachineClient extends BaseClient {
@@ -3595,7 +3595,8 @@ export declare enum Regions {
3595
3595
  UNOVA = 5,
3596
3596
  KALOS = 6,
3597
3597
  ALOLA = 7,
3598
- GALAR = 8
3598
+ GALAR = 8,
3599
+ HISUI = 9
3599
3600
  }
3600
3601
  export declare enum PalParkAreas {
3601
3602
  FOREST = 1,
@@ -3625,7 +3626,8 @@ export declare enum MoveAilmtents {
3625
3626
  EMBARGO = 19,
3626
3627
  PERISH_SONG = 20,
3627
3628
  INGRAIN = 21,
3628
- SILENCE = 24
3629
+ SILENCE = 24,
3630
+ TAR_SHOT = 42
3629
3631
  }
3630
3632
  export declare enum MoveBattleStyles {
3631
3633
  ATTACK = 1,
package/jest.config.js ADDED
@@ -0,0 +1,25 @@
1
+ // @ts-check
2
+
3
+ /** @type {import('@jest/types').Config.InitialOptions} */
4
+ const jestConfig = {
5
+ displayName: 'pokenode-ts',
6
+ clearMocks: true,
7
+ testEnvironment: 'node',
8
+ transform: {
9
+ '^.+\\.(t|j)sx?$': '@swc/jest',
10
+ },
11
+ collectCoverageFrom: [
12
+ 'src/**/*.ts',
13
+ '!**/*.d.ts',
14
+ '!**/node_modules/**',
15
+ '!**/dist/**',
16
+ '!**/src/models/**',
17
+ '!**/src/constants/**',
18
+ '!**/src/config/**',
19
+ '!**/src/structures/**',
20
+ ],
21
+ testMatch: ['**/__tests__/**/*.[jt]s?(x)', '**/?(*.)+(spec|test).[tj]s?(x)'],
22
+ testPathIgnorePatterns: ['/node_modules/', '/dist/'],
23
+ };
24
+
25
+ module.exports = jestConfig;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pokenode-ts",
3
- "version": "1.13.1",
3
+ "version": "1.15.0",
4
4
  "private": false,
5
5
  "description": "A lightweight Node.js wrapper for the PokéAPI with built-in types.",
6
6
  "keywords": [
@@ -44,64 +44,58 @@
44
44
  "test:watch": "jest --watch --verbose --colors --expand --maxWorkers=25%",
45
45
  "types": "dts-bundle-generator --config dts-generator.json"
46
46
  },
47
- "config": {
48
- "commitizen": {
49
- "path": "@commitlint/cz-commitlint"
50
- }
51
- },
52
47
  "dependencies": {
53
48
  "axios": "^0.27.2",
54
49
  "axios-cache-adapter": "^2.7.3",
55
- "pino": "^7.11.0",
56
- "pino-pretty": "^7.6.1",
50
+ "pino": "^8.1.0",
51
+ "pino-pretty": "^8.1.0",
57
52
  "tslib": "^2.4.0"
58
53
  },
59
54
  "devDependencies": {
60
- "@babel/cli": "^7.17.6",
61
- "@babel/core": "^7.17.9",
62
- "@babel/node": "^7.16.8",
63
- "@babel/preset-env": "^7.16.11",
64
- "@babel/preset-typescript": "^7.16.7",
65
- "@commitlint/cli": "^16.2.4",
66
- "@commitlint/config-conventional": "^16.2.4",
55
+ "@babel/cli": "^7.18.6",
56
+ "@babel/core": "^7.18.6",
57
+ "@babel/node": "^7.18.6",
58
+ "@babel/preset-env": "^7.18.6",
59
+ "@babel/preset-typescript": "^7.18.6",
60
+ "@commitlint/cli": "^17.0.3",
61
+ "@commitlint/config-conventional": "^17.0.3",
67
62
  "@semantic-release/changelog": "^6.0.1",
68
63
  "@semantic-release/commit-analyzer": "^9.0.2",
69
64
  "@semantic-release/git": "^10.0.1",
70
- "@semantic-release/github": "^8.0.4",
65
+ "@semantic-release/github": "^8.0.5",
71
66
  "@semantic-release/npm": "^9.0.1",
72
67
  "@semantic-release/release-notes-generator": "^10.0.3",
73
- "@swc/core": "^1.2.173",
74
- "@swc/jest": "^0.2.20",
75
- "@types/jest": "^27.4.1",
76
- "@types/node": "^17.0.29",
77
- "@typescript-eslint/eslint-plugin": "^5.21.0",
78
- "@typescript-eslint/parser": "^5.21.0",
68
+ "@swc/core": "^1.2.211",
69
+ "@swc/jest": "^0.2.21",
70
+ "@types/jest": "^28.1.4",
71
+ "@types/node": "^18.0.3",
72
+ "@typescript-eslint/eslint-plugin": "^5.30.5",
73
+ "@typescript-eslint/parser": "^5.30.5",
79
74
  "babel-plugin-module-resolver": "^4.1.0",
80
- "conventional-changelog-conventionalcommits": "^4.6.3",
81
- "dts-bundle-generator": "^6.9.0",
82
- "eslint": "^8.14.0",
75
+ "dts-bundle-generator": "^6.12.0",
76
+ "eslint": "^8.19.0",
83
77
  "eslint-config-airbnb-base": "^15.0.0",
84
78
  "eslint-config-airbnb-typescript": "^17.0.0",
85
79
  "eslint-config-node": "^4.1.0",
86
80
  "eslint-config-prettier": "^8.5.0",
87
81
  "eslint-plugin-eslint-comments": "^3.2.0",
88
82
  "eslint-plugin-import": "^2.26.0",
89
- "eslint-plugin-jest": "^26.1.5",
83
+ "eslint-plugin-jest": "^26.5.3",
90
84
  "eslint-plugin-node": "^11.1.0",
91
- "eslint-plugin-prettier": "^4.0.0",
85
+ "eslint-plugin-prettier": "^4.2.1",
92
86
  "eslint-plugin-promise": "^6.0.0",
93
- "eslint-plugin-unicorn": "^42.0.0",
87
+ "eslint-plugin-unicorn": "^43.0.1",
94
88
  "http-status-codes": "^2.2.0",
95
- "husky": "^7.0.4",
89
+ "husky": "^8.0.1",
96
90
  "is-ci": "^3.0.1",
97
- "jest": "^28.0.2",
98
- "lint-staged": "^12.4.1",
99
- "lockfile-lint": "^4.7.4",
100
- "prettier": "^2.6.2",
101
- "semantic-release": "^19.0.2",
102
- "sort-package-json": "^1.55.0",
103
- "ts-node-dev": "^1.1.8",
104
- "typescript": "^4.6.3"
91
+ "jest": "^28.1.2",
92
+ "lint-staged": "^13.0.3",
93
+ "lockfile-lint": "^4.7.6",
94
+ "prettier": "^2.7.1",
95
+ "semantic-release": "^19.0.3",
96
+ "sort-package-json": "^1.57.0",
97
+ "ts-node-dev": "^2.0.0",
98
+ "typescript": "^4.7.4"
105
99
  },
106
100
  "engines": {
107
101
  "node": ">=14"