@atlaskit/pagination 14.1.2 → 14.1.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/CHANGELOG.md +19 -0
- package/dist/cjs/internal/components/navigator.js +8 -2
- package/dist/cjs/internal/components/render-ellipsis.js +8 -3
- package/dist/cjs/pagination.js +8 -6
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/internal/components/navigator.js +8 -3
- package/dist/es2019/internal/components/render-ellipsis.js +8 -3
- package/dist/es2019/pagination.js +7 -6
- package/dist/es2019/version.json +1 -1
- package/dist/esm/internal/components/navigator.js +8 -3
- package/dist/esm/internal/components/render-ellipsis.js +8 -3
- package/dist/esm/pagination.js +9 -6
- package/dist/esm/version.json +1 -1
- package/dist/types/internal/components/page.d.ts +1 -0
- package/package.json +14 -12
- package/dist/cjs/internal/styles.js +0 -26
- package/dist/es2019/internal/styles.js +0 -15
- package/dist/esm/internal/styles.js +0 -15
- package/dist/types/internal/styles.d.ts +0 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# @atlaskit/pagination
|
|
2
2
|
|
|
3
|
+
## 14.1.5
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 14.1.4
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [`f8678250d08`](https://bitbucket.org/atlassian/atlassian-frontend/commits/f8678250d08) - Styles have been rewritten to prepare for migration to compiled.
|
|
14
|
+
- Updated dependencies
|
|
15
|
+
|
|
16
|
+
## 14.1.3
|
|
17
|
+
|
|
18
|
+
### Patch Changes
|
|
19
|
+
|
|
20
|
+
- [`19d72473dfb`](https://bitbucket.org/atlassian/atlassian-frontend/commits/19d72473dfb) - Bump dependency tiny-invariant to latest"
|
|
21
|
+
|
|
3
22
|
## 14.1.2
|
|
4
23
|
|
|
5
24
|
### Patch Changes
|
|
@@ -15,13 +15,19 @@ var _core = require("@emotion/core");
|
|
|
15
15
|
|
|
16
16
|
var _standardButton = _interopRequireDefault(require("@atlaskit/button/standard-button"));
|
|
17
17
|
|
|
18
|
-
var
|
|
18
|
+
var _constants = require("@atlaskit/theme/constants");
|
|
19
19
|
|
|
20
20
|
/** @jsx jsx */
|
|
21
|
+
var gridSize = (0, _constants.gridSize)();
|
|
22
|
+
var navigatorStyles = (0, _core.css)({
|
|
23
|
+
paddingRight: gridSize / 2,
|
|
24
|
+
paddingLeft: gridSize / 2
|
|
25
|
+
});
|
|
26
|
+
|
|
21
27
|
function Navigator(props) {
|
|
22
28
|
return (0, _core.jsx)(_standardButton.default, (0, _extends2.default)({}, props, {
|
|
23
29
|
appearance: "subtle",
|
|
24
30
|
spacing: "none",
|
|
25
|
-
css:
|
|
31
|
+
css: navigatorStyles
|
|
26
32
|
}));
|
|
27
33
|
}
|
|
@@ -7,13 +7,18 @@ exports.default = renderEllipsis;
|
|
|
7
7
|
|
|
8
8
|
var _core = require("@emotion/core");
|
|
9
9
|
|
|
10
|
-
var _styles = require("../styles");
|
|
11
|
-
|
|
12
10
|
/** @jsx jsx */
|
|
11
|
+
var ellipsisStyles = (0, _core.css)({
|
|
12
|
+
display: 'inline-flex',
|
|
13
|
+
padding: '0 8px',
|
|
14
|
+
alignItems: 'center',
|
|
15
|
+
textAlign: 'center'
|
|
16
|
+
});
|
|
17
|
+
|
|
13
18
|
function renderEllipsis(_ref) {
|
|
14
19
|
var key = _ref.key;
|
|
15
20
|
return (0, _core.jsx)("span", {
|
|
16
21
|
key: key,
|
|
17
|
-
css:
|
|
22
|
+
css: ellipsisStyles
|
|
18
23
|
}, "...");
|
|
19
24
|
}
|
package/dist/cjs/pagination.js
CHANGED
|
@@ -33,19 +33,20 @@ var _renderEllipsis = _interopRequireDefault(require("./internal/components/rend
|
|
|
33
33
|
|
|
34
34
|
var _constants = require("./internal/constants");
|
|
35
35
|
|
|
36
|
-
var _styles = require("./internal/styles");
|
|
37
|
-
|
|
38
36
|
var _collapseRange = _interopRequireDefault(require("./internal/utils/collapse-range"));
|
|
39
37
|
|
|
40
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
38
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
41
39
|
|
|
42
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
40
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
43
41
|
|
|
44
42
|
var analyticsAttributes = {
|
|
45
43
|
componentName: 'pagination',
|
|
46
44
|
packageName: "@atlaskit/pagination",
|
|
47
|
-
packageVersion: "14.1.
|
|
45
|
+
packageVersion: "14.1.5"
|
|
48
46
|
};
|
|
47
|
+
var navStyles = (0, _core.css)({
|
|
48
|
+
display: 'flex'
|
|
49
|
+
});
|
|
49
50
|
|
|
50
51
|
function InnerPagination(_ref, ref) {
|
|
51
52
|
var _ref$components = _ref.components,
|
|
@@ -116,7 +117,8 @@ function InnerPagination(_ref, ref) {
|
|
|
116
117
|
|
|
117
118
|
return (0, _core.jsx)("nav", {
|
|
118
119
|
"data-testid": testId,
|
|
119
|
-
css:
|
|
120
|
+
css: navStyles,
|
|
121
|
+
style: style,
|
|
120
122
|
ref: ref,
|
|
121
123
|
"aria-label": label
|
|
122
124
|
}, (0, _core.jsx)(_navigator.default, {
|
package/dist/cjs/version.json
CHANGED
|
@@ -2,13 +2,18 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
import React from 'react';
|
|
5
|
-
import { jsx } from '@emotion/core';
|
|
5
|
+
import { css, jsx } from '@emotion/core';
|
|
6
6
|
import Button from '@atlaskit/button/standard-button';
|
|
7
|
-
import {
|
|
7
|
+
import { gridSize as getGridSize } from '@atlaskit/theme/constants';
|
|
8
|
+
const gridSize = getGridSize();
|
|
9
|
+
const navigatorStyles = css({
|
|
10
|
+
paddingRight: gridSize / 2,
|
|
11
|
+
paddingLeft: gridSize / 2
|
|
12
|
+
});
|
|
8
13
|
export default function Navigator(props) {
|
|
9
14
|
return jsx(Button, _extends({}, props, {
|
|
10
15
|
appearance: "subtle",
|
|
11
16
|
spacing: "none",
|
|
12
|
-
css:
|
|
17
|
+
css: navigatorStyles
|
|
13
18
|
}));
|
|
14
19
|
}
|
|
@@ -1,11 +1,16 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
|
-
import { jsx } from '@emotion/core';
|
|
3
|
-
|
|
2
|
+
import { css, jsx } from '@emotion/core';
|
|
3
|
+
const ellipsisStyles = css({
|
|
4
|
+
display: 'inline-flex',
|
|
5
|
+
padding: '0 8px',
|
|
6
|
+
alignItems: 'center',
|
|
7
|
+
textAlign: 'center'
|
|
8
|
+
});
|
|
4
9
|
export default function renderEllipsis({
|
|
5
10
|
key
|
|
6
11
|
}) {
|
|
7
12
|
return jsx("span", {
|
|
8
13
|
key: key,
|
|
9
|
-
css:
|
|
14
|
+
css: ellipsisStyles
|
|
10
15
|
}, "...");
|
|
11
16
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
2
|
import { forwardRef, memo } from 'react';
|
|
3
|
-
import { jsx } from '@emotion/core';
|
|
3
|
+
import { css, jsx } from '@emotion/core';
|
|
4
4
|
import { usePlatformLeafEventHandler } from '@atlaskit/analytics-next';
|
|
5
5
|
import noop from '@atlaskit/ds-lib/noop';
|
|
6
6
|
import useControlled from '@atlaskit/ds-lib/use-controlled';
|
|
@@ -10,13 +10,15 @@ import Navigator from './internal/components/navigator';
|
|
|
10
10
|
import PageComponent from './internal/components/page';
|
|
11
11
|
import renderDefaultEllipsis from './internal/components/render-ellipsis';
|
|
12
12
|
import { emptyObject } from './internal/constants';
|
|
13
|
-
import { navStyle } from './internal/styles';
|
|
14
13
|
import collapseRange from './internal/utils/collapse-range';
|
|
15
14
|
const analyticsAttributes = {
|
|
16
15
|
componentName: 'pagination',
|
|
17
16
|
packageName: "@atlaskit/pagination",
|
|
18
|
-
packageVersion: "14.1.
|
|
17
|
+
packageVersion: "14.1.5"
|
|
19
18
|
};
|
|
19
|
+
const navStyles = css({
|
|
20
|
+
display: 'flex'
|
|
21
|
+
});
|
|
20
22
|
|
|
21
23
|
function InnerPagination({
|
|
22
24
|
components = emptyObject,
|
|
@@ -73,9 +75,8 @@ function InnerPagination({
|
|
|
73
75
|
|
|
74
76
|
return jsx("nav", {
|
|
75
77
|
"data-testid": testId,
|
|
76
|
-
css:
|
|
77
|
-
|
|
78
|
-
},
|
|
78
|
+
css: navStyles,
|
|
79
|
+
style: style,
|
|
79
80
|
ref: ref,
|
|
80
81
|
"aria-label": label
|
|
81
82
|
}, jsx(Navigator, {
|
package/dist/es2019/version.json
CHANGED
|
@@ -2,13 +2,18 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
import React from 'react';
|
|
5
|
-
import { jsx } from '@emotion/core';
|
|
5
|
+
import { css, jsx } from '@emotion/core';
|
|
6
6
|
import Button from '@atlaskit/button/standard-button';
|
|
7
|
-
import {
|
|
7
|
+
import { gridSize as getGridSize } from '@atlaskit/theme/constants';
|
|
8
|
+
var gridSize = getGridSize();
|
|
9
|
+
var navigatorStyles = css({
|
|
10
|
+
paddingRight: gridSize / 2,
|
|
11
|
+
paddingLeft: gridSize / 2
|
|
12
|
+
});
|
|
8
13
|
export default function Navigator(props) {
|
|
9
14
|
return jsx(Button, _extends({}, props, {
|
|
10
15
|
appearance: "subtle",
|
|
11
16
|
spacing: "none",
|
|
12
|
-
css:
|
|
17
|
+
css: navigatorStyles
|
|
13
18
|
}));
|
|
14
19
|
}
|
|
@@ -1,10 +1,15 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
|
-
import { jsx } from '@emotion/core';
|
|
3
|
-
|
|
2
|
+
import { css, jsx } from '@emotion/core';
|
|
3
|
+
var ellipsisStyles = css({
|
|
4
|
+
display: 'inline-flex',
|
|
5
|
+
padding: '0 8px',
|
|
6
|
+
alignItems: 'center',
|
|
7
|
+
textAlign: 'center'
|
|
8
|
+
});
|
|
4
9
|
export default function renderEllipsis(_ref) {
|
|
5
10
|
var key = _ref.key;
|
|
6
11
|
return jsx("span", {
|
|
7
12
|
key: key,
|
|
8
|
-
css:
|
|
13
|
+
css: ellipsisStyles
|
|
9
14
|
}, "...");
|
|
10
15
|
}
|
package/dist/esm/pagination.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
3
|
|
|
4
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
4
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
5
5
|
|
|
6
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
6
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7
7
|
|
|
8
8
|
/** @jsx jsx */
|
|
9
9
|
import { forwardRef, memo } from 'react';
|
|
10
|
-
import { jsx } from '@emotion/core';
|
|
10
|
+
import { css, jsx } from '@emotion/core';
|
|
11
11
|
import { usePlatformLeafEventHandler } from '@atlaskit/analytics-next';
|
|
12
12
|
import noop from '@atlaskit/ds-lib/noop';
|
|
13
13
|
import useControlled from '@atlaskit/ds-lib/use-controlled';
|
|
@@ -17,13 +17,15 @@ import Navigator from './internal/components/navigator';
|
|
|
17
17
|
import PageComponent from './internal/components/page';
|
|
18
18
|
import renderDefaultEllipsis from './internal/components/render-ellipsis';
|
|
19
19
|
import { emptyObject } from './internal/constants';
|
|
20
|
-
import { navStyle } from './internal/styles';
|
|
21
20
|
import collapseRange from './internal/utils/collapse-range';
|
|
22
21
|
var analyticsAttributes = {
|
|
23
22
|
componentName: 'pagination',
|
|
24
23
|
packageName: "@atlaskit/pagination",
|
|
25
|
-
packageVersion: "14.1.
|
|
24
|
+
packageVersion: "14.1.5"
|
|
26
25
|
};
|
|
26
|
+
var navStyles = css({
|
|
27
|
+
display: 'flex'
|
|
28
|
+
});
|
|
27
29
|
|
|
28
30
|
function InnerPagination(_ref, ref) {
|
|
29
31
|
var _ref$components = _ref.components,
|
|
@@ -94,7 +96,8 @@ function InnerPagination(_ref, ref) {
|
|
|
94
96
|
|
|
95
97
|
return jsx("nav", {
|
|
96
98
|
"data-testid": testId,
|
|
97
|
-
css:
|
|
99
|
+
css: navStyles,
|
|
100
|
+
style: style,
|
|
98
101
|
ref: ref,
|
|
99
102
|
"aria-label": label
|
|
100
103
|
}, jsx(Navigator, {
|
package/dist/esm/version.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/pagination",
|
|
3
|
-
"version": "14.1.
|
|
3
|
+
"version": "14.1.5",
|
|
4
4
|
"description": "Pagination allows you to divide large amounts of content into smaller chunks across multiple pages.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -16,7 +16,6 @@
|
|
|
16
16
|
"atlaskit:src": "src/index.ts",
|
|
17
17
|
"atlassian": {
|
|
18
18
|
"team": "Design System Team",
|
|
19
|
-
"inPublicMirror": true,
|
|
20
19
|
"releaseModel": "scheduled",
|
|
21
20
|
"website": {
|
|
22
21
|
"name": "Pagination"
|
|
@@ -24,11 +23,11 @@
|
|
|
24
23
|
},
|
|
25
24
|
"dependencies": {
|
|
26
25
|
"@atlaskit/analytics-next": "^8.0.0",
|
|
27
|
-
"@atlaskit/button": "^16.
|
|
28
|
-
"@atlaskit/codemod-utils": "^
|
|
29
|
-
"@atlaskit/ds-lib": "^1.
|
|
30
|
-
"@atlaskit/icon": "^21.
|
|
31
|
-
"@atlaskit/theme": "^12.
|
|
26
|
+
"@atlaskit/button": "^16.2.0",
|
|
27
|
+
"@atlaskit/codemod-utils": "^4.0.0",
|
|
28
|
+
"@atlaskit/ds-lib": "^1.4.0",
|
|
29
|
+
"@atlaskit/icon": "^21.10.0",
|
|
30
|
+
"@atlaskit/theme": "^12.1.0",
|
|
32
31
|
"@babel/runtime": "^7.0.0",
|
|
33
32
|
"@emotion/core": "^10.0.9",
|
|
34
33
|
"memoize-one": "^6.0.0"
|
|
@@ -37,9 +36,8 @@
|
|
|
37
36
|
"react": "^16.8.0"
|
|
38
37
|
},
|
|
39
38
|
"devDependencies": {
|
|
40
|
-
"@atlaskit/build-utils": "*",
|
|
41
39
|
"@atlaskit/docs": "*",
|
|
42
|
-
"@atlaskit/dynamic-table": "^14.
|
|
40
|
+
"@atlaskit/dynamic-table": "^14.5.0",
|
|
43
41
|
"@atlaskit/section-message": "^6.1.0",
|
|
44
42
|
"@atlaskit/ssr": "*",
|
|
45
43
|
"@atlaskit/visual-regression": "*",
|
|
@@ -52,8 +50,8 @@
|
|
|
52
50
|
"react-dom": "^16.8.0",
|
|
53
51
|
"react-router-dom": "^4.2.2",
|
|
54
52
|
"storybook-addon-performance": "^0.16.0",
|
|
55
|
-
"tiny-invariant": "^
|
|
56
|
-
"typescript": "3.9.
|
|
53
|
+
"tiny-invariant": "^1.2.0",
|
|
54
|
+
"typescript": "3.9.10",
|
|
57
55
|
"wait-for-expect": "^1.2.0"
|
|
58
56
|
},
|
|
59
57
|
"techstack": {
|
|
@@ -64,7 +62,11 @@
|
|
|
64
62
|
"ui-components": "lite-mode",
|
|
65
63
|
"analytics": "analytics-next",
|
|
66
64
|
"theming": "tokens",
|
|
67
|
-
"deprecation": "no-deprecated-imports"
|
|
65
|
+
"deprecation": "no-deprecated-imports",
|
|
66
|
+
"styling": [
|
|
67
|
+
"emotion",
|
|
68
|
+
"static"
|
|
69
|
+
]
|
|
68
70
|
}
|
|
69
71
|
},
|
|
70
72
|
"af:exports": {
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.navigatorStyle = exports.navStyle = exports.ellipsisStyle = void 0;
|
|
7
|
-
|
|
8
|
-
var _constants = require("@atlaskit/theme/constants");
|
|
9
|
-
|
|
10
|
-
var ellipsisStyle = {
|
|
11
|
-
display: 'inline-flex',
|
|
12
|
-
textAlign: 'center',
|
|
13
|
-
alignItems: 'center',
|
|
14
|
-
padding: '0 8px'
|
|
15
|
-
};
|
|
16
|
-
exports.ellipsisStyle = ellipsisStyle;
|
|
17
|
-
var navStyle = {
|
|
18
|
-
display: 'flex'
|
|
19
|
-
};
|
|
20
|
-
exports.navStyle = navStyle;
|
|
21
|
-
var halfGridSize = (0, _constants.gridSize)() / 2;
|
|
22
|
-
var navigatorStyle = {
|
|
23
|
-
paddingLeft: halfGridSize,
|
|
24
|
-
paddingRight: halfGridSize
|
|
25
|
-
};
|
|
26
|
-
exports.navigatorStyle = navigatorStyle;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { gridSize } from '@atlaskit/theme/constants';
|
|
2
|
-
export const ellipsisStyle = {
|
|
3
|
-
display: 'inline-flex',
|
|
4
|
-
textAlign: 'center',
|
|
5
|
-
alignItems: 'center',
|
|
6
|
-
padding: '0 8px'
|
|
7
|
-
};
|
|
8
|
-
export const navStyle = {
|
|
9
|
-
display: 'flex'
|
|
10
|
-
};
|
|
11
|
-
const halfGridSize = gridSize() / 2;
|
|
12
|
-
export const navigatorStyle = {
|
|
13
|
-
paddingLeft: halfGridSize,
|
|
14
|
-
paddingRight: halfGridSize
|
|
15
|
-
};
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { gridSize } from '@atlaskit/theme/constants';
|
|
2
|
-
export var ellipsisStyle = {
|
|
3
|
-
display: 'inline-flex',
|
|
4
|
-
textAlign: 'center',
|
|
5
|
-
alignItems: 'center',
|
|
6
|
-
padding: '0 8px'
|
|
7
|
-
};
|
|
8
|
-
export var navStyle = {
|
|
9
|
-
display: 'flex'
|
|
10
|
-
};
|
|
11
|
-
var halfGridSize = gridSize() / 2;
|
|
12
|
-
export var navigatorStyle = {
|
|
13
|
-
paddingLeft: halfGridSize,
|
|
14
|
-
paddingRight: halfGridSize
|
|
15
|
-
};
|