@semcore/pagination 3.2.9 → 3.2.10

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
@@ -2,6 +2,12 @@
2
2
 
3
3
  CHANGELOG.md standards are inspired by [keepachangelog.com](https://keepachangelog.com/en/1.0.0/).
4
4
 
5
+ ## [3.2.10] - 2022-10-04
6
+
7
+ ### Changed
8
+
9
+ - Version patch update due to children dependencies update (`@semcore/button` [4.0.17 ~> 4.0.18], `@semcore/flex-box` [4.5.11 ~> 4.5.12], `@semcore/icon` [2.32.1 ~> 2.32.2], `@semcore/input` [3.0.15 ~> 3.0.16], `@semcore/link` [4.1.4 ~> 4.1.5], `@semcore/utils` [3.37.1 ~> 3.37.2]).
10
+
5
11
  ## [3.2.9] - 2022-09-29
6
12
 
7
13
  ### Changed
@@ -86,20 +86,20 @@ var style = (
86
86
  /*__reshadow_css_start__*/
87
87
  _core.sstyled.insert(
88
88
  /*__inner_css_start__*/
89
- ".___SPagination_19cjt_gg_{display:flex;justify-content:flex-start;align-items:center}.___SNextPage_19cjt_gg_,.___SPrevPage_19cjt_gg_{align-self:center;margin-left:8px}.___SLabel_19cjt_gg_:not(:first-child){margin-left:16px}.___STotalPages_19cjt_gg_{align-self:center;line-height:normal}.___STotalPagesLabel_19cjt_gg_{margin-left:8px;margin-right:4px}.___SPageInput_19cjt_gg_{max-width:68px;margin-left:4px}.___SPageInputValue_19cjt_gg_:focus~.___SPageInputAddon_19cjt_gg_{visibility:visible;clip:auto;position:static}.___SPageInputAddon_19cjt_gg_{visibility:hidden;clip:rect(1px,1px,1px,1px);position:absolute}.___SLabel_19cjt_gg_,.___STotalPages_19cjt_gg_,.___STotalPagesLabel_19cjt_gg_{font-size:14px;line-height:1.42}"
89
+ ".___SPagination_10eev_gg_{display:flex;justify-content:flex-start;align-items:center}.___SNextPage_10eev_gg_,.___SPrevPage_10eev_gg_{align-self:center;margin-left:8px}.___SLabel_10eev_gg_:not(:first-child){margin-left:16px}.___STotalPages_10eev_gg_{align-self:center;line-height:normal}.___STotalPagesLabel_10eev_gg_{margin-left:8px;margin-right:4px}.___SPageInput_10eev_gg_{max-width:68px;margin-left:4px}.___SPageInputValue_10eev_gg_:focus~.___SPageInputAddon_10eev_gg_{visibility:visible;clip:auto;position:static}.___SPageInputAddon_10eev_gg_{visibility:hidden;clip:rect(1px,1px,1px,1px);position:absolute}.___SLabel_10eev_gg_,.___STotalPages_10eev_gg_,.___STotalPagesLabel_10eev_gg_{font-size:14px;line-height:1.42}"
90
90
  /*__inner_css_end__*/
91
- , "19cjt_gg_")
91
+ , "10eev_gg_")
92
92
  /*__reshadow_css_end__*/
93
93
  , {
94
- "__SPagination": "___SPagination_19cjt_gg_",
95
- "__SNextPage": "___SNextPage_19cjt_gg_",
96
- "__SPrevPage": "___SPrevPage_19cjt_gg_",
97
- "__SLabel": "___SLabel_19cjt_gg_",
98
- "__STotalPages": "___STotalPages_19cjt_gg_",
99
- "__STotalPagesLabel": "___STotalPagesLabel_19cjt_gg_",
100
- "__SPageInput": "___SPageInput_19cjt_gg_",
101
- "__SPageInputValue": "___SPageInputValue_19cjt_gg_",
102
- "__SPageInputAddon": "___SPageInputAddon_19cjt_gg_"
94
+ "__SPagination": "___SPagination_10eev_gg_",
95
+ "__SNextPage": "___SNextPage_10eev_gg_",
96
+ "__SPrevPage": "___SPrevPage_10eev_gg_",
97
+ "__SLabel": "___SLabel_10eev_gg_",
98
+ "__STotalPages": "___STotalPages_10eev_gg_",
99
+ "__STotalPagesLabel": "___STotalPagesLabel_10eev_gg_",
100
+ "__SPageInput": "___SPageInput_10eev_gg_",
101
+ "__SPageInputValue": "___SPageInputValue_10eev_gg_",
102
+ "__SPageInputAddon": "___SPageInputAddon_10eev_gg_"
103
103
  });
