@elliemae/ds-pagination 3.16.0-next.4 → 3.16.0-next.5
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/dist/cjs/DSPaginationDefinitions.js +13 -1
- package/dist/cjs/DSPaginationDefinitions.js.map +2 -2
- package/dist/cjs/PaginationDataTestID.js +3 -1
- package/dist/cjs/PaginationDataTestID.js.map +2 -2
- package/dist/cjs/index.js +32 -2
- package/dist/cjs/index.js.map +3 -3
- package/dist/cjs/parts/DSPageNextButton.js +70 -0
- package/dist/cjs/parts/DSPageNextButton.js.map +7 -0
- package/dist/cjs/parts/DSPagePrevButton.js +70 -0
- package/dist/cjs/parts/DSPagePrevButton.js.map +7 -0
- package/dist/cjs/parts/DSPaginationContainer.js +57 -0
- package/dist/cjs/parts/DSPaginationContainer.js.map +7 -0
- package/dist/cjs/parts/{PageNextButton.js → DSPaginator/createPaginatorHeader.js} +19 -25
- package/dist/cjs/parts/DSPaginator/createPaginatorHeader.js.map +7 -0
- package/dist/cjs/parts/DSPaginator/getOptions.js +72 -0
- package/dist/cjs/parts/DSPaginator/getOptions.js.map +7 -0
- package/dist/cjs/parts/DSPaginator/index.js +144 -0
- package/dist/cjs/parts/DSPaginator/index.js.map +7 -0
- package/dist/cjs/{hooks → parts/DSPaginator}/usePaginationSearch.js +5 -2
- package/dist/cjs/parts/DSPaginator/usePaginationSearch.js.map +7 -0
- package/dist/cjs/parts/DSPaginator/usePaginator.js +87 -0
- package/dist/cjs/parts/DSPaginator/usePaginator.js.map +7 -0
- package/dist/cjs/parts/{PagePrevButton.js → DSPerPageSelector/getOptions.js} +21 -22
- package/dist/cjs/parts/DSPerPageSelector/getOptions.js.map +7 -0
- package/dist/cjs/parts/{PerPageSelector.js → DSPerPageSelector/index.js} +37 -49
- package/dist/cjs/parts/DSPerPageSelector/index.js.map +7 -0
- package/dist/cjs/parts/DSPerPageSelector/usePerPageSelector.js +68 -0
- package/dist/cjs/parts/DSPerPageSelector/usePerPageSelector.js.map +7 -0
- package/dist/cjs/parts/PaginationContent.js +36 -51
- package/dist/cjs/parts/PaginationContent.js.map +3 -3
- package/dist/cjs/parts/index.js +45 -0
- package/dist/cjs/parts/index.js.map +7 -0
- package/dist/cjs/react-desc-prop-types.js +107 -33
- package/dist/cjs/react-desc-prop-types.js.map +2 -2
- package/dist/cjs/styled.js +17 -27
- package/dist/cjs/styled.js.map +2 -2
- package/dist/esm/DSPaginationDefinitions.js +13 -1
- package/dist/esm/DSPaginationDefinitions.js.map +2 -2
- package/dist/esm/PaginationDataTestID.js +3 -1
- package/dist/esm/PaginationDataTestID.js.map +2 -2
- package/dist/esm/index.js +39 -1
- package/dist/esm/index.js.map +3 -3
- package/dist/esm/parts/DSPageNextButton.js +50 -0
- package/dist/esm/parts/DSPageNextButton.js.map +7 -0
- package/dist/esm/parts/DSPagePrevButton.js +50 -0
- package/dist/esm/parts/DSPagePrevButton.js.map +7 -0
- package/dist/esm/parts/DSPaginationContainer.js +31 -0
- package/dist/esm/parts/DSPaginationContainer.js.map +7 -0
- package/dist/esm/parts/DSPaginator/createPaginatorHeader.js +20 -0
- package/dist/esm/parts/DSPaginator/createPaginatorHeader.js.map +7 -0
- package/dist/esm/parts/DSPaginator/getOptions.js +46 -0
- package/dist/esm/parts/DSPaginator/getOptions.js.map +7 -0
- package/dist/esm/parts/DSPaginator/index.js +118 -0
- package/dist/esm/parts/DSPaginator/index.js.map +7 -0
- package/dist/esm/{hooks → parts/DSPaginator}/usePaginationSearch.js +5 -2
- package/dist/esm/parts/DSPaginator/usePaginationSearch.js.map +7 -0
- package/dist/esm/parts/DSPaginator/usePaginator.js +61 -0
- package/dist/esm/parts/DSPaginator/usePaginator.js.map +7 -0
- package/dist/esm/parts/DSPerPageSelector/getOptions.js +22 -0
- package/dist/esm/parts/DSPerPageSelector/getOptions.js.map +7 -0
- package/dist/esm/parts/DSPerPageSelector/index.js +76 -0
- package/dist/esm/parts/DSPerPageSelector/index.js.map +7 -0
- package/dist/esm/parts/DSPerPageSelector/usePerPageSelector.js +42 -0
- package/dist/esm/parts/DSPerPageSelector/usePerPageSelector.js.map +7 -0
- package/dist/esm/parts/PaginationContent.js +37 -52
- package/dist/esm/parts/PaginationContent.js.map +2 -2
- package/dist/esm/parts/index.js +19 -0
- package/dist/esm/parts/index.js.map +7 -0
- package/dist/esm/react-desc-prop-types.js +88 -14
- package/dist/esm/react-desc-prop-types.js.map +2 -2
- package/dist/esm/styled.js +15 -25
- package/dist/esm/styled.js.map +2 -2
- package/dist/types/DSPaginationDefinitions.d.ts +6 -0
- package/dist/types/PaginationDataTestID.d.ts +2 -0
- package/dist/types/index.d.ts +17 -1
- package/dist/types/parts/DSPageNextButton.d.ts +4 -0
- package/dist/types/parts/DSPagePrevButton.d.ts +4 -0
- package/dist/types/parts/DSPaginationContainer.d.ts +4 -0
- package/dist/types/parts/DSPaginator/createPaginatorHeader.d.ts +6 -0
- package/dist/types/parts/DSPaginator/getOptions.d.ts +7 -0
- package/dist/types/parts/DSPaginator/index.d.ts +4 -0
- package/dist/types/parts/DSPaginator/usePaginationSearch.d.ts +2 -0
- package/dist/types/parts/DSPaginator/usePaginator.d.ts +17 -0
- package/dist/types/parts/DSPerPageSelector/getOptions.d.ts +3 -0
- package/dist/types/parts/DSPerPageSelector/index.d.ts +4 -0
- package/dist/types/parts/DSPerPageSelector/usePerPageSelector.d.ts +13 -0
- package/dist/types/parts/index.d.ts +5 -0
- package/dist/types/react-desc-prop-types.d.ts +528 -9
- package/dist/types/styled.d.ts +7 -9
- package/dist/types/tests/a11y/axe.test.d.ts +1 -0
- package/dist/types/tests/callbacks/paginator.test.d.ts +1 -0
- package/dist/types/tests/callbacks/per-page-selector.test.d.ts +1 -0
- package/dist/types/tests/callbacks/prev-next-buttons.test.d.ts +1 -0
- package/dist/types/tests/keyboard/navigation.test.d.ts +1 -0
- package/dist/types/tests/keyboard/paginator-search.test.d.ts +1 -0
- package/dist/types/tests/render/page-count-loading.test.d.ts +1 -0
- package/dist/types/tests/render/paginator.test.d.ts +1 -0
- package/dist/types/tests/render/per-page-selector.test.d.ts +1 -0
- package/dist/types/tests/render/segmented-paginator.test.d.ts +1 -0
- package/dist/types/tests/render/simple.render.test.d.ts +1 -0
- package/package.json +16 -11
- package/dist/cjs/hooks/usePaginationSearch.js.map +0 -7
- package/dist/cjs/package.json +0 -7
- package/dist/cjs/parts/PageNextButton.js.map +0 -7
- package/dist/cjs/parts/PagePrevButton.js.map +0 -7
- package/dist/cjs/parts/Paginator.js +0 -162
- package/dist/cjs/parts/Paginator.js.map +0 -7
- package/dist/cjs/parts/PerPageSelector.js.map +0 -7
- package/dist/esm/hooks/usePaginationSearch.js.map +0 -7
- package/dist/esm/package.json +0 -7
- package/dist/esm/parts/PageNextButton.js +0 -26
- package/dist/esm/parts/PageNextButton.js.map +0 -7
- package/dist/esm/parts/PagePrevButton.js +0 -23
- package/dist/esm/parts/PagePrevButton.js.map +0 -7
- package/dist/esm/parts/Paginator.js +0 -136
- package/dist/esm/parts/Paginator.js.map +0 -7
- package/dist/esm/parts/PerPageSelector.js +0 -88
- package/dist/esm/parts/PerPageSelector.js.map +0 -7
- package/dist/types/hooks/usePaginationSearch.d.ts +0 -1
- package/dist/types/parts/PageNextButton.d.ts +0 -3
- package/dist/types/parts/PagePrevButton.d.ts +0 -3
- package/dist/types/parts/Paginator.d.ts +0 -11
- package/dist/types/parts/PerPageSelector.d.ts +0 -4
|
@@ -24,9 +24,21 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
24
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
25
25
|
var DSPaginationDefinitions_exports = {};
|
|
26
26
|
__export(DSPaginationDefinitions_exports, {
|
|
27
|
-
DSPaginationName: () => DSPaginationName
|
|
27
|
+
DSPaginationName: () => DSPaginationName,
|
|
28
|
+
PageNextButtonName: () => PageNextButtonName,
|
|
29
|
+
PagePrevButtonName: () => PagePrevButtonName,
|
|
30
|
+
PaginationContainerName: () => PaginationContainerName,
|
|
31
|
+
PaginationSeparatorName: () => PaginationSeparatorName,
|
|
32
|
+
PaginatorName: () => PaginatorName,
|
|
33
|
+
PerPageSelectorName: () => PerPageSelectorName
|
|
28
34
|
});
|
|
29
35
|
module.exports = __toCommonJS(DSPaginationDefinitions_exports);
|
|
30
36
|
var React = __toESM(require("react"));
|
|
31
37
|
const DSPaginationName = "DSPagination";
|
|
38
|
+
const PaginationContainerName = "DSPaginationContainer";
|
|
39
|
+
const PerPageSelectorName = "DSPerPageSelector";
|
|
40
|
+
const PagePrevButtonName = "DSPagePrevButton";
|
|
41
|
+
const PageNextButtonName = "DSPageNextButton";
|
|
42
|
+
const PaginatorName = "DSPaginator";
|
|
43
|
+
const PaginationSeparatorName = "DSPaginationSeparator";
|
|
32
44
|
//# sourceMappingURL=DSPaginationDefinitions.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/DSPaginationDefinitions.tsx", "../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["export const DSPaginationName = 'DSPagination';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,mBAAmB;",
|
|
4
|
+
"sourcesContent": ["export const DSPaginationName = 'DSPagination';\n\nexport const PaginationContainerName = 'DSPaginationContainer';\n\nexport const PerPageSelectorName = 'DSPerPageSelector';\n\nexport const PagePrevButtonName = 'DSPagePrevButton';\n\nexport const PageNextButtonName = 'DSPageNextButton';\n\nexport const PaginatorName = 'DSPaginator';\n\nexport const PaginationSeparatorName = 'DSPaginationSeparator';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,mBAAmB;AAEzB,MAAM,0BAA0B;AAEhC,MAAM,sBAAsB;AAE5B,MAAM,qBAAqB;AAE3B,MAAM,qBAAqB;AAE3B,MAAM,gBAAgB;AAEtB,MAAM,0BAA0B;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -31,6 +31,8 @@ var React = __toESM(require("react"));
|
|
|
31
31
|
const PAGINATION_DATA_TESTID = {
|
|
32
32
|
PREVIOUS_BUTTON: "data-table-pagination-prev-button",
|
|
33
33
|
NEXT_BUTTON: "data-table-pagination-next-button",
|
|
34
|
-
CONTAINER: "data-table-pagination-container"
|
|
34
|
+
CONTAINER: "data-table-pagination-container",
|
|
35
|
+
PER_PAGE_SELECTOR: "ds-pagination-per-page-selector",
|
|
36
|
+
PAGINATOR: "ds-pagination-paginator"
|
|
35
37
|
};
|
|
36
38
|
//# sourceMappingURL=PaginationDataTestID.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/PaginationDataTestID.tsx", "../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["export const PAGINATION_DATA_TESTID = {\n PREVIOUS_BUTTON: 'data-table-pagination-prev-button',\n NEXT_BUTTON: 'data-table-pagination-next-button',\n CONTAINER: 'data-table-pagination-container',\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,yBAAyB;AAAA,EACpC,iBAAiB;AAAA,EACjB,aAAa;AAAA,EACb,WAAW;AACb;",
|
|
4
|
+
"sourcesContent": ["export const PAGINATION_DATA_TESTID = {\n PREVIOUS_BUTTON: 'data-table-pagination-prev-button',\n NEXT_BUTTON: 'data-table-pagination-next-button',\n CONTAINER: 'data-table-pagination-container',\n PER_PAGE_SELECTOR: 'ds-pagination-per-page-selector',\n PAGINATOR: 'ds-pagination-paginator',\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAhB,MAAM,yBAAyB;AAAA,EACpC,iBAAiB;AAAA,EACjB,aAAa;AAAA,EACb,WAAW;AAAA,EACX,mBAAmB;AAAA,EACnB,WAAW;AACb;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/dist/cjs/index.js
CHANGED
|
@@ -5,6 +5,10 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __getProtoOf = Object.getPrototypeOf;
|
|
7
7
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
8
12
|
var __copyProps = (to, from, except, desc) => {
|
|
9
13
|
if (from && typeof from === "object" || typeof from === "function") {
|
|
10
14
|
for (let key of __getOwnPropNames(from))
|
|
@@ -13,14 +17,40 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
13
17
|
}
|
|
14
18
|
return to;
|
|
15
19
|
};
|
|
16
|
-
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
17
20
|
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
18
21
|
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
19
22
|
mod
|
|
20
23
|
));
|
|
21
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
22
25
|
var src_exports = {};
|
|
26
|
+
__export(src_exports, {
|
|
27
|
+
DSPageNextButton: () => import_parts.DSPageNextButton,
|
|
28
|
+
DSPageNextButtonWithSchema: () => import_parts.DSPageNextButtonWithSchema,
|
|
29
|
+
DSPagePrevButton: () => import_parts.DSPagePrevButton,
|
|
30
|
+
DSPagePrevButtonWithSchema: () => import_parts.DSPagePrevButtonWithSchema,
|
|
31
|
+
DSPagination: () => import_Pagination.DSPagination,
|
|
32
|
+
DSPaginationContainer: () => import_parts.DSPaginationContainer,
|
|
33
|
+
DSPaginationContainerWithSchema: () => import_parts.DSPaginationContainerWithSchema,
|
|
34
|
+
DSPaginationSeparator: () => import_styled2.DSPaginationSeparator,
|
|
35
|
+
DSPaginationSeparatorWithSchema: () => DSPaginationSeparatorWithSchema,
|
|
36
|
+
DSPaginationWithSchema: () => import_Pagination.DSPaginationWithSchema,
|
|
37
|
+
DSPaginator: () => import_parts.DSPaginator,
|
|
38
|
+
DSPaginatorWithSchema: () => import_parts.DSPaginatorWithSchema,
|
|
39
|
+
DSPerPageSelector: () => import_parts.DSPerPageSelector,
|
|
40
|
+
DSPerPageSelectorWithSchema: () => import_parts.DSPerPageSelectorWithSchema,
|
|
41
|
+
PAGINATION_DATA_TESTID: () => import_PaginationDataTestID.PAGINATION_DATA_TESTID
|
|
42
|
+
});
|
|
23
43
|
module.exports = __toCommonJS(src_exports);
|
|
24
44
|
var React = __toESM(require("react"));
|
|
25
|
-
|
|
45
|
+
var import_styled = require("./styled");
|
|
46
|
+
var import_react_desc_prop_types = require("./react-desc-prop-types");
|
|
47
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
48
|
+
var import_DSPaginationDefinitions = require("./DSPaginationDefinitions");
|
|
49
|
+
var import_Pagination = require("./Pagination");
|
|
50
|
+
var import_parts = require("./parts");
|
|
51
|
+
var import_styled2 = require("./styled");
|
|
52
|
+
var import_PaginationDataTestID = require("./PaginationDataTestID");
|
|
53
|
+
import_styled.DSPaginationSeparator.propTypes = import_react_desc_prop_types.DSPaginationStyledPartPropTypesSchema;
|
|
54
|
+
import_styled.DSPaginationSeparator.displayName = import_DSPaginationDefinitions.PaginationSeparatorName;
|
|
55
|
+
const DSPaginationSeparatorWithSchema = (0, import_ds_props_helpers.describe)(import_styled.DSPaginationSeparator).description("Pagination Separator");
|
|
26
56
|
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.tsx", "../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
-
"sourcesContent": ["
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": []
|
|
4
|
+
"sourcesContent": ["import { DSPaginationSeparator } from './styled';\nimport { DSPaginationStyledPartPropTypesSchema } from './react-desc-prop-types';\nimport { describe } from '@elliemae/ds-props-helpers';\nimport { PaginationSeparatorName } from './DSPaginationDefinitions';\n\nDSPaginationSeparator.propTypes = DSPaginationStyledPartPropTypesSchema;\nDSPaginationSeparator.displayName = PaginationSeparatorName;\nconst DSPaginationSeparatorWithSchema = describe(DSPaginationSeparator).description('Pagination Separator');\n\nexport { DSPagination, DSPaginationWithSchema } from './Pagination';\nexport {\n DSPageNextButton,\n DSPageNextButtonWithSchema,\n DSPagePrevButton,\n DSPagePrevButtonWithSchema,\n DSPaginationContainer,\n DSPaginationContainerWithSchema,\n DSPerPageSelector,\n DSPerPageSelectorWithSchema,\n DSPaginator,\n DSPaginatorWithSchema,\n} from './parts';\n\nexport { DSPaginationSeparator } from './styled';\n\nexport { DSPaginationSeparatorWithSchema };\n\nexport { PAGINATION_DATA_TESTID } from './PaginationDataTestID';\n\nexport type { DSPaginationT } from './react-desc-prop-types';\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADAvB,oBAAsC;AACtC,mCAAsD;AACtD,8BAAyB;AACzB,qCAAwC;AAMxC,wBAAqD;AACrD,mBAWO;AAEP,IAAAA,iBAAsC;AAItC,kCAAuC;AAtBvC,oCAAsB,YAAY;AAClC,oCAAsB,cAAc;AACpC,MAAM,sCAAkC,kCAAS,mCAAqB,EAAE,YAAY,sBAAsB;",
|
|
6
|
+
"names": ["import_styled"]
|
|
7
7
|
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
24
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
25
|
+
var DSPageNextButton_exports = {};
|
|
26
|
+
__export(DSPageNextButton_exports, {
|
|
27
|
+
DSPageNextButton: () => DSPageNextButton,
|
|
28
|
+
DSPageNextButtonWithSchema: () => DSPageNextButtonWithSchema
|
|
29
|
+
});
|
|
30
|
+
module.exports = __toCommonJS(DSPageNextButton_exports);
|
|
31
|
+
var React = __toESM(require("react"));
|
|
32
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
33
|
+
var import_lodash = require("lodash");
|
|
34
|
+
var import_ds_icons = require("@elliemae/ds-icons");
|
|
35
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
36
|
+
var import_PaginationDataTestID = require("../PaginationDataTestID");
|
|
37
|
+
var import_styled = require("../styled");
|
|
38
|
+
var import_react_desc_prop_types = require("../react-desc-prop-types");
|
|
39
|
+
var import_DSPaginationDefinitions = require("../DSPaginationDefinitions");
|
|
40
|
+
const DSPageNextButton = (props) => {
|
|
41
|
+
const propsWithDefault = (0, import_ds_props_helpers.useMemoMergePropsWithDefault)(
|
|
42
|
+
props,
|
|
43
|
+
import_react_desc_prop_types.pageNextButtonDefaultProps
|
|
44
|
+
);
|
|
45
|
+
(0, import_ds_props_helpers.useValidateTypescriptPropTypes)(propsWithDefault, import_react_desc_prop_types.DSPageNextButtonPropTypesSchema, import_DSPaginationDefinitions.PageNextButtonName);
|
|
46
|
+
const { canNextPage, onNextPage } = propsWithDefault;
|
|
47
|
+
const globalAttributes = (0, import_lodash.omit)((0, import_ds_props_helpers.useGetGlobalAttributes)(propsWithDefault), "shape", "size", "type");
|
|
48
|
+
const xstyledAttributes = (0, import_ds_props_helpers.useGetXstyledProps)(propsWithDefault);
|
|
49
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
50
|
+
import_styled.PreviousNextPageButton,
|
|
51
|
+
{
|
|
52
|
+
disabled: !canNextPage,
|
|
53
|
+
buttonType: "raw",
|
|
54
|
+
"data-testid": import_PaginationDataTestID.PAGINATION_DATA_TESTID.NEXT_BUTTON,
|
|
55
|
+
"aria-label": "Go to next page",
|
|
56
|
+
...globalAttributes,
|
|
57
|
+
...xstyledAttributes,
|
|
58
|
+
onClick: () => {
|
|
59
|
+
if (canNextPage)
|
|
60
|
+
onNextPage();
|
|
61
|
+
},
|
|
62
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_icons.ChevronRight, { color: canNextPage ? ["brand-primary", "700"] : ["neutral", "500"] })
|
|
63
|
+
}
|
|
64
|
+
);
|
|
65
|
+
};
|
|
66
|
+
DSPageNextButton.propTypes = import_react_desc_prop_types.DSPageNextButtonPropTypesSchema;
|
|
67
|
+
DSPageNextButton.displayName = import_DSPaginationDefinitions.PageNextButtonName;
|
|
68
|
+
const DSPageNextButtonWithSchema = (0, import_ds_props_helpers.describe)(DSPageNextButton).description("Per Page Selector");
|
|
69
|
+
DSPageNextButtonWithSchema.propTypes = import_react_desc_prop_types.DSPageNextButtonPropTypesSchema;
|
|
70
|
+
//# sourceMappingURL=DSPageNextButton.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/parts/DSPageNextButton.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["/* eslint-disable react/prop-types */\nimport React from 'react';\nimport { omit } from 'lodash';\nimport { ChevronRight } from '@elliemae/ds-icons';\nimport {\n describe,\n useGetGlobalAttributes,\n useGetXstyledProps,\n useMemoMergePropsWithDefault,\n useValidateTypescriptPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { PAGINATION_DATA_TESTID } from '../PaginationDataTestID';\nimport { PreviousNextPageButton } from '../styled';\nimport { pageNextButtonDefaultProps, DSPageNextButtonPropTypesSchema } from '../react-desc-prop-types';\nimport { PageNextButtonName } from '../DSPaginationDefinitions';\nimport type { DSPaginationT } from '../react-desc-prop-types';\n\nexport const DSPageNextButton: React.ComponentType<DSPaginationT.PageNextButtonProps> = (props) => {\n const propsWithDefault = useMemoMergePropsWithDefault<DSPaginationT.PageNextButtonInternalProps>(\n props,\n pageNextButtonDefaultProps,\n );\n useValidateTypescriptPropTypes(propsWithDefault, DSPageNextButtonPropTypesSchema, PageNextButtonName);\n\n const { canNextPage, onNextPage } = propsWithDefault;\n const globalAttributes = omit(useGetGlobalAttributes(propsWithDefault), 'shape', 'size', 'type');\n const xstyledAttributes = useGetXstyledProps(propsWithDefault);\n\n return (\n <PreviousNextPageButton\n disabled={!canNextPage}\n buttonType=\"raw\"\n data-testid={PAGINATION_DATA_TESTID.NEXT_BUTTON}\n aria-label=\"Go to next page\"\n {...globalAttributes}\n {...xstyledAttributes}\n onClick={() => {\n if (canNextPage) onNextPage();\n }}\n >\n <ChevronRight color={canNextPage ? ['brand-primary', '700'] : ['neutral', '500']} />\n </PreviousNextPageButton>\n );\n};\n\nDSPageNextButton.propTypes = DSPageNextButtonPropTypesSchema;\nDSPageNextButton.displayName = PageNextButtonName;\nexport const DSPageNextButtonWithSchema = describe(DSPageNextButton).description('Per Page Selector');\nDSPageNextButtonWithSchema.propTypes = DSPageNextButtonPropTypesSchema;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADwCjB;AAtCN,oBAAqB;AACrB,sBAA6B;AAC7B,8BAMO;AACP,kCAAuC;AACvC,oBAAuC;AACvC,mCAA4E;AAC5E,qCAAmC;AAG5B,MAAM,mBAA2E,CAAC,UAAU;AACjG,QAAM,uBAAmB;AAAA,IACvB;AAAA,IACA;AAAA,EACF;AACA,8DAA+B,kBAAkB,8DAAiC,iDAAkB;AAEpG,QAAM,EAAE,aAAa,WAAW,IAAI;AACpC,QAAM,uBAAmB,wBAAK,gDAAuB,gBAAgB,GAAG,SAAS,QAAQ,MAAM;AAC/F,QAAM,wBAAoB,4CAAmB,gBAAgB;AAE7D,SACE;AAAA,IAAC;AAAA;AAAA,MACC,UAAU,CAAC;AAAA,MACX,YAAW;AAAA,MACX,eAAa,mDAAuB;AAAA,MACpC,cAAW;AAAA,MACV,GAAG;AAAA,MACH,GAAG;AAAA,MACJ,SAAS,MAAM;AACb,YAAI;AAAa,qBAAW;AAAA,MAC9B;AAAA,MAEA,sDAAC,gCAAa,OAAO,cAAc,CAAC,iBAAiB,KAAK,IAAI,CAAC,WAAW,KAAK,GAAG;AAAA;AAAA,EACpF;AAEJ;AAEA,iBAAiB,YAAY;AAC7B,iBAAiB,cAAc;AACxB,MAAM,iCAA6B,kCAAS,gBAAgB,EAAE,YAAY,mBAAmB;AACpG,2BAA2B,YAAY;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
24
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
25
|
+
var DSPagePrevButton_exports = {};
|
|
26
|
+
__export(DSPagePrevButton_exports, {
|
|
27
|
+
DSPagePrevButton: () => DSPagePrevButton,
|
|
28
|
+
DSPagePrevButtonWithSchema: () => DSPagePrevButtonWithSchema
|
|
29
|
+
});
|
|
30
|
+
module.exports = __toCommonJS(DSPagePrevButton_exports);
|
|
31
|
+
var React = __toESM(require("react"));
|
|
32
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
33
|
+
var import_lodash = require("lodash");
|
|
34
|
+
var import_ds_icons = require("@elliemae/ds-icons");
|
|
35
|
+
var import_PaginationDataTestID = require("../PaginationDataTestID");
|
|
36
|
+
var import_styled = require("../styled");
|
|
37
|
+
var import_react_desc_prop_types = require("../react-desc-prop-types");
|
|
38
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
39
|
+
var import_DSPaginationDefinitions = require("../DSPaginationDefinitions");
|
|
40
|
+
const DSPagePrevButton = (props) => {
|
|
41
|
+
const propsWithDefault = (0, import_ds_props_helpers.useMemoMergePropsWithDefault)(
|
|
42
|
+
props,
|
|
43
|
+
import_react_desc_prop_types.pagePrevButtonDefaultProps
|
|
44
|
+
);
|
|
45
|
+
(0, import_ds_props_helpers.useValidateTypescriptPropTypes)(propsWithDefault, import_react_desc_prop_types.DSPagePrevButtonPropTypesSchema, import_DSPaginationDefinitions.PagePrevButtonName);
|
|
46
|
+
const { canPreviousPage, onPreviousPage } = propsWithDefault;
|
|
47
|
+
const globalAttributes = (0, import_lodash.omit)((0, import_ds_props_helpers.useGetGlobalAttributes)(propsWithDefault), "shape", "size", "type");
|
|
48
|
+
const xstyledAttributes = (0, import_ds_props_helpers.useGetXstyledProps)(propsWithDefault);
|
|
49
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
50
|
+
import_styled.PreviousNextPageButton,
|
|
51
|
+
{
|
|
52
|
+
disabled: !canPreviousPage,
|
|
53
|
+
buttonType: "raw",
|
|
54
|
+
"data-testid": import_PaginationDataTestID.PAGINATION_DATA_TESTID.PREVIOUS_BUTTON,
|
|
55
|
+
"aria-label": "Go to previous page",
|
|
56
|
+
...globalAttributes,
|
|
57
|
+
...xstyledAttributes,
|
|
58
|
+
onClick: () => {
|
|
59
|
+
if (canPreviousPage)
|
|
60
|
+
onPreviousPage();
|
|
61
|
+
},
|
|
62
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_icons.ChevronLeft, { color: canPreviousPage ? ["brand-primary", "700"] : ["neutral", "500"] })
|
|
63
|
+
}
|
|
64
|
+
);
|
|
65
|
+
};
|
|
66
|
+
DSPagePrevButton.propTypes = import_react_desc_prop_types.DSPagePrevButtonPropTypesSchema;
|
|
67
|
+
DSPagePrevButton.displayName = import_DSPaginationDefinitions.PagePrevButtonName;
|
|
68
|
+
const DSPagePrevButtonWithSchema = (0, import_ds_props_helpers.describe)(DSPagePrevButton).description("Per Page Selector");
|
|
69
|
+
DSPagePrevButtonWithSchema.propTypes = import_react_desc_prop_types.DSPagePrevButtonPropTypesSchema;
|
|
70
|
+
//# sourceMappingURL=DSPagePrevButton.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/parts/DSPagePrevButton.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["/* eslint-disable react/prop-types */\nimport React from 'react';\nimport { omit } from 'lodash';\nimport { ChevronLeft } from '@elliemae/ds-icons';\nimport { PAGINATION_DATA_TESTID } from '../PaginationDataTestID';\nimport { PreviousNextPageButton } from '../styled';\nimport { pagePrevButtonDefaultProps, DSPagePrevButtonPropTypesSchema } from '../react-desc-prop-types';\nimport {\n describe,\n useGetGlobalAttributes,\n useGetXstyledProps,\n useMemoMergePropsWithDefault,\n useValidateTypescriptPropTypes,\n} from '@elliemae/ds-props-helpers';\nimport { PagePrevButtonName } from '../DSPaginationDefinitions';\nimport type { DSPaginationT } from '../react-desc-prop-types';\n\nexport const DSPagePrevButton: React.ComponentType<DSPaginationT.PagePrevButtonProps> = (props) => {\n const propsWithDefault = useMemoMergePropsWithDefault<DSPaginationT.PagePrevButtonInternalProps>(\n props,\n pagePrevButtonDefaultProps,\n );\n useValidateTypescriptPropTypes(propsWithDefault, DSPagePrevButtonPropTypesSchema, PagePrevButtonName);\n\n const { canPreviousPage, onPreviousPage } = propsWithDefault;\n const globalAttributes = omit(useGetGlobalAttributes(propsWithDefault), 'shape', 'size', 'type');\n const xstyledAttributes = useGetXstyledProps(propsWithDefault);\n\n return (\n <PreviousNextPageButton\n disabled={!canPreviousPage}\n buttonType=\"raw\"\n data-testid={PAGINATION_DATA_TESTID.PREVIOUS_BUTTON}\n aria-label=\"Go to previous page\"\n {...globalAttributes}\n {...xstyledAttributes}\n onClick={() => {\n if (canPreviousPage) onPreviousPage();\n }}\n >\n <ChevronLeft color={canPreviousPage ? ['brand-primary', '700'] : ['neutral', '500']} />\n </PreviousNextPageButton>\n );\n};\n\nDSPagePrevButton.propTypes = DSPagePrevButtonPropTypesSchema;\nDSPagePrevButton.displayName = PagePrevButtonName;\nexport const DSPagePrevButtonWithSchema = describe(DSPagePrevButton).description('Per Page Selector');\nDSPagePrevButtonWithSchema.propTypes = DSPagePrevButtonPropTypesSchema;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADwCjB;AAtCN,oBAAqB;AACrB,sBAA4B;AAC5B,kCAAuC;AACvC,oBAAuC;AACvC,mCAA4E;AAC5E,8BAMO;AACP,qCAAmC;AAG5B,MAAM,mBAA2E,CAAC,UAAU;AACjG,QAAM,uBAAmB;AAAA,IACvB;AAAA,IACA;AAAA,EACF;AACA,8DAA+B,kBAAkB,8DAAiC,iDAAkB;AAEpG,QAAM,EAAE,iBAAiB,eAAe,IAAI;AAC5C,QAAM,uBAAmB,wBAAK,gDAAuB,gBAAgB,GAAG,SAAS,QAAQ,MAAM;AAC/F,QAAM,wBAAoB,4CAAmB,gBAAgB;AAE7D,SACE;AAAA,IAAC;AAAA;AAAA,MACC,UAAU,CAAC;AAAA,MACX,YAAW;AAAA,MACX,eAAa,mDAAuB;AAAA,MACpC,cAAW;AAAA,MACV,GAAG;AAAA,MACH,GAAG;AAAA,MACJ,SAAS,MAAM;AACb,YAAI;AAAiB,yBAAe;AAAA,MACtC;AAAA,MAEA,sDAAC,+BAAY,OAAO,kBAAkB,CAAC,iBAAiB,KAAK,IAAI,CAAC,WAAW,KAAK,GAAG;AAAA;AAAA,EACvF;AAEJ;AAEA,iBAAiB,YAAY;AAC7B,iBAAiB,cAAc;AACxB,MAAM,iCAA6B,kCAAS,gBAAgB,EAAE,YAAY,mBAAmB;AACpG,2BAA2B,YAAY;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
24
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
25
|
+
var DSPaginationContainer_exports = {};
|
|
26
|
+
__export(DSPaginationContainer_exports, {
|
|
27
|
+
DSPaginationContainer: () => DSPaginationContainer,
|
|
28
|
+
DSPaginationContainerWithSchema: () => DSPaginationContainerWithSchema
|
|
29
|
+
});
|
|
30
|
+
module.exports = __toCommonJS(DSPaginationContainer_exports);
|
|
31
|
+
var React = __toESM(require("react"));
|
|
32
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
33
|
+
var import_lodash = require("lodash");
|
|
34
|
+
var import_ds_props_helpers = require("@elliemae/ds-props-helpers");
|
|
35
|
+
var import_PaginationDataTestID = require("../PaginationDataTestID");
|
|
36
|
+
var import_styled = require("../styled");
|
|
37
|
+
var import_react_desc_prop_types = require("../react-desc-prop-types");
|
|
38
|
+
var import_DSPaginationDefinitions = require("../DSPaginationDefinitions");
|
|
39
|
+
const DSPaginationContainer = (props) => {
|
|
40
|
+
const globalAttributes = (0, import_lodash.omit)((0, import_ds_props_helpers.useGetGlobalAttributes)(props), ["rows", "wrap"]);
|
|
41
|
+
const xstyledProps = (0, import_ds_props_helpers.useGetXstyledProps)(props);
|
|
42
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
43
|
+
import_styled.StyledPaginationContainer,
|
|
44
|
+
{
|
|
45
|
+
"data-testid": import_PaginationDataTestID.PAGINATION_DATA_TESTID.CONTAINER,
|
|
46
|
+
...globalAttributes,
|
|
47
|
+
...xstyledProps,
|
|
48
|
+
cols: ["minmax(auto, 80%)"],
|
|
49
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styled.StyledPaginationWrapper, { children: props.children })
|
|
50
|
+
}
|
|
51
|
+
);
|
|
52
|
+
};
|
|
53
|
+
DSPaginationContainer.propTypes = import_react_desc_prop_types.DSPaginationContainerPropTypesSchema;
|
|
54
|
+
DSPaginationContainer.displayName = import_DSPaginationDefinitions.PaginationContainerName;
|
|
55
|
+
const DSPaginationContainerWithSchema = (0, import_ds_props_helpers.describe)(DSPaginationContainer).description("Per Page Selector");
|
|
56
|
+
DSPaginationContainerWithSchema.propTypes = import_react_desc_prop_types.DSPaginationContainerPropTypesSchema;
|
|
57
|
+
//# sourceMappingURL=DSPaginationContainer.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/parts/DSPaginationContainer.tsx", "../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport { omit } from 'lodash';\nimport { describe, useGetGlobalAttributes, useGetXstyledProps } from '@elliemae/ds-props-helpers';\nimport { PAGINATION_DATA_TESTID } from '../PaginationDataTestID';\nimport { StyledPaginationContainer, StyledPaginationWrapper } from '../styled';\nimport { DSPaginationContainerPropTypesSchema } from '../react-desc-prop-types';\nimport { PaginationContainerName } from '../DSPaginationDefinitions';\nimport type { DSPaginationT } from '../react-desc-prop-types';\n\nexport const DSPaginationContainer: React.ComponentType<DSPaginationT.ContainerProps> = (props) => {\n const globalAttributes = omit(useGetGlobalAttributes(props), ['rows', 'wrap']);\n const xstyledProps = useGetXstyledProps(props);\n\n return (\n <StyledPaginationContainer\n data-testid={PAGINATION_DATA_TESTID.CONTAINER}\n {...globalAttributes}\n {...xstyledProps}\n cols={['minmax(auto, 80%)']}\n >\n <StyledPaginationWrapper>{props.children}</StyledPaginationWrapper>\n </StyledPaginationContainer>\n );\n};\n\nDSPaginationContainer.propTypes = DSPaginationContainerPropTypesSchema;\nDSPaginationContainer.displayName = PaginationContainerName;\nexport const DSPaginationContainerWithSchema = describe(DSPaginationContainer).description('Per Page Selector');\nDSPaginationContainerWithSchema.propTypes = DSPaginationContainerPropTypesSchema;\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADoBjB;AAnBN,oBAAqB;AACrB,8BAAqE;AACrE,kCAAuC;AACvC,oBAAmE;AACnE,mCAAqD;AACrD,qCAAwC;AAGjC,MAAM,wBAA2E,CAAC,UAAU;AACjG,QAAM,uBAAmB,wBAAK,gDAAuB,KAAK,GAAG,CAAC,QAAQ,MAAM,CAAC;AAC7E,QAAM,mBAAe,4CAAmB,KAAK;AAE7C,SACE;AAAA,IAAC;AAAA;AAAA,MACC,eAAa,mDAAuB;AAAA,MACnC,GAAG;AAAA,MACH,GAAG;AAAA,MACJ,MAAM,CAAC,mBAAmB;AAAA,MAE1B,sDAAC,yCAAyB,gBAAM,UAAS;AAAA;AAAA,EAC3C;AAEJ;AAEA,sBAAsB,YAAY;AAClC,sBAAsB,cAAc;AAC7B,MAAM,sCAAkC,kCAAS,qBAAqB,EAAE,YAAY,mBAAmB;AAC9G,gCAAgC,YAAY;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -22,31 +22,25 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
22
22
|
mod
|
|
23
23
|
));
|
|
24
24
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
25
|
-
var
|
|
26
|
-
__export(
|
|
27
|
-
|
|
25
|
+
var createPaginatorHeader_exports = {};
|
|
26
|
+
__export(createPaginatorHeader_exports, {
|
|
27
|
+
createPaginatorHeader: () => createPaginatorHeader
|
|
28
28
|
});
|
|
29
|
-
module.exports = __toCommonJS(
|
|
29
|
+
module.exports = __toCommonJS(createPaginatorHeader_exports);
|
|
30
30
|
var React = __toESM(require("react"));
|
|
31
31
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
32
|
-
var
|
|
33
|
-
var
|
|
34
|
-
|
|
35
|
-
const
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
"data-testid": import_PaginationDataTestID.PAGINATION_DATA_TESTID.NEXT_BUTTON,
|
|
48
|
-
"aria-label": "Go to next page",
|
|
49
|
-
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_icons.ChevronRight, { color: canNextPage ? ["brand-primary", "700"] : ["neutral", "500"] })
|
|
50
|
-
}
|
|
51
|
-
);
|
|
52
|
-
//# sourceMappingURL=PageNextButton.js.map
|
|
32
|
+
var import_ds_grid = require("@elliemae/ds-grid");
|
|
33
|
+
var import_styled = require("../../styled");
|
|
34
|
+
const createPaginatorHeader = ({ pageDetailsTitle, pageInfoWidth }) => {
|
|
35
|
+
const Comp = () => {
|
|
36
|
+
if (pageDetailsTitle === "")
|
|
37
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_jsx_runtime.Fragment, { children: "Page" });
|
|
38
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_ds_grid.Grid, { cols: [`${pageInfoWidth + 50}px`, "8px", "auto"], children: [
|
|
39
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { style: { marginLeft: "8px" }, children: "Page" }),
|
|
40
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_styled.DSPaginationSeparator, { height: "100%" }),
|
|
41
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: pageDetailsTitle })
|
|
42
|
+
] });
|
|
43
|
+
};
|
|
44
|
+
return Comp;
|
|
45
|
+
};
|
|
46
|
+
//# sourceMappingURL=createPaginatorHeader.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../src/parts/DSPaginator/createPaginatorHeader.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { DSPaginationSeparator } from '../../styled';\n\ninterface PaginatorHeaderOptions {\n pageDetailsTitle: string;\n pageInfoWidth: number;\n}\n\nexport const createPaginatorHeader = ({ pageDetailsTitle, pageInfoWidth }: PaginatorHeaderOptions) => {\n const Comp = () => {\n if (pageDetailsTitle === '') return <>Page</>;\n\n return (\n <Grid cols={[`${pageInfoWidth + 50}px`, '8px', 'auto']}>\n <span style={{ marginLeft: '8px' }}>Page</span>\n <DSPaginationSeparator height=\"100%\" />\n <span>{pageDetailsTitle}</span>\n </Grid>\n );\n };\n return Comp;\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADWiB;AAVxC,qBAAqB;AACrB,oBAAsC;AAO/B,MAAM,wBAAwB,CAAC,EAAE,kBAAkB,cAAc,MAA8B;AACpG,QAAM,OAAO,MAAM;AACjB,QAAI,qBAAqB;AAAI,aAAO,2EAAE,kBAAI;AAE1C,WACE,6CAAC,uBAAK,MAAM,CAAC,GAAG,gBAAgB,QAAQ,OAAO,MAAM,GACnD;AAAA,kDAAC,UAAK,OAAO,EAAE,YAAY,MAAM,GAAG,kBAAI;AAAA,MACxC,4CAAC,uCAAsB,QAAO,QAAO;AAAA,MACrC,4CAAC,UAAM,4BAAiB;AAAA,OAC1B;AAAA,EAEJ;AACA,SAAO;AACT;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
24
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
25
|
+
var getOptions_exports = {};
|
|
26
|
+
__export(getOptions_exports, {
|
|
27
|
+
getOptions: () => getOptions
|
|
28
|
+
});
|
|
29
|
+
module.exports = __toCommonJS(getOptions_exports);
|
|
30
|
+
var React = __toESM(require("react"));
|
|
31
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
32
|
+
var import_ds_grid = require("@elliemae/ds-grid");
|
|
33
|
+
var import_ds_icons = require("@elliemae/ds-icons");
|
|
34
|
+
const OptionWithDetails = (props) => {
|
|
35
|
+
const Comp = () => {
|
|
36
|
+
const { pageInfoWidth, pageIndex, index, pageDetails } = props;
|
|
37
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_ds_grid.Grid, { cols: ["16px", `${pageInfoWidth + 16}px`, "auto"], gutter: "xxs", alignItems: "center", children: [
|
|
38
|
+
pageIndex - 1 === index ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ds_icons.Checkmark, { size: "s", color: ["brand-primary", "600"] }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {}),
|
|
39
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: index + 1 }),
|
|
40
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
41
|
+
"span",
|
|
42
|
+
{
|
|
43
|
+
style: {
|
|
44
|
+
whiteSpace: "nowrap",
|
|
45
|
+
textOverflow: "ellipsis",
|
|
46
|
+
overflow: "hidden"
|
|
47
|
+
},
|
|
48
|
+
children: pageDetails[index]
|
|
49
|
+
}
|
|
50
|
+
)
|
|
51
|
+
] });
|
|
52
|
+
};
|
|
53
|
+
return Comp;
|
|
54
|
+
};
|
|
55
|
+
const getOptions = (args) => {
|
|
56
|
+
const { pageCount, pageIndex, pageDetails, pageInfoWidth } = args;
|
|
57
|
+
const amountOfPages = typeof pageCount === "string" ? pageIndex + 1 : pageCount;
|
|
58
|
+
const options = new Array(amountOfPages).fill(0).map((_, index) => {
|
|
59
|
+
const option = {
|
|
60
|
+
dsId: (index + 1).toString(),
|
|
61
|
+
label: (index + 1).toString(),
|
|
62
|
+
value: index + 1,
|
|
63
|
+
type: "single"
|
|
64
|
+
};
|
|
65
|
+
if (pageDetails?.length) {
|
|
66
|
+
option.render = OptionWithDetails({ pageInfoWidth, pageIndex, index, pageDetails });
|
|
67
|
+
}
|
|
68
|
+
return option;
|
|
69
|
+
});
|
|
70
|
+
return options;
|
|
71
|
+
};
|
|
72
|
+
//# sourceMappingURL=getOptions.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../src/parts/DSPaginator/getOptions.tsx", "../../../../../../scripts/build/transpile/react-shim.js"],
|
|
4
|
+
"sourcesContent": ["import React from 'react';\nimport { Grid } from '@elliemae/ds-grid';\nimport { Checkmark } from '@elliemae/ds-icons';\nimport type { DSDropdownMenuT } from '@elliemae/ds-dropdownmenu';\n\ninterface OptionWithDetailsT {\n pageInfoWidth: number;\n pageIndex: number;\n index: number;\n pageDetails: string[];\n}\n\nconst OptionWithDetails = (props: OptionWithDetailsT) => {\n const Comp = () => {\n const { pageInfoWidth, pageIndex, index, pageDetails } = props;\n return (\n <Grid cols={['16px', `${pageInfoWidth + 16}px`, 'auto']} gutter=\"xxs\" alignItems=\"center\">\n {pageIndex - 1 === index ? <Checkmark size=\"s\" color={['brand-primary', '600']} /> : <div />}\n <span>{index + 1}</span>\n <span\n style={{\n whiteSpace: 'nowrap',\n textOverflow: 'ellipsis',\n overflow: 'hidden',\n }}\n >\n {pageDetails[index]}\n </span>\n </Grid>\n );\n };\n return Comp;\n};\n\nexport const getOptions = (args: {\n pageCount: number | string;\n pageIndex: number;\n pageDetails: string[];\n pageInfoWidth: number;\n}): DSDropdownMenuT.ItemSingleOptions[] => {\n const { pageCount, pageIndex, pageDetails, pageInfoWidth } = args;\n\n const amountOfPages = typeof pageCount === 'string' ? pageIndex + 1 : pageCount;\n\n const options = new Array(amountOfPages).fill(0).map((_, index) => {\n const option: DSDropdownMenuT.ItemSingleOptions = {\n dsId: (index + 1).toString(),\n label: (index + 1).toString(),\n value: index + 1,\n type: 'single',\n };\n if (pageDetails?.length) {\n option.render = OptionWithDetails({ pageInfoWidth, pageIndex, index, pageDetails });\n }\n return option;\n });\n return options;\n};\n", "import * as React from 'react';\nexport { React };\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;ACAA,YAAuB;ADgBjB;AAfN,qBAAqB;AACrB,sBAA0B;AAU1B,MAAM,oBAAoB,CAAC,UAA8B;AACvD,QAAM,OAAO,MAAM;AACjB,UAAM,EAAE,eAAe,WAAW,OAAO,YAAY,IAAI;AACzD,WACE,6CAAC,uBAAK,MAAM,CAAC,QAAQ,GAAG,gBAAgB,QAAQ,MAAM,GAAG,QAAO,OAAM,YAAW,UAC9E;AAAA,kBAAY,MAAM,QAAQ,4CAAC,6BAAU,MAAK,KAAI,OAAO,CAAC,iBAAiB,KAAK,GAAG,IAAK,4CAAC,SAAI;AAAA,MAC1F,4CAAC,UAAM,kBAAQ,GAAE;AAAA,MACjB;AAAA,QAAC;AAAA;AAAA,UACC,OAAO;AAAA,YACL,YAAY;AAAA,YACZ,cAAc;AAAA,YACd,UAAU;AAAA,UACZ;AAAA,UAEC,sBAAY;AAAA;AAAA,MACf;AAAA,OACF;AAAA,EAEJ;AACA,SAAO;AACT;AAEO,MAAM,aAAa,CAAC,SAKgB;AACzC,QAAM,EAAE,WAAW,WAAW,aAAa,cAAc,IAAI;AAE7D,QAAM,gBAAgB,OAAO,cAAc,WAAW,YAAY,IAAI;AAEtE,QAAM,UAAU,IAAI,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,IAAI,CAAC,GAAG,UAAU;AACjE,UAAM,SAA4C;AAAA,MAChD,OAAO,QAAQ,GAAG,SAAS;AAAA,MAC3B,QAAQ,QAAQ,GAAG,SAAS;AAAA,MAC5B,OAAO,QAAQ;AAAA,MACf,MAAM;AAAA,IACR;AACA,QAAI,aAAa,QAAQ;AACvB,aAAO,SAAS,kBAAkB,EAAE,eAAe,WAAW,OAAO,YAAY,CAAC;AAAA,IACpF;AACA,WAAO;AAAA,EACT,CAAC;AACD,SAAO;AACT;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|