@atlaskit/table-tree 9.1.9 → 9.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/cjs/components/header.js +3 -3
- package/dist/cjs/components/headers.js +3 -3
- package/dist/cjs/components/internal/common-cell.js +3 -3
- package/dist/cjs/components/internal/item.js +3 -3
- package/dist/cjs/components/internal/overflow-container.js +3 -3
- package/dist/cjs/components/internal/styled.js +10 -10
- package/dist/cjs/components/row.js +1 -1
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/components/header.js +1 -1
- package/dist/es2019/components/headers.js +1 -1
- package/dist/es2019/components/internal/common-cell.js +1 -1
- package/dist/es2019/components/internal/item.js +1 -1
- package/dist/es2019/components/internal/overflow-container.js +1 -1
- package/dist/es2019/components/internal/styled.js +1 -1
- package/dist/es2019/components/row.js +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/components/header.js +1 -1
- package/dist/esm/components/headers.js +1 -1
- package/dist/esm/components/internal/common-cell.js +1 -1
- package/dist/esm/components/internal/item.js +1 -1
- package/dist/esm/components/internal/overflow-container.js +1 -1
- package/dist/esm/components/internal/styled.js +1 -1
- package/dist/esm/components/row.js +1 -1
- package/dist/esm/version.json +1 -1
- package/dist/types/components/headers.d.ts +2 -1
- package/dist/types/components/internal/item.d.ts +2 -1
- package/package.json +8 -6
- package/report.api.md +369 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @atlaskit/table-tree
|
|
2
2
|
|
|
3
|
+
## 9.1.10
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`70c2c0e00ea`](https://bitbucket.org/atlassian/atlassian-frontend/commits/70c2c0e00ea) - Updates `@emotion/core` v10 to `@emotion/react` v11. No expected behaviour change.
|
|
8
|
+
|
|
3
9
|
## 9.1.9
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
|
@@ -21,7 +21,7 @@ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/ge
|
|
|
21
21
|
|
|
22
22
|
var _react = require("react");
|
|
23
23
|
|
|
24
|
-
var
|
|
24
|
+
var _react2 = require("@emotion/react");
|
|
25
25
|
|
|
26
26
|
var _colors = require("@atlaskit/theme/colors");
|
|
27
27
|
|
|
@@ -33,7 +33,7 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
|
|
|
33
33
|
|
|
34
34
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
35
35
|
|
|
36
|
-
var headerStyles = (0,
|
|
36
|
+
var headerStyles = (0, _react2.css)({
|
|
37
37
|
color: "var(--ds-text-subtle, ".concat(_colors.N300, ")"),
|
|
38
38
|
fontSize: 12,
|
|
39
39
|
fontWeight: 'bold',
|
|
@@ -55,7 +55,7 @@ var Header = /*#__PURE__*/function (_Component) {
|
|
|
55
55
|
key: "render",
|
|
56
56
|
value: function render() {
|
|
57
57
|
var props = this.props;
|
|
58
|
-
return (0,
|
|
58
|
+
return (0, _react2.jsx)(_commonCell.default, (0, _extends2.default)({
|
|
59
59
|
css: headerStyles,
|
|
60
60
|
role: "columnheader",
|
|
61
61
|
style: {
|
|
@@ -19,13 +19,13 @@ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/ge
|
|
|
19
19
|
|
|
20
20
|
var _react = require("react");
|
|
21
21
|
|
|
22
|
-
var
|
|
22
|
+
var _react2 = require("@emotion/react");
|
|
23
23
|
|
|
24
24
|
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); }; }
|
|
25
25
|
|
|
26
26
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
27
27
|
|
|
28
|
-
var containerStyles = (0,
|
|
28
|
+
var containerStyles = (0, _react2.css)({
|
|
29
29
|
display: 'flex',
|
|
30
30
|
borderBottom: "solid 2px ".concat("var(--ds-border, #dfe1e6)")
|
|
31
31
|
});
|
|
@@ -43,7 +43,7 @@ var Headers = /*#__PURE__*/function (_Component) {
|
|
|
43
43
|
(0, _createClass2.default)(Headers, [{
|
|
44
44
|
key: "render",
|
|
45
45
|
value: function render() {
|
|
46
|
-
return (0,
|
|
46
|
+
return (0, _react2.jsx)("div", {
|
|
47
47
|
css: containerStyles,
|
|
48
48
|
role: "row"
|
|
49
49
|
}, _react.Children.map(this.props.children, function (header, index) {
|
|
@@ -11,12 +11,12 @@ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends")
|
|
|
11
11
|
|
|
12
12
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _react = require("@emotion/react");
|
|
15
15
|
|
|
16
16
|
var _colors = require("@atlaskit/theme/colors");
|
|
17
17
|
|
|
18
18
|
var _excluded = ["indent", "width"];
|
|
19
|
-
var commonStyles = (0,
|
|
19
|
+
var commonStyles = (0, _react.css)({
|
|
20
20
|
display: 'flex',
|
|
21
21
|
boxSizing: 'border-box',
|
|
22
22
|
minHeight: 40,
|
|
@@ -34,7 +34,7 @@ var CommonCell = function CommonCell(_ref) {
|
|
|
34
34
|
var indent = _ref.indent,
|
|
35
35
|
width = _ref.width,
|
|
36
36
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
37
|
-
return (0,
|
|
37
|
+
return (0, _react.jsx)("div", (0, _extends2.default)({}, props, {
|
|
38
38
|
style: {
|
|
39
39
|
'--indent': indent,
|
|
40
40
|
width: width
|
|
@@ -21,7 +21,7 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
|
|
|
21
21
|
|
|
22
22
|
var _react = require("react");
|
|
23
23
|
|
|
24
|
-
var
|
|
24
|
+
var _react2 = require("@emotion/react");
|
|
25
25
|
|
|
26
26
|
var _toItemId = _interopRequireDefault(require("../../utils/to-item-id"));
|
|
27
27
|
|
|
@@ -62,9 +62,9 @@ var Item = /*#__PURE__*/function (_Component) {
|
|
|
62
62
|
depth: depth,
|
|
63
63
|
data: data,
|
|
64
64
|
renderChildren: function renderChildren() {
|
|
65
|
-
return (0,
|
|
65
|
+
return (0, _react2.jsx)("div", {
|
|
66
66
|
id: (0, _toItemId.default)(itemId)
|
|
67
|
-
}, (0,
|
|
67
|
+
}, (0, _react2.jsx)(_items.default, {
|
|
68
68
|
parentData: data,
|
|
69
69
|
depth: depth,
|
|
70
70
|
items: items,
|
|
@@ -11,10 +11,10 @@ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends")
|
|
|
11
11
|
|
|
12
12
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _react = require("@emotion/react");
|
|
15
15
|
|
|
16
16
|
var _excluded = ["isSingleLine"];
|
|
17
|
-
var overflowContainerStyles = (0,
|
|
17
|
+
var overflowContainerStyles = (0, _react.css)({
|
|
18
18
|
overflow: 'hidden',
|
|
19
19
|
textOverflow: 'ellipsis',
|
|
20
20
|
whiteSpace: 'nowrap'
|
|
@@ -27,7 +27,7 @@ var OverflowContainer = function OverflowContainer(_ref) {
|
|
|
27
27
|
var isSingleLine = _ref.isSingleLine,
|
|
28
28
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
29
29
|
return (// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
30
|
-
(0,
|
|
30
|
+
(0, _react.jsx)("span", (0, _extends2.default)({
|
|
31
31
|
css: isSingleLine && overflowContainerStyles
|
|
32
32
|
}, props))
|
|
33
33
|
);
|
|
@@ -11,14 +11,14 @@ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/h
|
|
|
11
11
|
|
|
12
12
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
13
13
|
|
|
14
|
-
var
|
|
14
|
+
var _react = require("@emotion/react");
|
|
15
15
|
|
|
16
16
|
var _colors = require("@atlaskit/theme/colors");
|
|
17
17
|
|
|
18
18
|
var _excluded = ["isRoot"];
|
|
19
19
|
var iconColor = "var(--ds-text, ".concat(_colors.N800, ")");
|
|
20
20
|
exports.iconColor = iconColor;
|
|
21
|
-
var treeRowContainerStyles = (0,
|
|
21
|
+
var treeRowContainerStyles = (0, _react.css)({
|
|
22
22
|
display: 'flex',
|
|
23
23
|
borderBottom: "1px solid ".concat("var(--ds-border, ".concat(_colors.N30, ")"))
|
|
24
24
|
});
|
|
@@ -28,14 +28,14 @@ var treeRowContainerStyles = (0, _core.css)({
|
|
|
28
28
|
|
|
29
29
|
var TreeRowContainer = function TreeRowContainer(props) {
|
|
30
30
|
return (// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
31
|
-
(0,
|
|
31
|
+
(0, _react.jsx)("div", (0, _extends2.default)({
|
|
32
32
|
css: treeRowContainerStyles
|
|
33
33
|
}, props))
|
|
34
34
|
);
|
|
35
35
|
};
|
|
36
36
|
|
|
37
37
|
exports.TreeRowContainer = TreeRowContainer;
|
|
38
|
-
var commonChevronContainerStyles = (0,
|
|
38
|
+
var commonChevronContainerStyles = (0, _react.css)({
|
|
39
39
|
display: 'flex',
|
|
40
40
|
marginLeft: -25,
|
|
41
41
|
position: 'absolute',
|
|
@@ -48,13 +48,13 @@ var commonChevronContainerStyles = (0, _core.css)({
|
|
|
48
48
|
|
|
49
49
|
var ChevronContainer = function ChevronContainer(props // eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
50
50
|
) {
|
|
51
|
-
return (0,
|
|
51
|
+
return (0, _react.jsx)("span", (0, _extends2.default)({}, props, {
|
|
52
52
|
css: commonChevronContainerStyles
|
|
53
53
|
}));
|
|
54
54
|
};
|
|
55
55
|
|
|
56
56
|
exports.ChevronContainer = ChevronContainer;
|
|
57
|
-
var chevronIconContainerStyles = (0,
|
|
57
|
+
var chevronIconContainerStyles = (0, _react.css)({
|
|
58
58
|
position: 'relative',
|
|
59
59
|
top: 1
|
|
60
60
|
});
|
|
@@ -66,17 +66,17 @@ var chevronIconContainerStyles = (0, _core.css)({
|
|
|
66
66
|
|
|
67
67
|
var ChevronIconContainer = function ChevronIconContainer(props // eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
68
68
|
) {
|
|
69
|
-
return (0,
|
|
69
|
+
return (0, _react.jsx)("span", (0, _extends2.default)({}, props, {
|
|
70
70
|
css: chevronIconContainerStyles
|
|
71
71
|
}));
|
|
72
72
|
};
|
|
73
73
|
|
|
74
74
|
exports.ChevronIconContainer = ChevronIconContainer;
|
|
75
|
-
var loadingItemContainerStyles = (0,
|
|
75
|
+
var loadingItemContainerStyles = (0, _react.css)({
|
|
76
76
|
width: '100%',
|
|
77
77
|
paddingTop: 5
|
|
78
78
|
});
|
|
79
|
-
var paddingLeftStyles = (0,
|
|
79
|
+
var paddingLeftStyles = (0, _react.css)({
|
|
80
80
|
paddingLeft: '50%'
|
|
81
81
|
});
|
|
82
82
|
/**
|
|
@@ -88,7 +88,7 @@ var paddingLeftStyles = (0, _core.css)({
|
|
|
88
88
|
var LoaderItemContainer = function LoaderItemContainer(_ref) {
|
|
89
89
|
var isRoot = _ref.isRoot,
|
|
90
90
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
91
|
-
return (0,
|
|
91
|
+
return (0, _react.jsx)("span", (0, _extends2.default)({
|
|
92
92
|
css: [commonChevronContainerStyles, loadingItemContainerStyles, isRoot && paddingLeftStyles] // eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
93
93
|
|
|
94
94
|
}, props));
|
|
@@ -44,7 +44,7 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
|
|
|
44
44
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
45
45
|
|
|
46
46
|
var packageName = "@atlaskit/table-tree";
|
|
47
|
-
var packageVersion = "9.1.
|
|
47
|
+
var packageVersion = "9.1.10";
|
|
48
48
|
|
|
49
49
|
var Row = /*#__PURE__*/function (_Component) {
|
|
50
50
|
(0, _inherits2.default)(Row, _Component);
|
package/dist/cjs/version.json
CHANGED
|
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
import { Component } from 'react';
|
|
5
|
-
import { css, jsx } from '@emotion/
|
|
5
|
+
import { css, jsx } from '@emotion/react';
|
|
6
6
|
import { N300 } from '@atlaskit/theme/colors';
|
|
7
7
|
import ColumnCell from './internal/common-cell';
|
|
8
8
|
import withColumnWidth from './internal/with-column-width';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
/* eslint-disable @repo/internal/react/no-clone-element */
|
|
4
4
|
import { Children, cloneElement, Component } from 'react';
|
|
5
|
-
import { css, jsx } from '@emotion/
|
|
5
|
+
import { css, jsx } from '@emotion/react';
|
|
6
6
|
const containerStyles = css({
|
|
7
7
|
display: 'flex',
|
|
8
8
|
borderBottom: `solid 2px ${"var(--ds-border, #dfe1e6)"}`
|
|
@@ -4,7 +4,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
4
4
|
|
|
5
5
|
/* eslint-disable @repo/internal/react/no-clone-element */
|
|
6
6
|
import { cloneElement, Component } from 'react';
|
|
7
|
-
import { jsx } from '@emotion/
|
|
7
|
+
import { jsx } from '@emotion/react';
|
|
8
8
|
import toItemId from '../../utils/to-item-id';
|
|
9
9
|
import Items from './items';
|
|
10
10
|
export default class Item extends Component {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
|
|
3
3
|
/** @jsx jsx */
|
|
4
|
-
import { css, jsx } from '@emotion/
|
|
4
|
+
import { css, jsx } from '@emotion/react';
|
|
5
5
|
import { N30, N800 } from '@atlaskit/theme/colors';
|
|
6
6
|
export const iconColor = `var(--ds-text, ${N800})`;
|
|
7
7
|
const treeRowContainerStyles = css({
|
|
@@ -8,7 +8,7 @@ import toItemId from '../utils/to-item-id';
|
|
|
8
8
|
import Chevron from './internal/chevron';
|
|
9
9
|
import { TreeRowContainer } from './internal/styled';
|
|
10
10
|
const packageName = "@atlaskit/table-tree";
|
|
11
|
-
const packageVersion = "9.1.
|
|
11
|
+
const packageVersion = "9.1.10";
|
|
12
12
|
|
|
13
13
|
class Row extends Component {
|
|
14
14
|
constructor(...args) {
|
package/dist/es2019/version.json
CHANGED
|
@@ -11,7 +11,7 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
11
11
|
|
|
12
12
|
/** @jsx jsx */
|
|
13
13
|
import { Component } from 'react';
|
|
14
|
-
import { css, jsx } from '@emotion/
|
|
14
|
+
import { css, jsx } from '@emotion/react';
|
|
15
15
|
import { N300 } from '@atlaskit/theme/colors';
|
|
16
16
|
import ColumnCell from './internal/common-cell';
|
|
17
17
|
import withColumnWidth from './internal/with-column-width';
|
|
@@ -12,7 +12,7 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
12
12
|
|
|
13
13
|
/* eslint-disable @repo/internal/react/no-clone-element */
|
|
14
14
|
import { Children, cloneElement, Component } from 'react';
|
|
15
|
-
import { css, jsx } from '@emotion/
|
|
15
|
+
import { css, jsx } from '@emotion/react';
|
|
16
16
|
var containerStyles = css({
|
|
17
17
|
display: 'flex',
|
|
18
18
|
borderBottom: "solid 2px ".concat("var(--ds-border, #dfe1e6)")
|
|
@@ -3,7 +3,7 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
|
3
3
|
var _excluded = ["indent", "width"];
|
|
4
4
|
|
|
5
5
|
/** @jsx jsx */
|
|
6
|
-
import { css, jsx } from '@emotion/
|
|
6
|
+
import { css, jsx } from '@emotion/react';
|
|
7
7
|
import { N800 } from '@atlaskit/theme/colors';
|
|
8
8
|
var commonStyles = css({
|
|
9
9
|
display: 'flex',
|
|
@@ -13,7 +13,7 @@ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Re
|
|
|
13
13
|
|
|
14
14
|
/* eslint-disable @repo/internal/react/no-clone-element */
|
|
15
15
|
import { cloneElement, Component } from 'react';
|
|
16
|
-
import { jsx } from '@emotion/
|
|
16
|
+
import { jsx } from '@emotion/react';
|
|
17
17
|
import toItemId from '../../utils/to-item-id';
|
|
18
18
|
import Items from './items';
|
|
19
19
|
|
|
@@ -3,7 +3,7 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
|
3
3
|
var _excluded = ["isSingleLine"];
|
|
4
4
|
|
|
5
5
|
/** @jsx jsx */
|
|
6
|
-
import { css, jsx } from '@emotion/
|
|
6
|
+
import { css, jsx } from '@emotion/react';
|
|
7
7
|
var overflowContainerStyles = css({
|
|
8
8
|
overflow: 'hidden',
|
|
9
9
|
textOverflow: 'ellipsis',
|
|
@@ -3,7 +3,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
3
3
|
var _excluded = ["isRoot"];
|
|
4
4
|
|
|
5
5
|
/** @jsx jsx */
|
|
6
|
-
import { css, jsx } from '@emotion/
|
|
6
|
+
import { css, jsx } from '@emotion/react';
|
|
7
7
|
import { N30, N800 } from '@atlaskit/theme/colors';
|
|
8
8
|
export var iconColor = "var(--ds-text, ".concat(N800, ")");
|
|
9
9
|
var treeRowContainerStyles = css({
|
|
@@ -18,7 +18,7 @@ import toItemId from '../utils/to-item-id';
|
|
|
18
18
|
import Chevron from './internal/chevron';
|
|
19
19
|
import { TreeRowContainer } from './internal/styled';
|
|
20
20
|
var packageName = "@atlaskit/table-tree";
|
|
21
|
-
var packageVersion = "9.1.
|
|
21
|
+
var packageVersion = "9.1.10";
|
|
22
22
|
|
|
23
23
|
var Row = /*#__PURE__*/function (_Component) {
|
|
24
24
|
_inherits(Row, _Component);
|
package/dist/esm/version.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/** @jsx jsx */
|
|
2
2
|
import { Component } from 'react';
|
|
3
|
+
import { jsx } from '@emotion/react';
|
|
3
4
|
export default class Item extends Component<any> {
|
|
4
5
|
static defaultProps: {
|
|
5
6
|
depth: number;
|
|
@@ -7,6 +8,6 @@ export default class Item extends Component<any> {
|
|
|
7
8
|
render(): import("react").FunctionComponentElement<{
|
|
8
9
|
depth: any;
|
|
9
10
|
data: any;
|
|
10
|
-
renderChildren: () => JSX.Element;
|
|
11
|
+
renderChildren: () => jsx.JSX.Element;
|
|
11
12
|
}> | null;
|
|
12
13
|
}
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/table-tree",
|
|
3
|
-
"version": "9.1.
|
|
3
|
+
"version": "9.1.10",
|
|
4
4
|
"description": "A table tree is an expandable table for showing nested hierarchies of information.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
7
7
|
},
|
|
8
|
-
"repository": "https://bitbucket.org/atlassian/atlassian-frontend",
|
|
8
|
+
"repository": "https://bitbucket.org/atlassian/atlassian-frontend-mirror",
|
|
9
9
|
"author": "Atlassian Pty Ltd",
|
|
10
10
|
"license": "Apache-2.0",
|
|
11
11
|
"main": "dist/cjs/index.js",
|
|
@@ -19,7 +19,8 @@
|
|
|
19
19
|
"team": "Design System Team",
|
|
20
20
|
"releaseModel": "scheduled",
|
|
21
21
|
"website": {
|
|
22
|
-
"name": "Table tree"
|
|
22
|
+
"name": "Table tree",
|
|
23
|
+
"category": "Components"
|
|
23
24
|
}
|
|
24
25
|
},
|
|
25
26
|
"af:exports": {
|
|
@@ -33,7 +34,7 @@
|
|
|
33
34
|
"@atlaskit/theme": "^12.1.0",
|
|
34
35
|
"@atlaskit/tokens": "^0.10.0",
|
|
35
36
|
"@babel/runtime": "^7.0.0",
|
|
36
|
-
"@emotion/
|
|
37
|
+
"@emotion/react": "^11.7.1",
|
|
37
38
|
"lodash": "^4.17.21",
|
|
38
39
|
"prop-types": "^15.5.10"
|
|
39
40
|
},
|
|
@@ -44,11 +45,11 @@
|
|
|
44
45
|
"@atlaskit/docs": "*",
|
|
45
46
|
"@atlaskit/empty-state": "^7.3.0",
|
|
46
47
|
"@atlaskit/section-message": "^6.0.0",
|
|
47
|
-
"@atlaskit/select": "^15.
|
|
48
|
+
"@atlaskit/select": "^15.6.0",
|
|
48
49
|
"@atlaskit/ssr": "*",
|
|
49
50
|
"@atlaskit/visual-regression": "*",
|
|
50
51
|
"@atlassian/atlassian-frontend-prettier-config-1.0.1": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.1",
|
|
51
|
-
"@emotion/styled": "^
|
|
52
|
+
"@emotion/styled": "^11.0.0",
|
|
52
53
|
"enzyme": "^3.10.0",
|
|
53
54
|
"exenv": "^1.2.2",
|
|
54
55
|
"react-dom": "^16.8.0",
|
|
@@ -68,6 +69,7 @@
|
|
|
68
69
|
"circular-dependencies": "file-and-folder-level"
|
|
69
70
|
},
|
|
70
71
|
"@repo/internal": {
|
|
72
|
+
"dom-events": "use-bind-event-listener",
|
|
71
73
|
"design-system": "v1",
|
|
72
74
|
"styling": [
|
|
73
75
|
"static",
|
package/report.api.md
ADDED
|
@@ -0,0 +1,369 @@
|
|
|
1
|
+
## API Report File for "@atlaskit/table-tree"
|
|
2
|
+
|
|
3
|
+
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
|
|
4
|
+
|
|
5
|
+
```ts
|
|
6
|
+
/// <reference types="react" />
|
|
7
|
+
|
|
8
|
+
import { Component } from 'react';
|
|
9
|
+
import { Context } from 'react';
|
|
10
|
+
import { ErrorInfo } from 'react';
|
|
11
|
+
import PropTypes from 'prop-types';
|
|
12
|
+
import { default as React_2 } from 'react';
|
|
13
|
+
import { ReactInstance } from 'react';
|
|
14
|
+
import { ReactNode } from 'react';
|
|
15
|
+
import { Validator } from 'prop-types';
|
|
16
|
+
import { WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
|
|
17
|
+
import { WithContextProps } from '@atlaskit/analytics-next';
|
|
18
|
+
|
|
19
|
+
export declare const Cell: {
|
|
20
|
+
new (props: Readonly<CellProps & CellWithColumnWidthProps>): {
|
|
21
|
+
UNSAFE_componentWillMount(): void;
|
|
22
|
+
setColumnWidth(width?: string | number | undefined): void;
|
|
23
|
+
UNSAFE_componentWillReceiveProps(nextProps: CellWithColumnWidthProps): void;
|
|
24
|
+
render(): JSX.Element;
|
|
25
|
+
context: any;
|
|
26
|
+
setState<K extends never>(
|
|
27
|
+
state:
|
|
28
|
+
| {}
|
|
29
|
+
| ((
|
|
30
|
+
prevState: Readonly<{}>,
|
|
31
|
+
props: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
32
|
+
) => {} | Pick<{}, K> | null)
|
|
33
|
+
| Pick<{}, K>
|
|
34
|
+
| null,
|
|
35
|
+
callback?: (() => void) | undefined,
|
|
36
|
+
): void;
|
|
37
|
+
forceUpdate(callBack?: (() => void) | undefined): void;
|
|
38
|
+
readonly props: Readonly<CellProps & CellWithColumnWidthProps> &
|
|
39
|
+
Readonly<{
|
|
40
|
+
children?: React_2.ReactNode;
|
|
41
|
+
}>;
|
|
42
|
+
state: Readonly<{}>;
|
|
43
|
+
refs: {
|
|
44
|
+
[key: string]: React_2.ReactInstance;
|
|
45
|
+
};
|
|
46
|
+
componentDidMount?(): void;
|
|
47
|
+
shouldComponentUpdate?(
|
|
48
|
+
nextProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
49
|
+
nextState: Readonly<{}>,
|
|
50
|
+
nextContext: any,
|
|
51
|
+
): boolean;
|
|
52
|
+
componentWillUnmount?(): void;
|
|
53
|
+
componentDidCatch?(error: Error, errorInfo: React_2.ErrorInfo): void;
|
|
54
|
+
getSnapshotBeforeUpdate?(
|
|
55
|
+
prevProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
56
|
+
prevState: Readonly<{}>,
|
|
57
|
+
): any;
|
|
58
|
+
componentDidUpdate?(
|
|
59
|
+
prevProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
60
|
+
prevState: Readonly<{}>,
|
|
61
|
+
snapshot?: any,
|
|
62
|
+
): void;
|
|
63
|
+
componentWillMount?(): void;
|
|
64
|
+
componentWillReceiveProps?(
|
|
65
|
+
nextProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
66
|
+
nextContext: any,
|
|
67
|
+
): void;
|
|
68
|
+
componentWillUpdate?(
|
|
69
|
+
nextProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
70
|
+
nextState: Readonly<{}>,
|
|
71
|
+
nextContext: any,
|
|
72
|
+
): void;
|
|
73
|
+
UNSAFE_componentWillUpdate?(
|
|
74
|
+
nextProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
75
|
+
nextState: Readonly<{}>,
|
|
76
|
+
nextContext: any,
|
|
77
|
+
): void;
|
|
78
|
+
};
|
|
79
|
+
new (props: CellProps & CellWithColumnWidthProps, context?: any): {
|
|
80
|
+
UNSAFE_componentWillMount(): void;
|
|
81
|
+
setColumnWidth(width?: string | number | undefined): void;
|
|
82
|
+
UNSAFE_componentWillReceiveProps(nextProps: CellWithColumnWidthProps): void;
|
|
83
|
+
render(): JSX.Element;
|
|
84
|
+
context: any;
|
|
85
|
+
setState<K extends never>(
|
|
86
|
+
state:
|
|
87
|
+
| {}
|
|
88
|
+
| ((
|
|
89
|
+
prevState: Readonly<{}>,
|
|
90
|
+
props: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
91
|
+
) => {} | Pick<{}, K> | null)
|
|
92
|
+
| Pick<{}, K>
|
|
93
|
+
| null,
|
|
94
|
+
callback?: (() => void) | undefined,
|
|
95
|
+
): void;
|
|
96
|
+
forceUpdate(callBack?: (() => void) | undefined): void;
|
|
97
|
+
readonly props: Readonly<CellProps & CellWithColumnWidthProps> &
|
|
98
|
+
Readonly<{
|
|
99
|
+
children?: React_2.ReactNode;
|
|
100
|
+
}>;
|
|
101
|
+
state: Readonly<{}>;
|
|
102
|
+
refs: {
|
|
103
|
+
[key: string]: React_2.ReactInstance;
|
|
104
|
+
};
|
|
105
|
+
componentDidMount?(): void;
|
|
106
|
+
shouldComponentUpdate?(
|
|
107
|
+
nextProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
108
|
+
nextState: Readonly<{}>,
|
|
109
|
+
nextContext: any,
|
|
110
|
+
): boolean;
|
|
111
|
+
componentWillUnmount?(): void;
|
|
112
|
+
componentDidCatch?(error: Error, errorInfo: React_2.ErrorInfo): void;
|
|
113
|
+
getSnapshotBeforeUpdate?(
|
|
114
|
+
prevProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
115
|
+
prevState: Readonly<{}>,
|
|
116
|
+
): any;
|
|
117
|
+
componentDidUpdate?(
|
|
118
|
+
prevProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
119
|
+
prevState: Readonly<{}>,
|
|
120
|
+
snapshot?: any,
|
|
121
|
+
): void;
|
|
122
|
+
componentWillMount?(): void;
|
|
123
|
+
componentWillReceiveProps?(
|
|
124
|
+
nextProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
125
|
+
nextContext: any,
|
|
126
|
+
): void;
|
|
127
|
+
componentWillUpdate?(
|
|
128
|
+
nextProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
129
|
+
nextState: Readonly<{}>,
|
|
130
|
+
nextContext: any,
|
|
131
|
+
): void;
|
|
132
|
+
UNSAFE_componentWillUpdate?(
|
|
133
|
+
nextProps: Readonly<CellProps & CellWithColumnWidthProps>,
|
|
134
|
+
nextState: Readonly<{}>,
|
|
135
|
+
nextContext: any,
|
|
136
|
+
): void;
|
|
137
|
+
};
|
|
138
|
+
contextTypes: {
|
|
139
|
+
tableTree: Validator<object>;
|
|
140
|
+
};
|
|
141
|
+
contextType?: React_2.Context<any> | undefined;
|
|
142
|
+
};
|
|
143
|
+
|
|
144
|
+
export declare interface CellProps {
|
|
145
|
+
/**
|
|
146
|
+
* Whether the cell contents should wrap or display on a single line and be concatenated.
|
|
147
|
+
*/
|
|
148
|
+
singleLine?: boolean;
|
|
149
|
+
/**
|
|
150
|
+
* Indent level for the cell. Each indent level adds 25px to the left padding.
|
|
151
|
+
*/
|
|
152
|
+
indentLevel?: number;
|
|
153
|
+
/**
|
|
154
|
+
* Width of the header item. Takes a string or a number representing the width in pixels.
|
|
155
|
+
*/
|
|
156
|
+
width?: number | string;
|
|
157
|
+
/**
|
|
158
|
+
* Class name to apply to cell.
|
|
159
|
+
*/
|
|
160
|
+
className?: string;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
export declare interface CellWithColumnWidthProps {
|
|
164
|
+
width?: number | string;
|
|
165
|
+
columnIndex?: number;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
export declare const Header: {
|
|
169
|
+
new (props: Readonly<any>): {
|
|
170
|
+
UNSAFE_componentWillMount(): void;
|
|
171
|
+
setColumnWidth(width?: string | number | undefined): void;
|
|
172
|
+
UNSAFE_componentWillReceiveProps(nextProps: CellWithColumnWidthProps): void;
|
|
173
|
+
render(): JSX.Element;
|
|
174
|
+
context: any;
|
|
175
|
+
setState<K extends never>(
|
|
176
|
+
state:
|
|
177
|
+
| {}
|
|
178
|
+
| ((
|
|
179
|
+
prevState: Readonly<{}>,
|
|
180
|
+
props: Readonly<any>,
|
|
181
|
+
) => {} | Pick<{}, K> | null)
|
|
182
|
+
| Pick<{}, K>
|
|
183
|
+
| null,
|
|
184
|
+
callback?: (() => void) | undefined,
|
|
185
|
+
): void;
|
|
186
|
+
forceUpdate(callBack?: (() => void) | undefined): void;
|
|
187
|
+
readonly props: Readonly<any> &
|
|
188
|
+
Readonly<{
|
|
189
|
+
children?: ReactNode;
|
|
190
|
+
}>;
|
|
191
|
+
state: Readonly<{}>;
|
|
192
|
+
refs: {
|
|
193
|
+
[key: string]: ReactInstance;
|
|
194
|
+
};
|
|
195
|
+
componentDidMount?(): void;
|
|
196
|
+
shouldComponentUpdate?(
|
|
197
|
+
nextProps: Readonly<any>,
|
|
198
|
+
nextState: Readonly<{}>,
|
|
199
|
+
nextContext: any,
|
|
200
|
+
): boolean;
|
|
201
|
+
componentWillUnmount?(): void;
|
|
202
|
+
componentDidCatch?(error: Error, errorInfo: ErrorInfo): void;
|
|
203
|
+
getSnapshotBeforeUpdate?(
|
|
204
|
+
prevProps: Readonly<any>,
|
|
205
|
+
prevState: Readonly<{}>,
|
|
206
|
+
): any;
|
|
207
|
+
componentDidUpdate?(
|
|
208
|
+
prevProps: Readonly<any>,
|
|
209
|
+
prevState: Readonly<{}>,
|
|
210
|
+
snapshot?: any,
|
|
211
|
+
): void;
|
|
212
|
+
componentWillMount?(): void;
|
|
213
|
+
componentWillReceiveProps?(
|
|
214
|
+
nextProps: Readonly<any>,
|
|
215
|
+
nextContext: any,
|
|
216
|
+
): void;
|
|
217
|
+
componentWillUpdate?(
|
|
218
|
+
nextProps: Readonly<any>,
|
|
219
|
+
nextState: Readonly<{}>,
|
|
220
|
+
nextContext: any,
|
|
221
|
+
): void;
|
|
222
|
+
UNSAFE_componentWillUpdate?(
|
|
223
|
+
nextProps: Readonly<any>,
|
|
224
|
+
nextState: Readonly<{}>,
|
|
225
|
+
nextContext: any,
|
|
226
|
+
): void;
|
|
227
|
+
};
|
|
228
|
+
new (props: any, context?: any): {
|
|
229
|
+
UNSAFE_componentWillMount(): void;
|
|
230
|
+
setColumnWidth(width?: string | number | undefined): void;
|
|
231
|
+
UNSAFE_componentWillReceiveProps(nextProps: CellWithColumnWidthProps): void;
|
|
232
|
+
render(): JSX.Element;
|
|
233
|
+
context: any;
|
|
234
|
+
setState<K extends never>(
|
|
235
|
+
state:
|
|
236
|
+
| {}
|
|
237
|
+
| ((
|
|
238
|
+
prevState: Readonly<{}>,
|
|
239
|
+
props: Readonly<any>,
|
|
240
|
+
) => {} | Pick<{}, K> | null)
|
|
241
|
+
| Pick<{}, K>
|
|
242
|
+
| null,
|
|
243
|
+
callback?: (() => void) | undefined,
|
|
244
|
+
): void;
|
|
245
|
+
forceUpdate(callBack?: (() => void) | undefined): void;
|
|
246
|
+
readonly props: Readonly<any> &
|
|
247
|
+
Readonly<{
|
|
248
|
+
children?: ReactNode;
|
|
249
|
+
}>;
|
|
250
|
+
state: Readonly<{}>;
|
|
251
|
+
refs: {
|
|
252
|
+
[key: string]: ReactInstance;
|
|
253
|
+
};
|
|
254
|
+
componentDidMount?(): void;
|
|
255
|
+
shouldComponentUpdate?(
|
|
256
|
+
nextProps: Readonly<any>,
|
|
257
|
+
nextState: Readonly<{}>,
|
|
258
|
+
nextContext: any,
|
|
259
|
+
): boolean;
|
|
260
|
+
componentWillUnmount?(): void;
|
|
261
|
+
componentDidCatch?(error: Error, errorInfo: ErrorInfo): void;
|
|
262
|
+
getSnapshotBeforeUpdate?(
|
|
263
|
+
prevProps: Readonly<any>,
|
|
264
|
+
prevState: Readonly<{}>,
|
|
265
|
+
): any;
|
|
266
|
+
componentDidUpdate?(
|
|
267
|
+
prevProps: Readonly<any>,
|
|
268
|
+
prevState: Readonly<{}>,
|
|
269
|
+
snapshot?: any,
|
|
270
|
+
): void;
|
|
271
|
+
componentWillMount?(): void;
|
|
272
|
+
componentWillReceiveProps?(
|
|
273
|
+
nextProps: Readonly<any>,
|
|
274
|
+
nextContext: any,
|
|
275
|
+
): void;
|
|
276
|
+
componentWillUpdate?(
|
|
277
|
+
nextProps: Readonly<any>,
|
|
278
|
+
nextState: Readonly<{}>,
|
|
279
|
+
nextContext: any,
|
|
280
|
+
): void;
|
|
281
|
+
UNSAFE_componentWillUpdate?(
|
|
282
|
+
nextProps: Readonly<any>,
|
|
283
|
+
nextState: Readonly<{}>,
|
|
284
|
+
nextContext: any,
|
|
285
|
+
): void;
|
|
286
|
+
};
|
|
287
|
+
contextTypes: {
|
|
288
|
+
tableTree: Validator<object>;
|
|
289
|
+
};
|
|
290
|
+
contextType?: Context<any> | undefined;
|
|
291
|
+
};
|
|
292
|
+
|
|
293
|
+
declare class Headers_2 extends Component<any> {
|
|
294
|
+
render(): JSX.Element;
|
|
295
|
+
}
|
|
296
|
+
export { Headers_2 as Headers };
|
|
297
|
+
|
|
298
|
+
export declare const Row: React_2.ForwardRefExoticComponent<
|
|
299
|
+
Pick<
|
|
300
|
+
Pick<Omit<any, keyof WithAnalyticsEventsProps>, string | number | symbol> &
|
|
301
|
+
React_2.RefAttributes<any> &
|
|
302
|
+
WithContextProps,
|
|
303
|
+
string | number | symbol
|
|
304
|
+
> &
|
|
305
|
+
React_2.RefAttributes<any>
|
|
306
|
+
>;
|
|
307
|
+
|
|
308
|
+
export declare class Rows<T> extends Component<RowsProps<T>> {
|
|
309
|
+
render(): JSX.Element;
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
export declare interface RowsProps<T> {
|
|
313
|
+
items?: WithChildren<T>[];
|
|
314
|
+
render: (args: WithChildren<T>) => React_2.ReactNode;
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
declare interface State {
|
|
318
|
+
columnWidths: number[];
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
declare class TableTree extends Component<any, State> {
|
|
322
|
+
static childContextTypes: {
|
|
323
|
+
tableTree: PropTypes.Validator<object>;
|
|
324
|
+
};
|
|
325
|
+
state: State;
|
|
326
|
+
componentDidMount(): void;
|
|
327
|
+
setColumnWidth: (columnIndex: number, width: number) => void;
|
|
328
|
+
getColumnWidth: (columnIndex: any) => number | null;
|
|
329
|
+
getChildContext(): {
|
|
330
|
+
tableTree: {
|
|
331
|
+
columnWidths: number[];
|
|
332
|
+
setColumnWidth: (columnIndex: number, width: number) => void;
|
|
333
|
+
getColumnWidth: (columnIndex: any) => number | null;
|
|
334
|
+
};
|
|
335
|
+
};
|
|
336
|
+
render(): JSX.Element;
|
|
337
|
+
}
|
|
338
|
+
export default TableTree;
|
|
339
|
+
|
|
340
|
+
/**
|
|
341
|
+
* This helper class will create a cache of all the id's in the items object and
|
|
342
|
+
* path to the object.
|
|
343
|
+
* Example:
|
|
344
|
+
* [{
|
|
345
|
+
* // item 1,
|
|
346
|
+
* id: 1,
|
|
347
|
+
* children:[{
|
|
348
|
+
* // item 1.1,
|
|
349
|
+
* id: '2'
|
|
350
|
+
* }]
|
|
351
|
+
* }]
|
|
352
|
+
*
|
|
353
|
+
* Cache will look something like:
|
|
354
|
+
* {1: 0, 2: '0.children[0]'}
|
|
355
|
+
*/
|
|
356
|
+
export declare class TableTreeDataHelper<T extends any = any> {
|
|
357
|
+
key: keyof T;
|
|
358
|
+
keysCache: any;
|
|
359
|
+
constructor({ key }?: { key?: keyof T | undefined });
|
|
360
|
+
updateItems(items: T[], allItems?: T[], parentItem?: T | null): T[];
|
|
361
|
+
appendItems(items: T[], allItems?: T[], parentItem?: T | null): T[];
|
|
362
|
+
}
|
|
363
|
+
|
|
364
|
+
declare type WithChildren<T> = T & {
|
|
365
|
+
children?: T[] | null;
|
|
366
|
+
};
|
|
367
|
+
|
|
368
|
+
export {};
|
|
369
|
+
```
|