104
104
  var i18n = {
105
105
  de: _de["default"],
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ //# sourceMappingURL=index.d.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import { ComponentProps } from 'react';\nimport { CProps, PropGetterFn, ReturnEl } from '@semcore/core';\nimport { IBoxProps } from '@semcore/flex-box';\nimport Input, { IInputProps } from '@semcore/input';\nimport { ITextProps } from '@semcore/typography';\nimport Button from '@semcore/button';\nimport { IWithI18nEnhanceProps } from '@semcore/utils/lib/enhances/i18nEnhance';\n\nexport interface IPaginationProps extends IBoxProps, IWithI18nEnhanceProps {\n /**\n * Total number of pages\n * @default 1\n */\n totalPages?: number;\n /**\n * Active page number\n * @default 1\n */\n currentPage?: number;\n /**\n * Callback for changing the active page\n * @param pageNumber\n */\n onCurrentPageChange?: (pageNumber: number) => void;\n}\n\nexport interface ITotalPagesProps extends ITextProps, IWithI18nEnhanceProps {}\n\nexport interface IPageInputProps extends IInputProps, IWithI18nEnhanceProps {}\n\nexport interface IPaginationContext {\n getFirstPageProps: PropGetterFn;\n getPrevPageProps: PropGetterFn;\n getNextPageProps: PropGetterFn;\n getPageInputProps: PropGetterFn;\n getTotalPagesProps: PropGetterFn;\n}\n\nexport interface IPaginationHandlers {\n totalPages: (value: number) => void;\n currentPage: (value: number) => void;\n}\n\ndeclare const Pagination: (<T>(\n props: CProps<IPaginationProps & T, IPaginationContext, IPaginationHandlers>,\n) => ReturnEl) & {\n PrevPage: (props: ComponentProps<typeof Button>) => ReturnEl;\n NextPage: (props: ComponentProps<typeof Button>) => ReturnEl;\n FirstPage: (props: ComponentProps<typeof Button>) => ReturnEl;\n TotalPages: (props: CProps<ITotalPagesProps, {}, IPaginationHandlers>) => ReturnEl;\n PageInput: (<T>(props: CProps<IPageInputProps & T, {}, IPaginationHandlers>) => ReturnEl) & {\n Value: typeof Input.Value;\n Addon: typeof Input.Addon;\n };\n};\n\nexport default Pagination;\n"],"mappings":""}
@@ -52,20 +52,20 @@ var style = (
52
52
  /*__reshadow_css_start__*/
53
53
  _sstyled.insert(
54
54
  /*__inner_css_start__*/
55
- ".___SPagination_19cjt_gg_{display:flex;justify-content:flex-start;align-items:center}.___SNextPage_19cjt_gg_,.___SPrevPage_19cjt_gg_{align-self:center;margin-left:8px}.___SLabel_19cjt_gg_:not(:first-child){margin-left:16px}.___STotalPages_19cjt_gg_{align-self:center;line-height:normal}.___STotalPagesLabel_19cjt_gg_{margin-left:8px;margin-right:4px}.___SPageInput_19cjt_gg_{max-width:68px;margin-left:4px}.___SPageInputValue_19cjt_gg_:focus~.___SPageInputAddon_19cjt_gg_{visibility:visible;clip:auto;position:static}.___SPageInputAddon_19cjt_gg_{visibility:hidden;clip:rect(1px,1px,1px,1px);position:absolute}.___SLabel_19cjt_gg_,.___STotalPages_19cjt_gg_,.___STotalPagesLabel_19cjt_gg_{font-size:14px;line-height:1.42}"
55
+ ".___SPagination_10eev_gg_{display:flex;justify-content:flex-start;align-items:center}.___SNextPage_10eev_gg_,.___SPrevPage_10eev_gg_{align-self:center;margin-left:8px}.___SLabel_10eev_gg_:not(:first-child){margin-left:16px}.___STotalPages_10eev_gg_{align-self:center;line-height:normal}.___STotalPagesLabel_10eev_gg_{margin-left:8px;margin-right:4px}.___SPageInput_10eev_gg_{max-width:68px;margin-left:4px}.___SPageInputValue_10eev_gg_:focus~.___SPageInputAddon_10eev_gg_{visibility:visible;clip:auto;position:static}.___SPageInputAddon_10eev_gg_{visibility:hidden;clip:rect(1px,1px,1px,1px);position:absolute}.___SLabel_10eev_gg_,.___STotalPages_10eev_gg_,.___STotalPagesLabel_10eev_gg_{font-size:14px;line-height:1.42}"
56
56
  /*__inner_css_end__*/
57
- , "19cjt_gg_")
57
+ , "10eev_gg_")
58
58
  /*__reshadow_css_end__*/
59
59
  , {
60
- "__SPagination": "___SPagination_19cjt_gg_",
61
- "__SNextPage": "___SNextPage_19cjt_gg_",
62
- "__SPrevPage": "___SPrevPage_19cjt_gg_",
63
- "__SLabel": "___SLabel_19cjt_gg_",
64
- "__STotalPages": "___STotalPages_19cjt_gg_",
65
- "__STotalPagesLabel": "___STotalPagesLabel_19cjt_gg_",
66
- "__SPageInput": "___SPageInput_19cjt_gg_",
67
- "__SPageInputValue": "___SPageInputValue_19cjt_gg_",
68
- "__SPageInputAddon": "___SPageInputAddon_19cjt_gg_"
60
+ "__SPagination": "___SPagination_10eev_gg_",
61
+ "__SNextPage": "___SNextPage_10eev_gg_",
62
+ "__SPrevPage": "___SPrevPage_10eev_gg_",
63
+ "__SLabel": "___SLabel_10eev_gg_",
64
+ "__STotalPages": "___STotalPages_10eev_gg_",
65
+ "__STotalPagesLabel": "___STotalPagesLabel_10eev_gg_",
66
+ "__SPageInput": "___SPageInput_10eev_gg_",
67
+ "__SPageInputValue": "___SPageInputValue_10eev_gg_",
68
+ "__SPageInputAddon": "___SPageInputAddon_10eev_gg_"
69
69
  });
