@atlaskit/dynamic-table 14.18.1 → 14.18.3
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 +14 -0
- package/dist/cjs/components/body.js +13 -10
- package/dist/cjs/components/rankable/body.js +1 -1
- package/dist/cjs/components/rankable/table-cell.js +1 -1
- package/dist/cjs/components/rankable/table-head-cell.js +11 -8
- package/dist/cjs/components/rankable/table-row.js +1 -1
- package/dist/cjs/components/stateless.js +13 -3
- package/dist/cjs/styled/constants.js +4 -4
- package/dist/es2019/components/body.js +7 -4
- package/dist/es2019/components/rankable/body.js +2 -0
- package/dist/es2019/components/rankable/table-cell.js +2 -0
- package/dist/es2019/components/rankable/table-head-cell.js +5 -2
- package/dist/es2019/components/rankable/table-row.js +2 -0
- package/dist/es2019/components/stateless.js +13 -3
- package/dist/es2019/styled/constants.js +4 -4
- package/dist/esm/components/body.js +13 -10
- package/dist/esm/components/rankable/body.js +2 -0
- package/dist/esm/components/rankable/table-cell.js +2 -0
- package/dist/esm/components/rankable/table-head-cell.js +11 -8
- package/dist/esm/components/rankable/table-row.js +2 -0
- package/dist/esm/components/stateless.js +13 -3
- package/dist/esm/styled/constants.js +4 -4
- package/dist/types/components/body.d.ts +2 -2
- package/dist/types/components/rankable/table-head-cell.d.ts +2 -2
- package/dist/types/components/stateless.d.ts +10 -2
- package/dist/types-ts4.5/components/body.d.ts +2 -2
- package/dist/types-ts4.5/components/rankable/table-head-cell.d.ts +2 -2
- package/dist/types-ts4.5/components/stateless.d.ts +10 -2
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @atlaskit/dynamic-table
|
|
2
2
|
|
|
3
|
+
## 14.18.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#120049](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/120049)
|
|
8
|
+
[`77504ff274f72`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/77504ff274f72) -
|
|
9
|
+
DSP-19576: Assign names to anonymous default exports
|
|
10
|
+
|
|
11
|
+
## 14.18.2
|
|
12
|
+
|
|
13
|
+
### Patch Changes
|
|
14
|
+
|
|
15
|
+
- Updated dependencies
|
|
16
|
+
|
|
3
17
|
## 14.18.1
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
|
@@ -16,14 +16,14 @@ var _withSortedPageRows = _interopRequireDefault(require("../hoc/with-sorted-pag
|
|
|
16
16
|
var _tableRow = _interopRequireDefault(require("./table-row"));
|
|
17
17
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
18
18
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
19
|
-
var
|
|
20
|
-
(0, _inherits2.default)(
|
|
21
|
-
var _super = _createSuper(
|
|
22
|
-
function
|
|
23
|
-
(0, _classCallCheck2.default)(this,
|
|
19
|
+
var BodyComponent = /*#__PURE__*/function (_React$Component) {
|
|
20
|
+
(0, _inherits2.default)(BodyComponent, _React$Component);
|
|
21
|
+
var _super = _createSuper(BodyComponent);
|
|
22
|
+
function BodyComponent() {
|
|
23
|
+
(0, _classCallCheck2.default)(this, BodyComponent);
|
|
24
24
|
return _super.apply(this, arguments);
|
|
25
25
|
}
|
|
26
|
-
(0, _createClass2.default)(
|
|
26
|
+
(0, _createClass2.default)(BodyComponent, [{
|
|
27
27
|
key: "render",
|
|
28
28
|
value: function render() {
|
|
29
29
|
var _this$props = this.props,
|
|
@@ -48,10 +48,13 @@ var Body = /*#__PURE__*/function (_React$Component) {
|
|
|
48
48
|
}));
|
|
49
49
|
}
|
|
50
50
|
}]);
|
|
51
|
-
return
|
|
51
|
+
return BodyComponent;
|
|
52
52
|
}(_react.default.Component);
|
|
53
|
-
var
|
|
54
|
-
return /*#__PURE__*/_react.default.createElement(
|
|
53
|
+
var Body = (0, _withSortedPageRows.default)( /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
54
|
+
return /*#__PURE__*/_react.default.createElement(BodyComponent, (0, _extends2.default)({}, props, {
|
|
55
55
|
forwardedRef: ref
|
|
56
56
|
}));
|
|
57
|
-
}));
|
|
57
|
+
}));
|
|
58
|
+
|
|
59
|
+
// eslint-disable-next-line @repo/internal/react/require-jsdoc
|
|
60
|
+
var _default = exports.default = Body;
|
|
@@ -121,7 +121,7 @@ var RankableBody = exports.RankableBody = /*#__PURE__*/function (_React$Componen
|
|
|
121
121
|
}
|
|
122
122
|
}]);
|
|
123
123
|
return RankableBody;
|
|
124
|
-
}(_react.default.Component);
|
|
124
|
+
}(_react.default.Component); // eslint-disable-next-line import/no-anonymous-default-export
|
|
125
125
|
var _default = exports.default = (0, _withSortedPageRows.default)( /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
126
126
|
return /*#__PURE__*/_react.default.createElement(RankableBody, (0, _extends2.default)({}, props, {
|
|
127
127
|
forwardedRef: ref
|
|
@@ -61,5 +61,5 @@ var RankableTableCell = exports.RankableTableCell = /*#__PURE__*/function (_Reac
|
|
|
61
61
|
}
|
|
62
62
|
}]);
|
|
63
63
|
return RankableTableCell;
|
|
64
|
-
}(_react.default.Component);
|
|
64
|
+
}(_react.default.Component); // eslint-disable-next-line import/no-anonymous-default-export
|
|
65
65
|
var _default = exports.default = (0, _withDimensions.default)(RankableTableCell);
|
|
@@ -19,14 +19,14 @@ var _tableHeadCell = _interopRequireDefault(require("../table-head-cell"));
|
|
|
19
19
|
var _excluded = ["isRanking", "refHeight", "refWidth"];
|
|
20
20
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
21
21
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
22
|
-
var
|
|
23
|
-
(0, _inherits2.default)(
|
|
24
|
-
var _super = _createSuper(
|
|
25
|
-
function
|
|
26
|
-
(0, _classCallCheck2.default)(this,
|
|
22
|
+
var RankableTableHeadCellComponent = /*#__PURE__*/function (_React$Component) {
|
|
23
|
+
(0, _inherits2.default)(RankableTableHeadCellComponent, _React$Component);
|
|
24
|
+
var _super = _createSuper(RankableTableHeadCellComponent);
|
|
25
|
+
function RankableTableHeadCellComponent() {
|
|
26
|
+
(0, _classCallCheck2.default)(this, RankableTableHeadCellComponent);
|
|
27
27
|
return _super.apply(this, arguments);
|
|
28
28
|
}
|
|
29
|
-
(0, _createClass2.default)(
|
|
29
|
+
(0, _createClass2.default)(RankableTableHeadCellComponent, [{
|
|
30
30
|
key: "render",
|
|
31
31
|
value: function render() {
|
|
32
32
|
var _this$props = this.props,
|
|
@@ -40,6 +40,9 @@ var RankableTableHeadCell = /*#__PURE__*/function (_React$Component) {
|
|
|
40
40
|
}, restProps));
|
|
41
41
|
}
|
|
42
42
|
}]);
|
|
43
|
-
return
|
|
43
|
+
return RankableTableHeadCellComponent;
|
|
44
44
|
}(_react.default.Component);
|
|
45
|
-
var
|
|
45
|
+
var RankableTableHeadCell = (0, _withDimensions.default)(RankableTableHeadCellComponent);
|
|
46
|
+
|
|
47
|
+
// eslint-disable-next-line @repo/internal/react/require-jsdoc
|
|
48
|
+
var _default = exports.default = RankableTableHeadCell;
|
|
@@ -104,5 +104,5 @@ var RankableTableRow = exports.RankableTableRow = /*#__PURE__*/function (_React$
|
|
|
104
104
|
}
|
|
105
105
|
}]);
|
|
106
106
|
return RankableTableRow;
|
|
107
|
-
}(_react.default.Component);
|
|
107
|
+
}(_react.default.Component); // eslint-disable-next-line import/no-anonymous-default-export
|
|
108
108
|
var _default = exports.default = (0, _withDimensions.default)(RankableTableRow);
|
|
@@ -35,7 +35,7 @@ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e;
|
|
|
35
35
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
36
36
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
37
37
|
var packageName = "@atlaskit/dynamic-table";
|
|
38
|
-
var packageVersion = "14.18.
|
|
38
|
+
var packageVersion = "14.18.3";
|
|
39
39
|
function toggleSortOrder(currentSortOrder) {
|
|
40
40
|
switch (currentSortOrder) {
|
|
41
41
|
case _constants.DESC:
|
|
@@ -327,7 +327,16 @@ var TableBody = /*#__PURE__*/(0, _react.forwardRef)(function TableBody(_ref, ref
|
|
|
327
327
|
})))) : nonRankableBody;
|
|
328
328
|
});
|
|
329
329
|
var createAndFireEventOnAtlaskit = (0, _analyticsNext.createAndFireEvent)('atlaskit');
|
|
330
|
-
|
|
330
|
+
|
|
331
|
+
/**
|
|
332
|
+
* __Dynamic table stateless__
|
|
333
|
+
*
|
|
334
|
+
* A stateless table that requires consumers to manage the sorting, drag and drop, and pagination.
|
|
335
|
+
*
|
|
336
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/dynamic-table)
|
|
337
|
+
* - [Code](https://bitbucket.org/atlassian/atlassian-frontend/packages/design-system/dynamic-table)
|
|
338
|
+
*/
|
|
339
|
+
var DynamicTableStateless = (0, _analyticsNext.withAnalyticsContext)({
|
|
331
340
|
componentName: 'dynamicTable',
|
|
332
341
|
packageName: packageName,
|
|
333
342
|
packageVersion: packageVersion
|
|
@@ -350,4 +359,5 @@ var _default = exports.default = (0, _analyticsNext.withAnalyticsContext)({
|
|
|
350
359
|
packageVersion: packageVersion
|
|
351
360
|
}
|
|
352
361
|
})
|
|
353
|
-
})(DynamicTable));
|
|
362
|
+
})(DynamicTable));
|
|
363
|
+
var _default = exports.default = DynamicTableStateless;
|
|
@@ -10,18 +10,18 @@ var _react = require("@emotion/react");
|
|
|
10
10
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
11
11
|
|
|
12
12
|
var CSS_VAR_WIDTH = '--local-dynamic-table-width';
|
|
13
|
-
// eslint-disable-next-line @atlaskit/
|
|
13
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
14
14
|
var truncationWidthStyles = exports.truncationWidthStyles = (0, _react.css)({
|
|
15
15
|
width: "var(".concat(CSS_VAR_WIDTH, ")")
|
|
16
16
|
});
|
|
17
17
|
|
|
18
|
-
// eslint-disable-next-line @atlaskit/
|
|
18
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
19
19
|
var fixedSizeTruncateStyles = exports.fixedSizeTruncateStyles = (0, _react.css)({
|
|
20
20
|
textOverflow: 'ellipsis',
|
|
21
21
|
whiteSpace: 'nowrap'
|
|
22
22
|
});
|
|
23
23
|
|
|
24
|
-
// eslint-disable-next-line @atlaskit/
|
|
24
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
25
25
|
var overflowTruncateStyles = exports.overflowTruncateStyles = (0, _react.css)({
|
|
26
26
|
overflow: 'hidden'
|
|
27
27
|
});
|
|
@@ -30,7 +30,7 @@ var getTruncationStyleVars = exports.getTruncationStyleVars = function getTrunca
|
|
|
30
30
|
return typeof width !== 'undefined' ? (0, _defineProperty2.default)({}, CSS_VAR_WIDTH, "".concat(width, "%")) : undefined;
|
|
31
31
|
};
|
|
32
32
|
|
|
33
|
-
// eslint-disable-next-line @atlaskit/
|
|
33
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
34
34
|
var cellStyles = exports.cellStyles = (0, _react.css)({
|
|
35
35
|
padding: "var(--ds-space-050, 4px)".concat(" ", "var(--ds-space-100, 8px)"),
|
|
36
36
|
border: 'none',
|
|
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import withSortedPageRows from '../hoc/with-sorted-page-rows';
|
|
4
4
|
import TableRow from './table-row';
|
|
5
|
-
class
|
|
5
|
+
class BodyComponent extends React.Component {
|
|
6
6
|
render() {
|
|
7
7
|
const {
|
|
8
8
|
pageRows,
|
|
@@ -25,8 +25,11 @@ class Body extends React.Component {
|
|
|
25
25
|
})));
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
|
-
|
|
29
|
-
return /*#__PURE__*/React.createElement(
|
|
28
|
+
const Body = withSortedPageRows( /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
29
|
+
return /*#__PURE__*/React.createElement(BodyComponent, _extends({}, props, {
|
|
30
30
|
forwardedRef: ref
|
|
31
31
|
}));
|
|
32
|
-
}));
|
|
32
|
+
}));
|
|
33
|
+
|
|
34
|
+
// eslint-disable-next-line @repo/internal/react/require-jsdoc
|
|
35
|
+
export default Body;
|
|
@@ -109,6 +109,8 @@ export class RankableBody extends React.Component {
|
|
|
109
109
|
})), provided.placeholder)));
|
|
110
110
|
}
|
|
111
111
|
}
|
|
112
|
+
|
|
113
|
+
// eslint-disable-next-line import/no-anonymous-default-export
|
|
112
114
|
export default withSortedPageRows( /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
113
115
|
return /*#__PURE__*/React.createElement(RankableBody, _extends({}, props, {
|
|
114
116
|
forwardedRef: ref
|
|
@@ -3,7 +3,7 @@ import React from 'react';
|
|
|
3
3
|
import withDimensions from '../../hoc/with-dimensions';
|
|
4
4
|
import { inlineStylesIfRanking } from '../../internal/helpers';
|
|
5
5
|
import HeadCell from '../table-head-cell';
|
|
6
|
-
class
|
|
6
|
+
class RankableTableHeadCellComponent extends React.Component {
|
|
7
7
|
render() {
|
|
8
8
|
const {
|
|
9
9
|
isRanking,
|
|
@@ -17,4 +17,7 @@ class RankableTableHeadCell extends React.Component {
|
|
|
17
17
|
}, restProps));
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
|
-
|
|
20
|
+
const RankableTableHeadCell = withDimensions(RankableTableHeadCellComponent);
|
|
21
|
+
|
|
22
|
+
// eslint-disable-next-line @repo/internal/react/require-jsdoc
|
|
23
|
+
export default RankableTableHeadCell;
|
|
@@ -14,7 +14,7 @@ import LoadingContainerAdvanced from './loading-container-advanced';
|
|
|
14
14
|
import ManagedPagination from './managed-pagination';
|
|
15
15
|
import TableHead from './table-head';
|
|
16
16
|
const packageName = "@atlaskit/dynamic-table";
|
|
17
|
-
const packageVersion = "14.18.
|
|
17
|
+
const packageVersion = "14.18.3";
|
|
18
18
|
function toggleSortOrder(currentSortOrder) {
|
|
19
19
|
switch (currentSortOrder) {
|
|
20
20
|
case DESC:
|
|
@@ -287,7 +287,16 @@ const TableBody = /*#__PURE__*/forwardRef(function TableBody({
|
|
|
287
287
|
});
|
|
288
288
|
export { DynamicTable as DynamicTableWithoutAnalytics };
|
|
289
289
|
const createAndFireEventOnAtlaskit = createAndFireEvent('atlaskit');
|
|
290
|
-
|
|
290
|
+
|
|
291
|
+
/**
|
|
292
|
+
* __Dynamic table stateless__
|
|
293
|
+
*
|
|
294
|
+
* A stateless table that requires consumers to manage the sorting, drag and drop, and pagination.
|
|
295
|
+
*
|
|
296
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/dynamic-table)
|
|
297
|
+
* - [Code](https://bitbucket.org/atlassian/atlassian-frontend/packages/design-system/dynamic-table)
|
|
298
|
+
*/
|
|
299
|
+
const DynamicTableStateless = withAnalyticsContext({
|
|
291
300
|
componentName: 'dynamicTable',
|
|
292
301
|
packageName,
|
|
293
302
|
packageVersion
|
|
@@ -310,4 +319,5 @@ export default withAnalyticsContext({
|
|
|
310
319
|
packageVersion
|
|
311
320
|
}
|
|
312
321
|
})
|
|
313
|
-
})(DynamicTable));
|
|
322
|
+
})(DynamicTable));
|
|
323
|
+
export default DynamicTableStateless;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
2
2
|
import { css } from '@emotion/react';
|
|
3
3
|
const CSS_VAR_WIDTH = '--local-dynamic-table-width';
|
|
4
|
-
// eslint-disable-next-line @atlaskit/
|
|
4
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
5
5
|
export const truncationWidthStyles = css({
|
|
6
6
|
width: `var(${CSS_VAR_WIDTH})`
|
|
7
7
|
});
|
|
8
8
|
|
|
9
|
-
// eslint-disable-next-line @atlaskit/
|
|
9
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
10
10
|
export const fixedSizeTruncateStyles = css({
|
|
11
11
|
textOverflow: 'ellipsis',
|
|
12
12
|
whiteSpace: 'nowrap'
|
|
13
13
|
});
|
|
14
14
|
|
|
15
|
-
// eslint-disable-next-line @atlaskit/
|
|
15
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
16
16
|
export const overflowTruncateStyles = css({
|
|
17
17
|
overflow: 'hidden'
|
|
18
18
|
});
|
|
@@ -22,7 +22,7 @@ export const getTruncationStyleVars = ({
|
|
|
22
22
|
[CSS_VAR_WIDTH]: `${width}%`
|
|
23
23
|
} : undefined;
|
|
24
24
|
|
|
25
|
-
// eslint-disable-next-line @atlaskit/
|
|
25
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
26
26
|
export const cellStyles = css({
|
|
27
27
|
padding: `${"var(--ds-space-050, 4px)"} ${"var(--ds-space-100, 8px)"}`,
|
|
28
28
|
border: 'none',
|
|
@@ -9,14 +9,14 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
9
9
|
import React from 'react';
|
|
10
10
|
import withSortedPageRows from '../hoc/with-sorted-page-rows';
|
|
11
11
|
import TableRow from './table-row';
|
|
12
|
-
var
|
|
13
|
-
_inherits(
|
|
14
|
-
var _super = _createSuper(
|
|
15
|
-
function
|
|
16
|
-
_classCallCheck(this,
|
|
12
|
+
var BodyComponent = /*#__PURE__*/function (_React$Component) {
|
|
13
|
+
_inherits(BodyComponent, _React$Component);
|
|
14
|
+
var _super = _createSuper(BodyComponent);
|
|
15
|
+
function BodyComponent() {
|
|
16
|
+
_classCallCheck(this, BodyComponent);
|
|
17
17
|
return _super.apply(this, arguments);
|
|
18
18
|
}
|
|
19
|
-
_createClass(
|
|
19
|
+
_createClass(BodyComponent, [{
|
|
20
20
|
key: "render",
|
|
21
21
|
value: function render() {
|
|
22
22
|
var _this$props = this.props,
|
|
@@ -41,10 +41,13 @@ var Body = /*#__PURE__*/function (_React$Component) {
|
|
|
41
41
|
}));
|
|
42
42
|
}
|
|
43
43
|
}]);
|
|
44
|
-
return
|
|
44
|
+
return BodyComponent;
|
|
45
45
|
}(React.Component);
|
|
46
|
-
|
|
47
|
-
return /*#__PURE__*/React.createElement(
|
|
46
|
+
var Body = withSortedPageRows( /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
47
|
+
return /*#__PURE__*/React.createElement(BodyComponent, _extends({}, props, {
|
|
48
48
|
forwardedRef: ref
|
|
49
49
|
}));
|
|
50
|
-
}));
|
|
50
|
+
}));
|
|
51
|
+
|
|
52
|
+
// eslint-disable-next-line @repo/internal/react/require-jsdoc
|
|
53
|
+
export default Body;
|
|
@@ -117,6 +117,8 @@ export var RankableBody = /*#__PURE__*/function (_React$Component) {
|
|
|
117
117
|
}]);
|
|
118
118
|
return RankableBody;
|
|
119
119
|
}(React.Component);
|
|
120
|
+
|
|
121
|
+
// eslint-disable-next-line import/no-anonymous-default-export
|
|
120
122
|
export default withSortedPageRows( /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
121
123
|
return /*#__PURE__*/React.createElement(RankableBody, _extends({}, props, {
|
|
122
124
|
forwardedRef: ref
|
|
@@ -12,14 +12,14 @@ import React from 'react';
|
|
|
12
12
|
import withDimensions from '../../hoc/with-dimensions';
|
|
13
13
|
import { inlineStylesIfRanking } from '../../internal/helpers';
|
|
14
14
|
import HeadCell from '../table-head-cell';
|
|
15
|
-
var
|
|
16
|
-
_inherits(
|
|
17
|
-
var _super = _createSuper(
|
|
18
|
-
function
|
|
19
|
-
_classCallCheck(this,
|
|
15
|
+
var RankableTableHeadCellComponent = /*#__PURE__*/function (_React$Component) {
|
|
16
|
+
_inherits(RankableTableHeadCellComponent, _React$Component);
|
|
17
|
+
var _super = _createSuper(RankableTableHeadCellComponent);
|
|
18
|
+
function RankableTableHeadCellComponent() {
|
|
19
|
+
_classCallCheck(this, RankableTableHeadCellComponent);
|
|
20
20
|
return _super.apply(this, arguments);
|
|
21
21
|
}
|
|
22
|
-
_createClass(
|
|
22
|
+
_createClass(RankableTableHeadCellComponent, [{
|
|
23
23
|
key: "render",
|
|
24
24
|
value: function render() {
|
|
25
25
|
var _this$props = this.props,
|
|
@@ -33,6 +33,9 @@ var RankableTableHeadCell = /*#__PURE__*/function (_React$Component) {
|
|
|
33
33
|
}, restProps));
|
|
34
34
|
}
|
|
35
35
|
}]);
|
|
36
|
-
return
|
|
36
|
+
return RankableTableHeadCellComponent;
|
|
37
37
|
}(React.Component);
|
|
38
|
-
|
|
38
|
+
var RankableTableHeadCell = withDimensions(RankableTableHeadCellComponent);
|
|
39
|
+
|
|
40
|
+
// eslint-disable-next-line @repo/internal/react/require-jsdoc
|
|
41
|
+
export default RankableTableHeadCell;
|
|
@@ -25,7 +25,7 @@ import LoadingContainerAdvanced from './loading-container-advanced';
|
|
|
25
25
|
import ManagedPagination from './managed-pagination';
|
|
26
26
|
import TableHead from './table-head';
|
|
27
27
|
var packageName = "@atlaskit/dynamic-table";
|
|
28
|
-
var packageVersion = "14.18.
|
|
28
|
+
var packageVersion = "14.18.3";
|
|
29
29
|
function toggleSortOrder(currentSortOrder) {
|
|
30
30
|
switch (currentSortOrder) {
|
|
31
31
|
case DESC:
|
|
@@ -316,7 +316,16 @@ var TableBody = /*#__PURE__*/forwardRef(function TableBody(_ref, ref) {
|
|
|
316
316
|
});
|
|
317
317
|
export { DynamicTable as DynamicTableWithoutAnalytics };
|
|
318
318
|
var createAndFireEventOnAtlaskit = createAndFireEvent('atlaskit');
|
|
319
|
-
|
|
319
|
+
|
|
320
|
+
/**
|
|
321
|
+
* __Dynamic table stateless__
|
|
322
|
+
*
|
|
323
|
+
* A stateless table that requires consumers to manage the sorting, drag and drop, and pagination.
|
|
324
|
+
*
|
|
325
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/dynamic-table)
|
|
326
|
+
* - [Code](https://bitbucket.org/atlassian/atlassian-frontend/packages/design-system/dynamic-table)
|
|
327
|
+
*/
|
|
328
|
+
var DynamicTableStateless = withAnalyticsContext({
|
|
320
329
|
componentName: 'dynamicTable',
|
|
321
330
|
packageName: packageName,
|
|
322
331
|
packageVersion: packageVersion
|
|
@@ -339,4 +348,5 @@ export default withAnalyticsContext({
|
|
|
339
348
|
packageVersion: packageVersion
|
|
340
349
|
}
|
|
341
350
|
})
|
|
342
|
-
})(DynamicTable));
|
|
351
|
+
})(DynamicTable));
|
|
352
|
+
export default DynamicTableStateless;
|
|
@@ -2,18 +2,18 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
2
2
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
3
3
|
import { css } from '@emotion/react';
|
|
4
4
|
var CSS_VAR_WIDTH = '--local-dynamic-table-width';
|
|
5
|
-
// eslint-disable-next-line @atlaskit/
|
|
5
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
6
6
|
export var truncationWidthStyles = css({
|
|
7
7
|
width: "var(".concat(CSS_VAR_WIDTH, ")")
|
|
8
8
|
});
|
|
9
9
|
|
|
10
|
-
// eslint-disable-next-line @atlaskit/
|
|
10
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
11
11
|
export var fixedSizeTruncateStyles = css({
|
|
12
12
|
textOverflow: 'ellipsis',
|
|
13
13
|
whiteSpace: 'nowrap'
|
|
14
14
|
});
|
|
15
15
|
|
|
16
|
-
// eslint-disable-next-line @atlaskit/
|
|
16
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
17
17
|
export var overflowTruncateStyles = css({
|
|
18
18
|
overflow: 'hidden'
|
|
19
19
|
});
|
|
@@ -22,7 +22,7 @@ export var getTruncationStyleVars = function getTruncationStyleVars(_ref) {
|
|
|
22
22
|
return typeof width !== 'undefined' ? _defineProperty({}, CSS_VAR_WIDTH, "".concat(width, "%")) : undefined;
|
|
23
23
|
};
|
|
24
24
|
|
|
25
|
-
// eslint-disable-next-line @atlaskit/
|
|
25
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
26
26
|
export var cellStyles = css({
|
|
27
27
|
padding: "var(--ds-space-050, 4px)".concat(" ", "var(--ds-space-100, 8px)"),
|
|
28
28
|
border: 'none',
|
|
@@ -8,7 +8,7 @@ interface BodyProps extends WithSortedPageRowsProps {
|
|
|
8
8
|
forwardedRef?: React.Ref<HTMLTableSectionElement>;
|
|
9
9
|
testId?: string;
|
|
10
10
|
}
|
|
11
|
-
declare const
|
|
11
|
+
declare const Body: React.ForwardRefExoticComponent<Omit<BodyProps & import("../hoc/with-sorted-page-rows").TableProps, "pageRows"> & {
|
|
12
12
|
forwardedRef?: React.Ref<HTMLTableSectionElement> | undefined;
|
|
13
13
|
} & React.RefAttributes<HTMLTableSectionElement>>;
|
|
14
|
-
export default
|
|
14
|
+
export default Body;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type WithDimensionsProps } from '../../hoc/with-dimensions';
|
|
3
3
|
import { type TableHeadCellProps } from '../table-head-cell';
|
|
4
|
-
declare const
|
|
5
|
-
export default
|
|
4
|
+
declare const RankableTableHeadCell: React.ComponentClass<Omit<WithDimensionsProps & TableHeadCellProps, "innerRef" | "refWidth" | "refHeight">, import("../../hoc/with-dimensions").State>;
|
|
5
|
+
export default RankableTableHeadCell;
|
|
@@ -39,7 +39,15 @@ declare class DynamicTable extends React.Component<Props, State> {
|
|
|
39
39
|
render(): JSX.Element;
|
|
40
40
|
}
|
|
41
41
|
export { DynamicTable as DynamicTableWithoutAnalytics };
|
|
42
|
-
|
|
42
|
+
/**
|
|
43
|
+
* __Dynamic table stateless__
|
|
44
|
+
*
|
|
45
|
+
* A stateless table that requires consumers to manage the sorting, drag and drop, and pagination.
|
|
46
|
+
*
|
|
47
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/dynamic-table)
|
|
48
|
+
* - [Code](https://bitbucket.org/atlassian/atlassian-frontend/packages/design-system/dynamic-table)
|
|
49
|
+
*/
|
|
50
|
+
declare const DynamicTableStateless: React.ForwardRefExoticComponent<Pick<Pick<Omit<Props, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "head" | "caption" | "rows" | "emptyView" | "loadingSpinnerSize" | "loadingLabel" | "totalRows" | "onPageRowsUpdate" | "sortKey" | "sortOrder" | "highlightedRowIndex" | "testId" | "label"> & Partial<Pick<Omit<Props, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "isLoading" | "isFixedSize" | "rowsPerPage" | "onSetPage" | "onSort" | "page" | "isRankable" | "isRankingDisabled" | "onRankStart" | "onRankEnd" | "paginationi18n">> & Partial<Pick<{
|
|
43
51
|
isLoading: boolean;
|
|
44
52
|
isFixedSize: boolean;
|
|
45
53
|
rowsPerPage: number;
|
|
@@ -57,4 +65,4 @@ declare const _default: React.ForwardRefExoticComponent<Pick<Pick<Omit<Props, ke
|
|
|
57
65
|
pageLabel: string;
|
|
58
66
|
};
|
|
59
67
|
}, never>> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "head" | "caption" | "rows" | "emptyView" | "loadingSpinnerSize" | "isLoading" | "loadingLabel" | "isFixedSize" | "rowsPerPage" | "totalRows" | "onSetPage" | "onSort" | "onPageRowsUpdate" | "page" | "sortKey" | "sortOrder" | "isRankable" | "isRankingDisabled" | "onRankStart" | "onRankEnd" | "paginationi18n" | "highlightedRowIndex" | "testId" | "label" | "key" | "analyticsContext"> & React.RefAttributes<any>>;
|
|
60
|
-
export default
|
|
68
|
+
export default DynamicTableStateless;
|
|
@@ -8,7 +8,7 @@ interface BodyProps extends WithSortedPageRowsProps {
|
|
|
8
8
|
forwardedRef?: React.Ref<HTMLTableSectionElement>;
|
|
9
9
|
testId?: string;
|
|
10
10
|
}
|
|
11
|
-
declare const
|
|
11
|
+
declare const Body: React.ForwardRefExoticComponent<Omit<BodyProps & import("../hoc/with-sorted-page-rows").TableProps, "pageRows"> & {
|
|
12
12
|
forwardedRef?: React.Ref<HTMLTableSectionElement> | undefined;
|
|
13
13
|
} & React.RefAttributes<HTMLTableSectionElement>>;
|
|
14
|
-
export default
|
|
14
|
+
export default Body;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type WithDimensionsProps } from '../../hoc/with-dimensions';
|
|
3
3
|
import { type TableHeadCellProps } from '../table-head-cell';
|
|
4
|
-
declare const
|
|
5
|
-
export default
|
|
4
|
+
declare const RankableTableHeadCell: React.ComponentClass<Omit<WithDimensionsProps & TableHeadCellProps, "innerRef" | "refWidth" | "refHeight">, import("../../hoc/with-dimensions").State>;
|
|
5
|
+
export default RankableTableHeadCell;
|
|
@@ -39,7 +39,15 @@ declare class DynamicTable extends React.Component<Props, State> {
|
|
|
39
39
|
render(): JSX.Element;
|
|
40
40
|
}
|
|
41
41
|
export { DynamicTable as DynamicTableWithoutAnalytics };
|
|
42
|
-
|
|
42
|
+
/**
|
|
43
|
+
* __Dynamic table stateless__
|
|
44
|
+
*
|
|
45
|
+
* A stateless table that requires consumers to manage the sorting, drag and drop, and pagination.
|
|
46
|
+
*
|
|
47
|
+
* - [Examples](https://atlaskit.atlassian.com/packages/design-system/dynamic-table)
|
|
48
|
+
* - [Code](https://bitbucket.org/atlassian/atlassian-frontend/packages/design-system/dynamic-table)
|
|
49
|
+
*/
|
|
50
|
+
declare const DynamicTableStateless: React.ForwardRefExoticComponent<Pick<Pick<Omit<Props, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "head" | "caption" | "rows" | "emptyView" | "loadingSpinnerSize" | "loadingLabel" | "totalRows" | "onPageRowsUpdate" | "sortKey" | "sortOrder" | "highlightedRowIndex" | "testId" | "label"> & Partial<Pick<Omit<Props, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "isLoading" | "isFixedSize" | "rowsPerPage" | "onSetPage" | "onSort" | "page" | "isRankable" | "isRankingDisabled" | "onRankStart" | "onRankEnd" | "paginationi18n">> & Partial<Pick<{
|
|
43
51
|
isLoading: boolean;
|
|
44
52
|
isFixedSize: boolean;
|
|
45
53
|
rowsPerPage: number;
|
|
@@ -57,4 +65,4 @@ declare const _default: React.ForwardRefExoticComponent<Pick<Pick<Omit<Props, ke
|
|
|
57
65
|
pageLabel: string;
|
|
58
66
|
};
|
|
59
67
|
}, never>> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "head" | "caption" | "rows" | "emptyView" | "loadingSpinnerSize" | "isLoading" | "loadingLabel" | "isFixedSize" | "rowsPerPage" | "totalRows" | "onSetPage" | "onSort" | "onPageRowsUpdate" | "page" | "sortKey" | "sortOrder" | "isRankable" | "isRankingDisabled" | "onRankStart" | "onRankEnd" | "paginationi18n" | "highlightedRowIndex" | "testId" | "label" | "key" | "analyticsContext"> & React.RefAttributes<any>>;
|
|
60
|
-
export default
|
|
68
|
+
export default DynamicTableStateless;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/dynamic-table",
|
|
3
|
-
"version": "14.18.
|
|
3
|
+
"version": "14.18.3",
|
|
4
4
|
"description": "A dynamic table displays rows of data with built-in pagination, sorting, and re-ordering functionality.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -44,10 +44,10 @@
|
|
|
44
44
|
"@atlaskit/analytics-next": "^9.3.0",
|
|
45
45
|
"@atlaskit/ds-lib": "^2.3.0",
|
|
46
46
|
"@atlaskit/pagination": "^14.7.0",
|
|
47
|
-
"@atlaskit/platform-feature-flags": "^0.
|
|
47
|
+
"@atlaskit/platform-feature-flags": "^0.3.0",
|
|
48
48
|
"@atlaskit/spinner": "^16.2.0",
|
|
49
49
|
"@atlaskit/theme": "^12.11.0",
|
|
50
|
-
"@atlaskit/tokens": "^1.
|
|
50
|
+
"@atlaskit/tokens": "^1.54.0",
|
|
51
51
|
"@babel/runtime": "^7.0.0",
|
|
52
52
|
"@emotion/react": "^11.7.1",
|
|
53
53
|
"react-beautiful-dnd": "^12.2.0"
|