@atlaskit/dynamic-table 14.4.2 → 14.4.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 +7 -0
- package/dist/cjs/components/Stateless.js +1 -1
- package/dist/cjs/styled/TableHead.js +5 -7
- package/dist/cjs/styled/TableRow.js +4 -6
- package/dist/cjs/styled/rankable/TableRow.js +3 -5
- package/dist/cjs/theme.js +18 -20
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/components/Stateless.js +1 -1
- package/dist/es2019/styled/TableHead.js +5 -6
- package/dist/es2019/styled/TableRow.js +4 -5
- package/dist/es2019/styled/rankable/TableRow.js +3 -4
- package/dist/es2019/theme.js +18 -19
- package/dist/es2019/version.json +1 -1
- package/dist/esm/components/Stateless.js +1 -1
- package/dist/esm/styled/TableHead.js +5 -6
- package/dist/esm/styled/TableRow.js +4 -5
- package/dist/esm/styled/rankable/TableRow.js +3 -4
- package/dist/esm/theme.js +18 -19
- package/dist/esm/version.json +1 -1
- package/package.json +9 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# @atlaskit/dynamic-table
|
|
2
2
|
|
|
3
|
+
## 14.4.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`f460cc7c411`](https://bitbucket.org/atlassian/atlassian-frontend/commits/f460cc7c411) - Builds for this package now pass through a tokens babel plugin, removing runtime invocations of the tokens() function and improving bundle size.
|
|
8
|
+
- Updated dependencies
|
|
9
|
+
|
|
3
10
|
## 14.4.2
|
|
4
11
|
|
|
5
12
|
### Patch Changes
|
|
@@ -52,7 +52,7 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
|
|
|
52
52
|
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; } }
|
|
53
53
|
|
|
54
54
|
var packageName = "@atlaskit/dynamic-table";
|
|
55
|
-
var packageVersion = "14.4.
|
|
55
|
+
var packageVersion = "14.4.3";
|
|
56
56
|
|
|
57
57
|
function toggleSortOrder(currentSortOrder) {
|
|
58
58
|
switch (currentSortOrder) {
|
|
@@ -23,8 +23,6 @@ var _components = require("@atlaskit/theme/components");
|
|
|
23
23
|
|
|
24
24
|
var _constants = require("@atlaskit/theme/constants");
|
|
25
25
|
|
|
26
|
-
var _tokens = require("@atlaskit/tokens");
|
|
27
|
-
|
|
28
26
|
var _constants2 = require("../internal/constants");
|
|
29
27
|
|
|
30
28
|
var _theme = require("../theme");
|
|
@@ -43,9 +41,9 @@ var rankingStyles = (0, _core.css)({
|
|
|
43
41
|
|
|
44
42
|
var getHeadStyles = function getHeadStyles(theme) {
|
|
45
43
|
return (0, _core.css)({
|
|
46
|
-
borderBottom: "2px solid ".concat((
|
|
44
|
+
borderBottom: "2px solid ".concat("var(--ds-border-neutral, ".concat(_theme.head.borderColor({
|
|
47
45
|
theme: theme
|
|
48
|
-
})))
|
|
46
|
+
}), ")"))
|
|
49
47
|
});
|
|
50
48
|
};
|
|
51
49
|
|
|
@@ -67,9 +65,9 @@ var headCellStyles = (0, _core.css)([_constants3.cellStyles, {
|
|
|
67
65
|
position: 'relative',
|
|
68
66
|
textAlign: 'left',
|
|
69
67
|
verticalAlign: 'top',
|
|
70
|
-
color: (
|
|
68
|
+
color: "var(--ds-text-lowEmphasis, ".concat("var(".concat(CSS_VAR_TEXT_COLOR, ")"), ")"),
|
|
71
69
|
'&:focus': {
|
|
72
|
-
outline: "solid 2px ".concat((
|
|
70
|
+
outline: "solid 2px ".concat("var(--ds-border-focus, ".concat(_colors.B100, ")"))
|
|
73
71
|
}
|
|
74
72
|
}]); // this needs to be made static: https://product-fabric.atlassian.net/browse/DSP-2011
|
|
75
73
|
|
|
@@ -153,7 +151,7 @@ exports.getArrowStyles = getArrowStyles;
|
|
|
153
151
|
var onClickStyles = (0, _core.css)({
|
|
154
152
|
'&:hover': {
|
|
155
153
|
cursor: 'pointer',
|
|
156
|
-
backgroundColor: (
|
|
154
|
+
backgroundColor: "var(--ds-background-subtleNeutral-hover, ".concat(_colors.N30A, ")")
|
|
157
155
|
}
|
|
158
156
|
});
|
|
159
157
|
var HeadCell = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2, ref) {
|
|
@@ -15,26 +15,24 @@ var _react = require("react");
|
|
|
15
15
|
|
|
16
16
|
var _core = require("@emotion/core");
|
|
17
17
|
|
|
18
|
-
var _tokens = require("@atlaskit/tokens");
|
|
19
|
-
|
|
20
18
|
var _DynamicTable = require("./DynamicTable");
|
|
21
19
|
|
|
22
20
|
/** @jsx jsx */
|
|
23
21
|
var rowStyles = (0, _core.css)({
|
|
24
22
|
'&:focus': {
|
|
25
|
-
outline: "2px solid ".concat((
|
|
23
|
+
outline: "2px solid ".concat("var(--ds-border-focus, ".concat("var(".concat(_DynamicTable.tableRowCSSVars.CSS_VAR_HOVER_BACKGROUND, ")"), ")")),
|
|
26
24
|
outlineOffset: "-2px"
|
|
27
25
|
}
|
|
28
26
|
});
|
|
29
27
|
var rowBackgroundStyles = (0, _core.css)({
|
|
30
28
|
'&:hover': {
|
|
31
|
-
backgroundColor: (
|
|
29
|
+
backgroundColor: "var(--ds-background-transparentNeutral-hover, ".concat("var(".concat(_DynamicTable.tableRowCSSVars.CSS_VAR_HOVER_BACKGROUND, ")"), ")")
|
|
32
30
|
}
|
|
33
31
|
});
|
|
34
32
|
var rowHighlightedBackgroundStyles = (0, _core.css)({
|
|
35
|
-
backgroundColor: (
|
|
33
|
+
backgroundColor: "var(--ds-background-selected-resting, ".concat("var(".concat(_DynamicTable.tableRowCSSVars.CSS_VAR_HIGHLIGHTED_BACKGROUND, ")"), ")"),
|
|
36
34
|
'&:hover': {
|
|
37
|
-
backgroundColor: (
|
|
35
|
+
backgroundColor: "var(--ds-background-selected-hover, ".concat("var(".concat(_DynamicTable.tableRowCSSVars.CSS_VAR_HOVER_HIGHLIGHTED_BACKGROUND, ")"), ")")
|
|
38
36
|
}
|
|
39
37
|
});
|
|
40
38
|
var TableBodyRow = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
@@ -17,29 +17,27 @@ var _core = require("@emotion/core");
|
|
|
17
17
|
|
|
18
18
|
var _colors = require("@atlaskit/theme/colors");
|
|
19
19
|
|
|
20
|
-
var _tokens = require("@atlaskit/tokens");
|
|
21
|
-
|
|
22
20
|
var _TableRow = require("../TableRow");
|
|
23
21
|
|
|
24
22
|
/** @jsx jsx */
|
|
25
23
|
var rankingStyles = (0, _core.css)({
|
|
26
24
|
display: 'block'
|
|
27
25
|
});
|
|
28
|
-
var elevationStyle = (
|
|
26
|
+
var elevationStyle = "var(--ds-overlay, ".concat("0 20px 32px -8px ".concat(_colors.N50A, ", 0 0 1px ").concat(_colors.N60A), ")");
|
|
29
27
|
/**
|
|
30
28
|
* TODO: Pass the props here to get particular theme for the table
|
|
31
29
|
* Skipping it for now as it may impact migration as util-shared-styles does not support this feature
|
|
32
30
|
*/
|
|
33
31
|
|
|
34
32
|
var rankingItemStyles = (0, _core.css)({
|
|
35
|
-
backgroundColor: (
|
|
33
|
+
backgroundColor: "var(--ds-background-subtleNeutral-resting, ".concat(_colors.N20, ")"),
|
|
36
34
|
boxShadow: elevationStyle,
|
|
37
35
|
borderRadius: '2px'
|
|
38
36
|
});
|
|
39
37
|
var draggableStyles = (0, _core.css)({
|
|
40
38
|
'&:focus': {
|
|
41
39
|
outlineStyle: 'solid',
|
|
42
|
-
outlineColor: (
|
|
40
|
+
outlineColor: "var(--ds-border-focus, ".concat(_colors.B100, ")")
|
|
43
41
|
},
|
|
44
42
|
outlineWidth: '2px'
|
|
45
43
|
});
|
package/dist/cjs/theme.js
CHANGED
|
@@ -11,8 +11,6 @@ var colors = _interopRequireWildcard(require("@atlaskit/theme/colors"));
|
|
|
11
11
|
|
|
12
12
|
var _components = require("@atlaskit/theme/components");
|
|
13
13
|
|
|
14
|
-
var _tokens = require("@atlaskit/tokens");
|
|
15
|
-
|
|
16
14
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
17
15
|
|
|
18
16
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
@@ -26,46 +24,46 @@ var MSThemeColors = {
|
|
|
26
24
|
exports.MSThemeColors = MSThemeColors;
|
|
27
25
|
var arrow = {
|
|
28
26
|
defaultColor: (0, _components.themed)({
|
|
29
|
-
light: (
|
|
30
|
-
dark: (
|
|
27
|
+
light: "var(--ds-background-subtleNeutral-resting, ".concat(colors.N40, ")"),
|
|
28
|
+
dark: "var(--ds-background-subtleNeutral-resting, ".concat(colors.DN40, ")")
|
|
31
29
|
}),
|
|
32
30
|
selectedColor: (0, _components.themed)({
|
|
33
|
-
light: (
|
|
34
|
-
dark: (
|
|
31
|
+
light: "var(--ds-text-lowEmphasis, ".concat(colors.N300, ")"),
|
|
32
|
+
dark: "var(--ds-text-lowEmphasis, ".concat(colors.DN300, ")")
|
|
35
33
|
}),
|
|
36
34
|
hoverColor: (0, _components.themed)({
|
|
37
|
-
light: (
|
|
38
|
-
dark: (
|
|
35
|
+
light: "var(--ds-background-subtleNeutral-pressed, ".concat(colors.N60, ")"),
|
|
36
|
+
dark: "var(--ds-background-subtleNeutral-pressed, ".concat(colors.DN60, ")")
|
|
39
37
|
})
|
|
40
38
|
};
|
|
41
39
|
exports.arrow = arrow;
|
|
42
40
|
var row = {
|
|
43
41
|
focusOutline: (0, _components.themed)({
|
|
44
|
-
light: (
|
|
45
|
-
dark: (
|
|
42
|
+
light: "var(--ds-border-focus, ".concat(colors.B100, ")"),
|
|
43
|
+
dark: "var(--ds-border-focus, ".concat(colors.B100, ")")
|
|
46
44
|
}),
|
|
47
45
|
highlightedBackground: (0, _components.themed)({
|
|
48
|
-
light: (
|
|
49
|
-
dark: (
|
|
46
|
+
light: "var(--ds-background-selected-resting, ".concat(colors.B50, ")"),
|
|
47
|
+
dark: "var(--ds-background-selected-resting, ".concat(colors.DN50, ")")
|
|
50
48
|
}),
|
|
51
49
|
hoverBackground: (0, _components.themed)({
|
|
52
|
-
light: (
|
|
53
|
-
dark: (
|
|
50
|
+
light: "var(--ds-background-subtleBorderedNeutral-resting, ".concat(colors.N10, ")"),
|
|
51
|
+
dark: "var(--ds-background-subtleBorderedNeutral-resting, ".concat(colors.DN40, ")")
|
|
54
52
|
}),
|
|
55
53
|
hoverHighlightedBackground: (0, _components.themed)({
|
|
56
|
-
light: (
|
|
57
|
-
dark: (
|
|
54
|
+
light: "var(--ds-background-selected-hover, ".concat(colors.B75, ")"),
|
|
55
|
+
dark: "var(--ds-background-selected-hover, ".concat(colors.DN60, ")")
|
|
58
56
|
})
|
|
59
57
|
};
|
|
60
58
|
exports.row = row;
|
|
61
59
|
var head = {
|
|
62
60
|
borderColor: (0, _components.themed)({
|
|
63
|
-
light: (
|
|
64
|
-
dark: (
|
|
61
|
+
light: "var(--ds-border-neutral, ".concat(colors.N40, ")"),
|
|
62
|
+
dark: "var(--ds-border-neutral, ".concat(colors.DN50, ")")
|
|
65
63
|
}),
|
|
66
64
|
textColor: (0, _components.themed)({
|
|
67
|
-
light: (
|
|
68
|
-
dark: (
|
|
65
|
+
light: "var(--ds-text-lowEmphasis, ".concat(colors.N300, ")"),
|
|
66
|
+
dark: "var(--ds-text-lowEmphasis, ".concat(colors.DN300, ")")
|
|
69
67
|
})
|
|
70
68
|
};
|
|
71
69
|
exports.head = head;
|
package/dist/cjs/version.json
CHANGED
|
@@ -13,7 +13,7 @@ import ManagedPagination from './managed-pagination';
|
|
|
13
13
|
import RankableTableBody from './rankable/Body';
|
|
14
14
|
import TableHead from './TableHead';
|
|
15
15
|
const packageName = "@atlaskit/dynamic-table";
|
|
16
|
-
const packageVersion = "14.4.
|
|
16
|
+
const packageVersion = "14.4.3";
|
|
17
17
|
|
|
18
18
|
function toggleSortOrder(currentSortOrder) {
|
|
19
19
|
switch (currentSortOrder) {
|
|
@@ -6,7 +6,6 @@ import { css, jsx } from '@emotion/core';
|
|
|
6
6
|
import { B100, N30A } from '@atlaskit/theme/colors';
|
|
7
7
|
import { useGlobalTheme } from '@atlaskit/theme/components';
|
|
8
8
|
import { gridSize as getGridSize } from '@atlaskit/theme/constants';
|
|
9
|
-
import { token } from '@atlaskit/tokens';
|
|
10
9
|
import { ASC, DESC } from '../internal/constants';
|
|
11
10
|
import { arrow, head, MSThemeColors } from '../theme';
|
|
12
11
|
import { cellStyles, fixedSizeTruncateStyles, getTruncationStyleVars, overflowTruncateStyles, truncationWidthStyles } from './constants';
|
|
@@ -17,9 +16,9 @@ const rankingStyles = css({
|
|
|
17
16
|
});
|
|
18
17
|
|
|
19
18
|
const getHeadStyles = theme => css({
|
|
20
|
-
borderBottom: `2px solid ${
|
|
19
|
+
borderBottom: `2px solid ${`var(--ds-border-neutral, ${head.borderColor({
|
|
21
20
|
theme
|
|
22
|
-
}))}`
|
|
21
|
+
})})`}`
|
|
23
22
|
});
|
|
24
23
|
|
|
25
24
|
export const Head = ({
|
|
@@ -39,9 +38,9 @@ const headCellStyles = css([cellStyles, {
|
|
|
39
38
|
position: 'relative',
|
|
40
39
|
textAlign: 'left',
|
|
41
40
|
verticalAlign: 'top',
|
|
42
|
-
color:
|
|
41
|
+
color: `var(--ds-text-lowEmphasis, ${`var(${CSS_VAR_TEXT_COLOR})`})`,
|
|
43
42
|
'&:focus': {
|
|
44
|
-
outline: `solid 2px ${
|
|
43
|
+
outline: `solid 2px ${`var(--ds-border-focus, ${B100})`}`
|
|
45
44
|
}
|
|
46
45
|
}]); // this needs to be made static: https://product-fabric.atlassian.net/browse/DSP-2011
|
|
47
46
|
|
|
@@ -129,7 +128,7 @@ export const getArrowStyles = (isSortable, sortOrder, theme) => {
|
|
|
129
128
|
const onClickStyles = css({
|
|
130
129
|
'&:hover': {
|
|
131
130
|
cursor: 'pointer',
|
|
132
|
-
backgroundColor:
|
|
131
|
+
backgroundColor: `var(--ds-background-subtleNeutral-hover, ${N30A})`
|
|
133
132
|
}
|
|
134
133
|
});
|
|
135
134
|
export const HeadCell = /*#__PURE__*/forwardRef(({
|
|
@@ -3,23 +3,22 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
3
3
|
/** @jsx jsx */
|
|
4
4
|
import { forwardRef } from 'react';
|
|
5
5
|
import { css, jsx } from '@emotion/core';
|
|
6
|
-
import { token } from '@atlaskit/tokens';
|
|
7
6
|
import { tableRowCSSVars as cssVars } from './DynamicTable';
|
|
8
7
|
const rowStyles = css({
|
|
9
8
|
'&:focus': {
|
|
10
|
-
outline: `2px solid ${
|
|
9
|
+
outline: `2px solid ${`var(--ds-border-focus, ${`var(${cssVars.CSS_VAR_HOVER_BACKGROUND})`})`}`,
|
|
11
10
|
outlineOffset: `-2px`
|
|
12
11
|
}
|
|
13
12
|
});
|
|
14
13
|
const rowBackgroundStyles = css({
|
|
15
14
|
'&:hover': {
|
|
16
|
-
backgroundColor:
|
|
15
|
+
backgroundColor: `var(--ds-background-transparentNeutral-hover, ${`var(${cssVars.CSS_VAR_HOVER_BACKGROUND})`})`
|
|
17
16
|
}
|
|
18
17
|
});
|
|
19
18
|
const rowHighlightedBackgroundStyles = css({
|
|
20
|
-
backgroundColor:
|
|
19
|
+
backgroundColor: `var(--ds-background-selected-resting, ${`var(${cssVars.CSS_VAR_HIGHLIGHTED_BACKGROUND})`})`,
|
|
21
20
|
'&:hover': {
|
|
22
|
-
backgroundColor:
|
|
21
|
+
backgroundColor: `var(--ds-background-selected-hover, ${`var(${cssVars.CSS_VAR_HOVER_HIGHLIGHTED_BACKGROUND})`})`
|
|
23
22
|
}
|
|
24
23
|
});
|
|
25
24
|
export const TableBodyRow = /*#__PURE__*/forwardRef(({
|
|
@@ -4,26 +4,25 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
4
4
|
import { forwardRef } from 'react';
|
|
5
5
|
import { css, jsx } from '@emotion/core';
|
|
6
6
|
import { B100, N20, N50A, N60A } from '@atlaskit/theme/colors';
|
|
7
|
-
import { token } from '@atlaskit/tokens';
|
|
8
7
|
import { TableBodyRow } from '../TableRow';
|
|
9
8
|
const rankingStyles = css({
|
|
10
9
|
display: 'block'
|
|
11
10
|
});
|
|
12
|
-
const elevationStyle =
|
|
11
|
+
const elevationStyle = `var(--ds-overlay, ${`0 20px 32px -8px ${N50A}, 0 0 1px ${N60A}`})`;
|
|
13
12
|
/**
|
|
14
13
|
* TODO: Pass the props here to get particular theme for the table
|
|
15
14
|
* Skipping it for now as it may impact migration as util-shared-styles does not support this feature
|
|
16
15
|
*/
|
|
17
16
|
|
|
18
17
|
const rankingItemStyles = css({
|
|
19
|
-
backgroundColor:
|
|
18
|
+
backgroundColor: `var(--ds-background-subtleNeutral-resting, ${N20})`,
|
|
20
19
|
boxShadow: elevationStyle,
|
|
21
20
|
borderRadius: '2px'
|
|
22
21
|
});
|
|
23
22
|
const draggableStyles = css({
|
|
24
23
|
'&:focus': {
|
|
25
24
|
outlineStyle: 'solid',
|
|
26
|
-
outlineColor:
|
|
25
|
+
outlineColor: `var(--ds-border-focus, ${B100})`
|
|
27
26
|
},
|
|
28
27
|
outlineWidth: '2px'
|
|
29
28
|
});
|
package/dist/es2019/theme.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import * as colors from '@atlaskit/theme/colors';
|
|
2
2
|
import { themed } from '@atlaskit/theme/components';
|
|
3
|
-
import { token } from '@atlaskit/tokens';
|
|
4
3
|
export const MSThemeColors = {
|
|
5
4
|
Background: 'Canvas',
|
|
6
5
|
Text: 'CanvasText',
|
|
@@ -9,43 +8,43 @@ export const MSThemeColors = {
|
|
|
9
8
|
};
|
|
10
9
|
export const arrow = {
|
|
11
10
|
defaultColor: themed({
|
|
12
|
-
light:
|
|
13
|
-
dark:
|
|
11
|
+
light: `var(--ds-background-subtleNeutral-resting, ${colors.N40})`,
|
|
12
|
+
dark: `var(--ds-background-subtleNeutral-resting, ${colors.DN40})`
|
|
14
13
|
}),
|
|
15
14
|
selectedColor: themed({
|
|
16
|
-
light:
|
|
17
|
-
dark:
|
|
15
|
+
light: `var(--ds-text-lowEmphasis, ${colors.N300})`,
|
|
16
|
+
dark: `var(--ds-text-lowEmphasis, ${colors.DN300})`
|
|
18
17
|
}),
|
|
19
18
|
hoverColor: themed({
|
|
20
|
-
light:
|
|
21
|
-
dark:
|
|
19
|
+
light: `var(--ds-background-subtleNeutral-pressed, ${colors.N60})`,
|
|
20
|
+
dark: `var(--ds-background-subtleNeutral-pressed, ${colors.DN60})`
|
|
22
21
|
})
|
|
23
22
|
};
|
|
24
23
|
export const row = {
|
|
25
24
|
focusOutline: themed({
|
|
26
|
-
light:
|
|
27
|
-
dark:
|
|
25
|
+
light: `var(--ds-border-focus, ${colors.B100})`,
|
|
26
|
+
dark: `var(--ds-border-focus, ${colors.B100})`
|
|
28
27
|
}),
|
|
29
28
|
highlightedBackground: themed({
|
|
30
|
-
light:
|
|
31
|
-
dark:
|
|
29
|
+
light: `var(--ds-background-selected-resting, ${colors.B50})`,
|
|
30
|
+
dark: `var(--ds-background-selected-resting, ${colors.DN50})`
|
|
32
31
|
}),
|
|
33
32
|
hoverBackground: themed({
|
|
34
|
-
light:
|
|
35
|
-
dark:
|
|
33
|
+
light: `var(--ds-background-subtleBorderedNeutral-resting, ${colors.N10})`,
|
|
34
|
+
dark: `var(--ds-background-subtleBorderedNeutral-resting, ${colors.DN40})`
|
|
36
35
|
}),
|
|
37
36
|
hoverHighlightedBackground: themed({
|
|
38
|
-
light:
|
|
39
|
-
dark:
|
|
37
|
+
light: `var(--ds-background-selected-hover, ${colors.B75})`,
|
|
38
|
+
dark: `var(--ds-background-selected-hover, ${colors.DN60})`
|
|
40
39
|
})
|
|
41
40
|
};
|
|
42
41
|
export const head = {
|
|
43
42
|
borderColor: themed({
|
|
44
|
-
light:
|
|
45
|
-
dark:
|
|
43
|
+
light: `var(--ds-border-neutral, ${colors.N40})`,
|
|
44
|
+
dark: `var(--ds-border-neutral, ${colors.DN50})`
|
|
46
45
|
}),
|
|
47
46
|
textColor: themed({
|
|
48
|
-
light:
|
|
49
|
-
dark:
|
|
47
|
+
light: `var(--ds-text-lowEmphasis, ${colors.N300})`,
|
|
48
|
+
dark: `var(--ds-text-lowEmphasis, ${colors.DN300})`
|
|
50
49
|
})
|
|
51
50
|
};
|
package/dist/es2019/version.json
CHANGED
|
@@ -24,7 +24,7 @@ import ManagedPagination from './managed-pagination';
|
|
|
24
24
|
import RankableTableBody from './rankable/Body';
|
|
25
25
|
import TableHead from './TableHead';
|
|
26
26
|
var packageName = "@atlaskit/dynamic-table";
|
|
27
|
-
var packageVersion = "14.4.
|
|
27
|
+
var packageVersion = "14.4.3";
|
|
28
28
|
|
|
29
29
|
function toggleSortOrder(currentSortOrder) {
|
|
30
30
|
switch (currentSortOrder) {
|
|
@@ -12,7 +12,6 @@ import { css, jsx } from '@emotion/core';
|
|
|
12
12
|
import { B100, N30A } from '@atlaskit/theme/colors';
|
|
13
13
|
import { useGlobalTheme } from '@atlaskit/theme/components';
|
|
14
14
|
import { gridSize as getGridSize } from '@atlaskit/theme/constants';
|
|
15
|
-
import { token } from '@atlaskit/tokens';
|
|
16
15
|
import { ASC, DESC } from '../internal/constants';
|
|
17
16
|
import { arrow, head, MSThemeColors } from '../theme';
|
|
18
17
|
import { cellStyles, fixedSizeTruncateStyles, getTruncationStyleVars, overflowTruncateStyles, truncationWidthStyles } from './constants';
|
|
@@ -24,9 +23,9 @@ var rankingStyles = css({
|
|
|
24
23
|
|
|
25
24
|
var getHeadStyles = function getHeadStyles(theme) {
|
|
26
25
|
return css({
|
|
27
|
-
borderBottom: "2px solid ".concat(
|
|
26
|
+
borderBottom: "2px solid ".concat("var(--ds-border-neutral, ".concat(head.borderColor({
|
|
28
27
|
theme: theme
|
|
29
|
-
})))
|
|
28
|
+
}), ")"))
|
|
30
29
|
});
|
|
31
30
|
};
|
|
32
31
|
|
|
@@ -47,9 +46,9 @@ var headCellStyles = css([cellStyles, {
|
|
|
47
46
|
position: 'relative',
|
|
48
47
|
textAlign: 'left',
|
|
49
48
|
verticalAlign: 'top',
|
|
50
|
-
color:
|
|
49
|
+
color: "var(--ds-text-lowEmphasis, ".concat("var(".concat(CSS_VAR_TEXT_COLOR, ")"), ")"),
|
|
51
50
|
'&:focus': {
|
|
52
|
-
outline: "solid 2px ".concat(
|
|
51
|
+
outline: "solid 2px ".concat("var(--ds-border-focus, ".concat(B100, ")"))
|
|
53
52
|
}
|
|
54
53
|
}]); // this needs to be made static: https://product-fabric.atlassian.net/browse/DSP-2011
|
|
55
54
|
|
|
@@ -131,7 +130,7 @@ export var getArrowStyles = function getArrowStyles(isSortable, sortOrder, theme
|
|
|
131
130
|
var onClickStyles = css({
|
|
132
131
|
'&:hover': {
|
|
133
132
|
cursor: 'pointer',
|
|
134
|
-
backgroundColor:
|
|
133
|
+
backgroundColor: "var(--ds-background-subtleNeutral-hover, ".concat(N30A, ")")
|
|
135
134
|
}
|
|
136
135
|
});
|
|
137
136
|
export var HeadCell = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
@@ -4,23 +4,22 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
|
4
4
|
/** @jsx jsx */
|
|
5
5
|
import { forwardRef } from 'react';
|
|
6
6
|
import { css, jsx } from '@emotion/core';
|
|
7
|
-
import { token } from '@atlaskit/tokens';
|
|
8
7
|
import { tableRowCSSVars as cssVars } from './DynamicTable';
|
|
9
8
|
var rowStyles = css({
|
|
10
9
|
'&:focus': {
|
|
11
|
-
outline: "2px solid ".concat(
|
|
10
|
+
outline: "2px solid ".concat("var(--ds-border-focus, ".concat("var(".concat(cssVars.CSS_VAR_HOVER_BACKGROUND, ")"), ")")),
|
|
12
11
|
outlineOffset: "-2px"
|
|
13
12
|
}
|
|
14
13
|
});
|
|
15
14
|
var rowBackgroundStyles = css({
|
|
16
15
|
'&:hover': {
|
|
17
|
-
backgroundColor:
|
|
16
|
+
backgroundColor: "var(--ds-background-transparentNeutral-hover, ".concat("var(".concat(cssVars.CSS_VAR_HOVER_BACKGROUND, ")"), ")")
|
|
18
17
|
}
|
|
19
18
|
});
|
|
20
19
|
var rowHighlightedBackgroundStyles = css({
|
|
21
|
-
backgroundColor:
|
|
20
|
+
backgroundColor: "var(--ds-background-selected-resting, ".concat("var(".concat(cssVars.CSS_VAR_HIGHLIGHTED_BACKGROUND, ")"), ")"),
|
|
22
21
|
'&:hover': {
|
|
23
|
-
backgroundColor:
|
|
22
|
+
backgroundColor: "var(--ds-background-selected-hover, ".concat("var(".concat(cssVars.CSS_VAR_HOVER_HIGHLIGHTED_BACKGROUND, ")"), ")")
|
|
24
23
|
}
|
|
25
24
|
});
|
|
26
25
|
export var TableBodyRow = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
@@ -5,26 +5,25 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
|
5
5
|
import { forwardRef } from 'react';
|
|
6
6
|
import { css, jsx } from '@emotion/core';
|
|
7
7
|
import { B100, N20, N50A, N60A } from '@atlaskit/theme/colors';
|
|
8
|
-
import { token } from '@atlaskit/tokens';
|
|
9
8
|
import { TableBodyRow } from '../TableRow';
|
|
10
9
|
var rankingStyles = css({
|
|
11
10
|
display: 'block'
|
|
12
11
|
});
|
|
13
|
-
var elevationStyle =
|
|
12
|
+
var elevationStyle = "var(--ds-overlay, ".concat("0 20px 32px -8px ".concat(N50A, ", 0 0 1px ").concat(N60A), ")");
|
|
14
13
|
/**
|
|
15
14
|
* TODO: Pass the props here to get particular theme for the table
|
|
16
15
|
* Skipping it for now as it may impact migration as util-shared-styles does not support this feature
|
|
17
16
|
*/
|
|
18
17
|
|
|
19
18
|
var rankingItemStyles = css({
|
|
20
|
-
backgroundColor:
|
|
19
|
+
backgroundColor: "var(--ds-background-subtleNeutral-resting, ".concat(N20, ")"),
|
|
21
20
|
boxShadow: elevationStyle,
|
|
22
21
|
borderRadius: '2px'
|
|
23
22
|
});
|
|
24
23
|
var draggableStyles = css({
|
|
25
24
|
'&:focus': {
|
|
26
25
|
outlineStyle: 'solid',
|
|
27
|
-
outlineColor:
|
|
26
|
+
outlineColor: "var(--ds-border-focus, ".concat(B100, ")")
|
|
28
27
|
},
|
|
29
28
|
outlineWidth: '2px'
|
|
30
29
|
});
|
package/dist/esm/theme.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import * as colors from '@atlaskit/theme/colors';
|
|
2
2
|
import { themed } from '@atlaskit/theme/components';
|
|
3
|
-
import { token } from '@atlaskit/tokens';
|
|
4
3
|
export var MSThemeColors = {
|
|
5
4
|
Background: 'Canvas',
|
|
6
5
|
Text: 'CanvasText',
|
|
@@ -9,43 +8,43 @@ export var MSThemeColors = {
|
|
|
9
8
|
};
|
|
10
9
|
export var arrow = {
|
|
11
10
|
defaultColor: themed({
|
|
12
|
-
light:
|
|
13
|
-
dark:
|
|
11
|
+
light: "var(--ds-background-subtleNeutral-resting, ".concat(colors.N40, ")"),
|
|
12
|
+
dark: "var(--ds-background-subtleNeutral-resting, ".concat(colors.DN40, ")")
|
|
14
13
|
}),
|
|
15
14
|
selectedColor: themed({
|
|
16
|
-
light:
|
|
17
|
-
dark:
|
|
15
|
+
light: "var(--ds-text-lowEmphasis, ".concat(colors.N300, ")"),
|
|
16
|
+
dark: "var(--ds-text-lowEmphasis, ".concat(colors.DN300, ")")
|
|
18
17
|
}),
|
|
19
18
|
hoverColor: themed({
|
|
20
|
-
light:
|
|
21
|
-
dark:
|
|
19
|
+
light: "var(--ds-background-subtleNeutral-pressed, ".concat(colors.N60, ")"),
|
|
20
|
+
dark: "var(--ds-background-subtleNeutral-pressed, ".concat(colors.DN60, ")")
|
|
22
21
|
})
|
|
23
22
|
};
|
|
24
23
|
export var row = {
|
|
25
24
|
focusOutline: themed({
|
|
26
|
-
light:
|
|
27
|
-
dark:
|
|
25
|
+
light: "var(--ds-border-focus, ".concat(colors.B100, ")"),
|
|
26
|
+
dark: "var(--ds-border-focus, ".concat(colors.B100, ")")
|
|
28
27
|
}),
|
|
29
28
|
highlightedBackground: themed({
|
|
30
|
-
light:
|
|
31
|
-
dark:
|
|
29
|
+
light: "var(--ds-background-selected-resting, ".concat(colors.B50, ")"),
|
|
30
|
+
dark: "var(--ds-background-selected-resting, ".concat(colors.DN50, ")")
|
|
32
31
|
}),
|
|
33
32
|
hoverBackground: themed({
|
|
34
|
-
light:
|
|
35
|
-
dark:
|
|
33
|
+
light: "var(--ds-background-subtleBorderedNeutral-resting, ".concat(colors.N10, ")"),
|
|
34
|
+
dark: "var(--ds-background-subtleBorderedNeutral-resting, ".concat(colors.DN40, ")")
|
|
36
35
|
}),
|
|
37
36
|
hoverHighlightedBackground: themed({
|
|
38
|
-
light:
|
|
39
|
-
dark:
|
|
37
|
+
light: "var(--ds-background-selected-hover, ".concat(colors.B75, ")"),
|
|
38
|
+
dark: "var(--ds-background-selected-hover, ".concat(colors.DN60, ")")
|
|
40
39
|
})
|
|
41
40
|
};
|
|
42
41
|
export var head = {
|
|
43
42
|
borderColor: themed({
|
|
44
|
-
light:
|
|
45
|
-
dark:
|
|
43
|
+
light: "var(--ds-border-neutral, ".concat(colors.N40, ")"),
|
|
44
|
+
dark: "var(--ds-border-neutral, ".concat(colors.DN50, ")")
|
|
46
45
|
}),
|
|
47
46
|
textColor: themed({
|
|
48
|
-
light:
|
|
49
|
-
dark:
|
|
47
|
+
light: "var(--ds-text-lowEmphasis, ".concat(colors.N300, ")"),
|
|
48
|
+
dark: "var(--ds-text-lowEmphasis, ".concat(colors.DN300, ")")
|
|
50
49
|
})
|
|
51
50
|
};
|
package/dist/esm/version.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/dynamic-table",
|
|
3
|
-
"version": "14.4.
|
|
3
|
+
"version": "14.4.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/"
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"@atlaskit/pagination": "^14.0.0",
|
|
30
30
|
"@atlaskit/spinner": "^15.0.0",
|
|
31
31
|
"@atlaskit/theme": "^12.0.0",
|
|
32
|
-
"@atlaskit/tokens": "^0.
|
|
32
|
+
"@atlaskit/tokens": "^0.4.0",
|
|
33
33
|
"@babel/runtime": "^7.0.0",
|
|
34
34
|
"@emotion/core": "^10.0.9",
|
|
35
35
|
"react-beautiful-dnd": "^12.1.1"
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"@atlaskit/build-utils": "*",
|
|
44
44
|
"@atlaskit/button": "^16.0.0",
|
|
45
45
|
"@atlaskit/docs": "*",
|
|
46
|
-
"@atlaskit/dropdown-menu": "^
|
|
46
|
+
"@atlaskit/dropdown-menu": "^11.0.0",
|
|
47
47
|
"@atlaskit/ssr": "*",
|
|
48
48
|
"@atlaskit/toggle": "^12.3.0",
|
|
49
49
|
"@atlaskit/visual-regression": "*",
|
|
@@ -62,8 +62,12 @@
|
|
|
62
62
|
"import-structure": "atlassian-conventions"
|
|
63
63
|
},
|
|
64
64
|
"@repo/internal": {
|
|
65
|
-
"theming": "tokens"
|
|
65
|
+
"theming": "tokens",
|
|
66
|
+
"deprecation": "no-deprecated-imports",
|
|
67
|
+
"styling": [
|
|
68
|
+
"emotion"
|
|
69
|
+
]
|
|
66
70
|
}
|
|
67
71
|
},
|
|
68
72
|
"prettier": "@atlassian/atlassian-frontend-prettier-config-1.0.1"
|
|
69
|
-
}
|
|
73
|
+
}
|