70
70
  var i18n = {
71
71
  de: de,
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=index.d.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.js","names":[],"sources":["../../src/index.d.ts"],"sourcesContent":["import { ComponentProps } from 'react';\nimport { CProps, PropGetterFn, ReturnEl } from '@semcore/core';\nimport { IBoxProps } from '@semcore/flex-box';\nimport Input, { IInputProps } from '@semcore/input';\nimport { ITextProps } from '@semcore/typography';\nimport Button from '@semcore/button';\nimport { IWithI18nEnhanceProps } from '@semcore/utils/lib/enhances/i18nEnhance';\n\nexport interface IPaginationProps extends IBoxProps, IWithI18nEnhanceProps {\n /**\n * Total number of pages\n * @default 1\n */\n totalPages?: number;\n /**\n * Active page number\n * @default 1\n */\n currentPage?: number;\n /**\n * Callback for changing the active page\n * @param pageNumber\n */\n onCurrentPageChange?: (pageNumber: number) => void;\n}\n\nexport interface ITotalPagesProps extends ITextProps, IWithI18nEnhanceProps {}\n\nexport interface IPageInputProps extends IInputProps, IWithI18nEnhanceProps {}\n\nexport interface IPaginationContext {\n getFirstPageProps: PropGetterFn;\n getPrevPageProps: PropGetterFn;\n getNextPageProps: PropGetterFn;\n getPageInputProps: PropGetterFn;\n getTotalPagesProps: PropGetterFn;\n}\n\nexport interface IPaginationHandlers {\n totalPages: (value: number) => void;\n currentPage: (value: number) => void;\n}\n\ndeclare const Pagination: (<T>(\n props: CProps<IPaginationProps & T, IPaginationContext, IPaginationHandlers>,\n) => ReturnEl) & {\n PrevPage: (props: ComponentProps<typeof Button>) => ReturnEl;\n NextPage: (props: ComponentProps<typeof Button>) => ReturnEl;\n FirstPage: (props: ComponentProps<typeof Button>) => ReturnEl;\n TotalPages: (props: CProps<ITotalPagesProps, {}, IPaginationHandlers>) => ReturnEl;\n PageInput: (<T>(props: CProps<IPageInputProps & T, {}, IPaginationHandlers>) => ReturnEl) & {\n Value: typeof Input.Value;\n Addon: typeof Input.Addon;\n };\n};\n\nexport default Pagination;\n"],"mappings":""}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@semcore/pagination",
3
3
  "description": "Semrush Pagination Component",
4
- "version": "3.2.9",
4
+ "version": "3.2.10",
5
5
  "main": "lib/cjs/index.js",
6
6
  "module": "lib/es6/index.js",
7
7
  "typings": "lib/types/index.d.ts",
@@ -9,7 +9,7 @@
9
9
  "author": "UI-kit team <ui-kit-team@semrush.com>",
10
10
  "license": "MIT",
11
11
  "scripts": {
12
- "build": "build --source=js",
12
+ "build": "pnpm semcore-builder --source=js",
13
13
  "test": "jest"
14
14
  },
15
15
  "dependencies": {
@@ -34,6 +34,7 @@
34
34
  "directory": "semcore/pagination"
35
35
  },
36
36
  "devDependencies": {
37
+ "@types/react": "16.8 - 17",
37
38
  "@semcore/jest-preset-ui": "1.0.0"
38
39
  }
39
40
  }
