react-router-pagination 3.2.145 → 3.2.146

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-router-pagination",
3
- "version": "3.2.145",
3
+ "version": "3.2.146",
4
4
  "description": "A React Router Pagination component",
5
5
  "main": "./src/index.mjs",
6
6
  "type": "module",
@@ -54,8 +54,8 @@
54
54
  "core-js": "^3.37.1",
55
55
  "cross-env": "^7.0.3",
56
56
  "eslint": "8.57.0",
57
+ "eslint-config-love": "47.0.0",
57
58
  "eslint-config-standard": "^17.1.0",
58
- "eslint-config-standard-with-typescript": "^43.0.1",
59
59
  "eslint-import-resolver-babel-module": "^5.3.2",
60
60
  "eslint-plugin-react": "^7.34.2",
61
61
  "eslint-plugin-storybook": "^0.8.0",
package/src/index.d.mts CHANGED
@@ -40,3 +40,14 @@ declare namespace ReactRouterPaginationTypes {
40
40
  format?: string
41
41
  }
42
42
  }
43
+
44
+ declare module 'react-router-pagination' {
45
+ import type { JSX } from 'react'
46
+
47
+ export default class Pagination {
48
+ static calculateTotalPages (totalItemsInCollection: number | string, itemsPerPage: number | string): number
49
+ static calculatePageNumber (pageNumber: number | string, totalPages: number | string): number
50
+
51
+ render (): JSX.Element
52
+ }
53
+ }
package/src/index.tsx CHANGED
@@ -1,3 +1,5 @@
1
+ import type { JSX } from 'react'
2
+ import type ReactRouterPaginationTypes from 'react-router-pagination'
1
3
  import React, { Component } from 'react'
2
4
 
3
5
  import {
@@ -1,5 +1,7 @@
1
1
  import debug from 'debug'
2
2
 
3
+ import type ReactRouterPaginationTypes from 'react-router-pagination'
4
+
3
5
  import AbstractPagination, {
4
6
  toInteger,
5
7
  calculateTotalPages,
@@ -1,6 +1,8 @@
1
1
  /**
2
2
  * Pagination component
3
3
  */
4
+ import type { JSX } from 'react'
5
+ import type ReactRouterPaginationTypes from 'react-router-pagination'
4
6
  import React, { Component } from 'react'
5
7
 
6
8
  import {
@@ -1,5 +1,7 @@
1
1
  import debug from 'debug'
2
2
 
3
+ import type ReactRouterPaginationTypes from 'react-router-pagination'
4
+
3
5
  import AbstractPagination, {
4
6
  toInteger,
5
7
  calculateTotalPages,