@atlaskit/dynamic-table 18.0.2 → 18.0.4
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 +18 -0
- package/dist/cjs/components/stateless.js +2 -2
- package/dist/cjs/styled/table-row.js +10 -3
- package/dist/es2019/components/stateless.js +2 -2
- package/dist/es2019/styled/table-row.js +9 -3
- package/dist/esm/components/stateless.js +2 -2
- package/dist/esm/styled/table-row.js +10 -3
- package/package.json +6 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @atlaskit/dynamic-table
|
|
2
2
|
|
|
3
|
+
## 18.0.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#129972](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/129972)
|
|
8
|
+
[`b2d69a39e6687`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/b2d69a39e6687) -
|
|
9
|
+
Update `@compiled/react` dependency for improved type checking support.
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
12
|
+
## 18.0.3
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- [#127951](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/127951)
|
|
17
|
+
[`149b6d2ba42ec`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/149b6d2ba42ec) -
|
|
18
|
+
Fixes a bug where styles were not applied to Rankable table rows when dragging, which could cause
|
|
19
|
+
layout issues.
|
|
20
|
+
|
|
3
21
|
## 18.0.2
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
|
@@ -87,14 +87,14 @@ var DynamicTable = function DynamicTable(_ref) {
|
|
|
87
87
|
action: 'sorted',
|
|
88
88
|
componentName: 'dynamicTable',
|
|
89
89
|
packageName: "@atlaskit/dynamic-table",
|
|
90
|
-
packageVersion: "18.0.
|
|
90
|
+
packageVersion: "18.0.4"
|
|
91
91
|
});
|
|
92
92
|
var onRankEnd = (0, _analyticsNext.usePlatformLeafEventHandler)({
|
|
93
93
|
fn: providedOnRankEnd,
|
|
94
94
|
action: 'ranked',
|
|
95
95
|
componentName: 'dynamicTable',
|
|
96
96
|
packageName: "@atlaskit/dynamic-table",
|
|
97
|
-
packageVersion: "18.0.
|
|
97
|
+
packageVersion: "18.0.4"
|
|
98
98
|
});
|
|
99
99
|
(0, _react.useEffect)(function () {
|
|
100
100
|
(0, _helpers.validateSortKey)(sortKey, head);
|
|
@@ -14,7 +14,7 @@ var _runtime = require("@compiled/react/runtime");
|
|
|
14
14
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
15
15
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
16
16
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
17
|
-
var _excluded = ["isHighlighted", "children", "style", "testId"];
|
|
17
|
+
var _excluded = ["isHighlighted", "children", "style", "testId", "className"];
|
|
18
18
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
19
19
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
20
20
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
@@ -29,11 +29,18 @@ var TableBodyRow = exports.TableBodyRow = /*#__PURE__*/(0, _react.forwardRef)(fu
|
|
|
29
29
|
children = _ref.children,
|
|
30
30
|
style = _ref.style,
|
|
31
31
|
testId = _ref.testId,
|
|
32
|
+
className = _ref.className,
|
|
32
33
|
rest = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
33
|
-
return /*#__PURE__*/React.createElement("tr", (0, _extends2.default)({
|
|
34
|
+
return /*#__PURE__*/React.createElement("tr", (0, _extends2.default)({
|
|
35
|
+
/**
|
|
36
|
+
* We rely on this `className` for the `RankableTableBodyRow` to apply extra styles.
|
|
37
|
+
* With Compiled it needs to be statically analyzable. It does not get applied via spread props.
|
|
38
|
+
*/
|
|
39
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
|
|
40
|
+
className: (0, _runtime.ax)(["_bfhkqtfy _1ygb1852 _1ah312gs", isHighlighted ? "_bfhktkjs _irr31ae3" : "_irr3s8ts", className])
|
|
41
|
+
}, rest, {
|
|
34
42
|
ref: ref,
|
|
35
43
|
"data-testid": testId,
|
|
36
|
-
className: (0, _runtime.ax)(["_bfhkqtfy _1ygb1852 _1ah312gs", isHighlighted ? "_bfhktkjs _irr31ae3" : "_irr3s8ts"]),
|
|
37
44
|
style: _objectSpread(_objectSpread({}, style), {}, {
|
|
38
45
|
"--_akp1ox": (0, _runtime.ix)("2px solid ".concat("var(--ds-border-focused, var(--local-dynamic-table-hover-bg))"))
|
|
39
46
|
})
|
|
@@ -61,14 +61,14 @@ const DynamicTable = ({
|
|
|
61
61
|
action: 'sorted',
|
|
62
62
|
componentName: 'dynamicTable',
|
|
63
63
|
packageName: "@atlaskit/dynamic-table",
|
|
64
|
-
packageVersion: "18.0.
|
|
64
|
+
packageVersion: "18.0.4"
|
|
65
65
|
});
|
|
66
66
|
const onRankEnd = usePlatformLeafEventHandler({
|
|
67
67
|
fn: providedOnRankEnd,
|
|
68
68
|
action: 'ranked',
|
|
69
69
|
componentName: 'dynamicTable',
|
|
70
70
|
packageName: "@atlaskit/dynamic-table",
|
|
71
|
-
packageVersion: "18.0.
|
|
71
|
+
packageVersion: "18.0.4"
|
|
72
72
|
});
|
|
73
73
|
useEffect(() => {
|
|
74
74
|
validateSortKey(sortKey, head);
|
|
@@ -14,14 +14,20 @@ export const TableBodyRow = /*#__PURE__*/forwardRef(({
|
|
|
14
14
|
children,
|
|
15
15
|
style,
|
|
16
16
|
testId,
|
|
17
|
+
className,
|
|
17
18
|
...rest
|
|
18
19
|
}, ref) => {
|
|
19
20
|
return /*#__PURE__*/React.createElement("tr", _extends({
|
|
20
21
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/enforce-style-prop -- Ignored via go/DSP-18766
|
|
21
|
-
style: style
|
|
22
|
+
style: style,
|
|
23
|
+
/**
|
|
24
|
+
* We rely on this `className` for the `RankableTableBodyRow` to apply extra styles.
|
|
25
|
+
* With Compiled it needs to be statically analyzable. It does not get applied via spread props.
|
|
26
|
+
*/
|
|
27
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
|
|
28
|
+
className: ax(["_bfhkqtfy _1ygbi9un _1ah312gs", isHighlighted ? "_bfhktkjs _irr31ae3" : "_irr3s8ts", className])
|
|
22
29
|
}, rest, {
|
|
23
30
|
ref: ref,
|
|
24
|
-
"data-testid": testId
|
|
25
|
-
className: ax(["_bfhkqtfy _1ygbi9un _1ah312gs", isHighlighted ? "_bfhktkjs _irr31ae3" : "_irr3s8ts"])
|
|
31
|
+
"data-testid": testId
|
|
26
32
|
}), children);
|
|
27
33
|
});
|
|
@@ -77,14 +77,14 @@ var DynamicTable = function DynamicTable(_ref) {
|
|
|
77
77
|
action: 'sorted',
|
|
78
78
|
componentName: 'dynamicTable',
|
|
79
79
|
packageName: "@atlaskit/dynamic-table",
|
|
80
|
-
packageVersion: "18.0.
|
|
80
|
+
packageVersion: "18.0.4"
|
|
81
81
|
});
|
|
82
82
|
var onRankEnd = usePlatformLeafEventHandler({
|
|
83
83
|
fn: providedOnRankEnd,
|
|
84
84
|
action: 'ranked',
|
|
85
85
|
componentName: 'dynamicTable',
|
|
86
86
|
packageName: "@atlaskit/dynamic-table",
|
|
87
|
-
packageVersion: "18.0.
|
|
87
|
+
packageVersion: "18.0.4"
|
|
88
88
|
});
|
|
89
89
|
useEffect(function () {
|
|
90
90
|
validateSortKey(sortKey, head);
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
4
4
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
5
|
-
var _excluded = ["isHighlighted", "children", "style", "testId"];
|
|
5
|
+
var _excluded = ["isHighlighted", "children", "style", "testId", "className"];
|
|
6
6
|
import "./table-row.compiled.css";
|
|
7
7
|
import * as React from 'react';
|
|
8
8
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -19,11 +19,18 @@ export var TableBodyRow = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
19
19
|
children = _ref.children,
|
|
20
20
|
style = _ref.style,
|
|
21
21
|
testId = _ref.testId,
|
|
22
|
+
className = _ref.className,
|
|
22
23
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
23
|
-
return /*#__PURE__*/React.createElement("tr", _extends({
|
|
24
|
+
return /*#__PURE__*/React.createElement("tr", _extends({
|
|
25
|
+
/**
|
|
26
|
+
* We rely on this `className` for the `RankableTableBodyRow` to apply extra styles.
|
|
27
|
+
* With Compiled it needs to be statically analyzable. It does not get applied via spread props.
|
|
28
|
+
*/
|
|
29
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
|
|
30
|
+
className: ax(["_bfhkqtfy _1ygb1852 _1ah312gs", isHighlighted ? "_bfhktkjs _irr31ae3" : "_irr3s8ts", className])
|
|
31
|
+
}, rest, {
|
|
24
32
|
ref: ref,
|
|
25
33
|
"data-testid": testId,
|
|
26
|
-
className: ax(["_bfhkqtfy _1ygb1852 _1ah312gs", isHighlighted ? "_bfhktkjs _irr31ae3" : "_irr3s8ts"]),
|
|
27
34
|
style: _objectSpread(_objectSpread({}, style), {}, {
|
|
28
35
|
"--_akp1ox": ix("2px solid ".concat("var(--ds-border-focused, var(--local-dynamic-table-hover-bg))"))
|
|
29
36
|
})
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/dynamic-table",
|
|
3
|
-
"version": "18.0.
|
|
3
|
+
"version": "18.0.4",
|
|
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/"
|
|
@@ -46,13 +46,13 @@
|
|
|
46
46
|
"@atlaskit/pagination": "^16.0.0",
|
|
47
47
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
48
48
|
"@atlaskit/pragmatic-drag-and-drop-react-beautiful-dnd-migration": "^2.0.0",
|
|
49
|
-
"@atlaskit/primitives": "^14.
|
|
49
|
+
"@atlaskit/primitives": "^14.2.0",
|
|
50
50
|
"@atlaskit/spinner": "^18.0.0",
|
|
51
51
|
"@atlaskit/theme": "^18.0.0",
|
|
52
|
-
"@atlaskit/tokens": "^4.
|
|
52
|
+
"@atlaskit/tokens": "^4.5.0",
|
|
53
53
|
"@atlaskit/tooltip": "^20.0.0",
|
|
54
54
|
"@babel/runtime": "^7.0.0",
|
|
55
|
-
"@compiled/react": "^0.18.
|
|
55
|
+
"@compiled/react": "^0.18.3",
|
|
56
56
|
"@emotion/react": "^11.7.1"
|
|
57
57
|
},
|
|
58
58
|
"peerDependencies": {
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
"@atlaskit/link": "^3.0.0",
|
|
73
73
|
"@atlaskit/pragmatic-drag-and-drop": "^1.5.0",
|
|
74
74
|
"@atlaskit/pragmatic-drag-and-drop-hitbox": "^1.0.0",
|
|
75
|
-
"@atlaskit/section-message": "^8.
|
|
75
|
+
"@atlaskit/section-message": "^8.2.0",
|
|
76
76
|
"@atlaskit/ssr": "^0.4.0",
|
|
77
77
|
"@atlaskit/toggle": "^15.0.0",
|
|
78
78
|
"@atlassian/feature-flags-storybook-utils": "^0.3.0",
|
|
@@ -81,6 +81,7 @@
|
|
|
81
81
|
"@testing-library/react": "^13.4.0",
|
|
82
82
|
"@testing-library/user-event": "^14.4.3",
|
|
83
83
|
"react-dom": "^18.2.0",
|
|
84
|
+
"tiny-invariant": "^1.2.0",
|
|
84
85
|
"typescript": "~5.4.2"
|
|
85
86
|
},
|
|
86
87
|
"techstack": {
|