@@ -1,57 +0,0 @@
1
- import { ComponentProps } from 'react';
2
- import { CProps, PropGetterFn, ReturnEl } from '@semcore/core';
3
- import { IBoxProps } from '@semcore/flex-box';
4
- import Input, { IInputProps } from '@semcore/input';
5
- import { ITextProps } from '@semcore/typography';
6
- import Button from '@semcore/button';
7
- import { IWithI18nEnhanceProps } from '@semcore/utils/lib/enhances/i18nEnhance';
8
-
9
- export interface IPaginationProps extends IBoxProps, IWithI18nEnhanceProps {
10
- /**
11
- * Total number of pages
12
- * @default 1
13
- */
14
- totalPages?: number;
15
- /**
16
- * Active page number
17
- * @default 1
18
- */
19
- currentPage?: number;
20
- /**
21
- * Callback for changing the active page
22
- * @param pageNumber
23
- */
24
- onCurrentPageChange?: (pageNumber: number) => void;
25
- }
26
-
27
- export interface ITotalPagesProps extends ITextProps, IWithI18nEnhanceProps {}
28
-
29
- export interface IPageInputProps extends IInputProps, IWithI18nEnhanceProps {}
30
-
31
- export interface IPaginationContext {
32
- getFirstPageProps: PropGetterFn;
33
- getPrevPageProps: PropGetterFn;
34
- getNextPageProps: PropGetterFn;
35
- getPageInputProps: PropGetterFn;
36
- getTotalPagesProps: PropGetterFn;
37
- }
38
-
39
- export interface IPaginationHandlers {
40
- totalPages: (value: number) => void;
41
- currentPage: (value: number) => void;
42
- }
43
-
44
- declare const Pagination: (<T>(
45
- props: CProps<IPaginationProps & T, IPaginationContext, IPaginationHandlers>,
46
- ) => ReturnEl) & {
47
- PrevPage: (props: ComponentProps<typeof Button>) => ReturnEl;
48
- NextPage: (props: ComponentProps<typeof Button>) => ReturnEl;
49
- FirstPage: (props: ComponentProps<typeof Button>) => ReturnEl;
50
- TotalPages: (props: CProps<ITotalPagesProps, {}, IPaginationHandlers>) => ReturnEl;
51
- PageInput: (<T>(props: CProps<IPageInputProps & T, {}, IPaginationHandlers>) => ReturnEl) & {
52
- Value: typeof Input.Value;
53
- Addon: typeof Input.Addon;
54
- };
55
- };
56
-
57
- export default Pagination;
@@ -1,57 +0,0 @@
1
- import { ComponentProps } from 'react';
2
- import { CProps, PropGetterFn, ReturnEl } from '@semcore/core';
3
- import { IBoxProps } from '@semcore/flex-box';
4
- import Input, { IInputProps } from '@semcore/input';
5
- import { ITextProps } from '@semcore/typography';
6
- import Button from '@semcore/button';
7
- import { IWithI18nEnhanceProps } from '@semcore/utils/lib/enhances/i18nEnhance';
8
-
9
- export interface IPaginationProps extends IBoxProps, IWithI18nEnhanceProps {
10
- /**
11
- * Total number of pages
12
- * @default 1
13
- */
14
- totalPages?: number;
15
- /**
16
- * Active page number
17
- * @default 1
18
- */
19
- currentPage?: number;
20
- /**
21
- * Callback for changing the active page
22
- * @param pageNumber
23
- */
24
- onCurrentPageChange?: (pageNumber: number) => void;
25
- }
26
-
27
- export interface ITotalPagesProps extends ITextProps, IWithI18nEnhanceProps {}
28
-
29
- export interface IPageInputProps extends IInputProps, IWithI18nEnhanceProps {}
30
-
31
- export interface IPaginationContext {
32
- getFirstPageProps: PropGetterFn;
33
- getPrevPageProps: PropGetterFn;
34
- getNextPageProps: PropGetterFn;
35
- getPageInputProps: PropGetterFn;
36
- getTotalPagesProps: PropGetterFn;
37
- }
38
-
39
- export interface IPaginationHandlers {
40
- totalPages: (value: number) => void;
41
- currentPage: (value: number) => void;
42
- }
43
-
44
- declare const Pagination: (<T>(
45
- props: CProps<IPaginationProps & T, IPaginationContext, IPaginationHandlers>,
46
- ) => ReturnEl) & {
47
- PrevPage: (props: ComponentProps<typeof Button>) => ReturnEl;
48
- NextPage: (props: ComponentProps<typeof Button>) => ReturnEl;
49
- FirstPage: (props: ComponentProps<typeof Button>) => ReturnEl;
50
- TotalPages: (props: CProps<ITotalPagesProps, {}, IPaginationHandlers>) => ReturnEl;
51
- PageInput: (<T>(props: CProps<IPageInputProps & T, {}, IPaginationHandlers>) => ReturnEl) & {
52
- Value: typeof Input.Value;
53
- Addon: typeof Input.Addon;
54
- };
55
- };
56
-
57
- export default Pagination;