@atlaskit/table 0.6.6 → 0.6.8

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 CHANGED
@@ -1,5 +1,21 @@
1
1
  # @atlaskit/table
2
2
 
3
+ ## 0.6.8
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
+ ## 0.6.7
12
+
13
+ ### Patch Changes
14
+
15
+ - [#119140](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/119140)
16
+ [`dbda45aec4c30`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/dbda45aec4c30) -
17
+ Migrated usages of deprecated button `UNSAFE` icon size props to new render prop.
18
+
3
19
  ## 0.6.6
4
20
 
5
21
  ### Patch Changes
@@ -5,6 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
7
  exports.default = void 0;
8
+ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
8
9
  var _react = require("react");
9
10
  var _react2 = require("@emotion/react");
10
11
  var _new = require("@atlaskit/button/new");
@@ -32,14 +33,18 @@ var ExpandableCell = /*#__PURE__*/(0, _react.memo)(function () {
32
33
  var handleClick = (0, _react.useCallback)(function () {
33
34
  toggleExpanded();
34
35
  }, [toggleExpanded]);
36
+ var Icon = isExpanded ? _chevronUp.default : _chevronDown.default;
35
37
  return (0, _react2.jsx)(_expandableCell.ExpandableCell, {
36
38
  as: "td"
37
39
  }, (0, _react2.jsx)(_new.IconButton, {
38
40
  spacing: "compact",
39
41
  appearance: "subtle",
40
- icon: isExpanded ? _chevronUp.default : _chevronDown.default,
42
+ icon: function icon(iconProps) {
43
+ return (0, _react2.jsx)(Icon, (0, _extends2.default)({}, iconProps, {
44
+ size: "small"
45
+ }));
46
+ },
41
47
  label: "Expand row",
42
- UNSAFE_size: "small",
43
48
  onClick: handleClick,
44
49
  "aria-pressed": isExpanded
45
50
  }));
@@ -20,7 +20,7 @@ var _ui = require("./ui");
20
20
 
21
21
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
22
22
 
23
- var SelectableCell = function SelectableCell() {
23
+ var SelectableCellComponent = function SelectableCellComponent() {
24
24
  var _useSelection = (0, _selectionProvider.useSelection)(),
25
25
  _useSelection2 = (0, _slicedToArray2.default)(_useSelection, 2),
26
26
  _useSelection2$ = _useSelection2[0],
@@ -42,4 +42,7 @@ var SelectableCell = function SelectableCell() {
42
42
  label: (0, _react2.jsx)(_visuallyHidden.default, null, "Select row ", idx + 1)
43
43
  }));
44
44
  };
45
- var _default = exports.default = /*#__PURE__*/(0, _react.memo)(SelectableCell);
45
+ var SelectableCell = /*#__PURE__*/(0, _react.memo)(SelectableCellComponent);
46
+
47
+ // eslint-disable-next-line @repo/internal/react/require-jsdoc
48
+ var _default = exports.default = SelectableCell;
@@ -1,3 +1,4 @@
1
+ import _extends from "@babel/runtime/helpers/extends";
1
2
  /**
2
3
  * @jsxRuntime classic
3
4
  */
@@ -26,14 +27,16 @@ const ExpandableCell = /*#__PURE__*/memo(() => {
26
27
  const handleClick = useCallback(() => {
27
28
  toggleExpanded();
28
29
  }, [toggleExpanded]);
30
+ const Icon = isExpanded ? ChevronUpIcon : ChevronDownIcon;
29
31
  return jsx(ExpandableCellPrimitive, {
30
32
  as: "td"
31
33
  }, jsx(IconButton, {
32
34
  spacing: "compact",
33
35
  appearance: "subtle",
34
- icon: isExpanded ? ChevronUpIcon : ChevronDownIcon,
36
+ icon: iconProps => jsx(Icon, _extends({}, iconProps, {
37
+ size: "small"
38
+ })),
35
39
  label: "Expand row",
36
- UNSAFE_size: "small",
37
40
  onClick: handleClick,
38
41
  "aria-pressed": isExpanded
39
42
  }));
@@ -11,7 +11,7 @@ import VisuallyHidden from '@atlaskit/visually-hidden';
11
11
  import { useSelection } from './hooks/selection-provider';
12
12
  import { useRowId } from './hooks/use-row-id';
13
13
  import { SelectableCell as SelectableCellPrimitive } from './ui';
14
- const SelectableCell = () => {
14
+ const SelectableCellComponent = () => {
15
15
  const [{
16
16
  allChecked,
17
17
  checked
@@ -29,4 +29,7 @@ const SelectableCell = () => {
29
29
  label: jsx(VisuallyHidden, null, "Select row ", idx + 1)
30
30
  }));
31
31
  };
32
- export default /*#__PURE__*/memo(SelectableCell);
32
+ const SelectableCell = /*#__PURE__*/memo(SelectableCellComponent);
33
+
34
+ // eslint-disable-next-line @repo/internal/react/require-jsdoc
35
+ export default SelectableCell;
@@ -1,3 +1,4 @@
1
+ import _extends from "@babel/runtime/helpers/extends";
1
2
  /**
2
3
  * @jsxRuntime classic
3
4
  */
@@ -25,14 +26,18 @@ var ExpandableCell = /*#__PURE__*/memo(function () {
25
26
  var handleClick = useCallback(function () {
26
27
  toggleExpanded();
27
28
  }, [toggleExpanded]);
29
+ var Icon = isExpanded ? ChevronUpIcon : ChevronDownIcon;
28
30
  return jsx(ExpandableCellPrimitive, {
29
31
  as: "td"
30
32
  }, jsx(IconButton, {
31
33
  spacing: "compact",
32
34
  appearance: "subtle",
33
- icon: isExpanded ? ChevronUpIcon : ChevronDownIcon,
35
+ icon: function icon(iconProps) {
36
+ return jsx(Icon, _extends({}, iconProps, {
37
+ size: "small"
38
+ }));
39
+ },
34
40
  label: "Expand row",
35
- UNSAFE_size: "small",
36
41
  onClick: handleClick,
37
42
  "aria-pressed": isExpanded
38
43
  }));
@@ -12,7 +12,7 @@ import VisuallyHidden from '@atlaskit/visually-hidden';
12
12
  import { useSelection } from './hooks/selection-provider';
13
13
  import { useRowId } from './hooks/use-row-id';
14
14
  import { SelectableCell as SelectableCellPrimitive } from './ui';
15
- var SelectableCell = function SelectableCell() {
15
+ var SelectableCellComponent = function SelectableCellComponent() {
16
16
  var _useSelection = useSelection(),
17
17
  _useSelection2 = _slicedToArray(_useSelection, 2),
18
18
  _useSelection2$ = _useSelection2[0],
@@ -34,4 +34,7 @@ var SelectableCell = function SelectableCell() {
34
34
  label: jsx(VisuallyHidden, null, "Select row ", idx + 1)
35
35
  }));
36
36
  };
37
- export default /*#__PURE__*/memo(SelectableCell);
37
+ var SelectableCell = /*#__PURE__*/memo(SelectableCellComponent);
38
+
39
+ // eslint-disable-next-line @repo/internal/react/require-jsdoc
40
+ export default SelectableCell;
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
- declare const _default: import("react").NamedExoticComponent<{}>;
3
- export default _default;
2
+ declare const SelectableCell: import("react").NamedExoticComponent<{}>;
3
+ export default SelectableCell;
@@ -1,3 +1,3 @@
1
1
  /// <reference types="react" />
2
- declare const _default: import("react").NamedExoticComponent<{}>;
3
- export default _default;
2
+ declare const SelectableCell: import("react").NamedExoticComponent<{}>;
3
+ export default SelectableCell;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/table",
3
- "version": "0.6.6",
3
+ "version": "0.6.8",
4
4
  "description": "A table is used to display data.",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -41,13 +41,13 @@
41
41
  "./primitives": "./src/ui/index.tsx"
42
42
  },
43
43
  "dependencies": {
44
- "@atlaskit/button": "^18.3.0",
44
+ "@atlaskit/button": "^18.4.0",
45
45
  "@atlaskit/checkbox": "^13.5.0",
46
46
  "@atlaskit/ds-lib": "^2.3.0",
47
47
  "@atlaskit/focus-ring": "^1.5.0",
48
48
  "@atlaskit/icon": "^22.6.0",
49
49
  "@atlaskit/primitives": "^11.0.0",
50
- "@atlaskit/tokens": "^1.53.0",
50
+ "@atlaskit/tokens": "^1.54.0",
51
51
  "@atlaskit/tooltip": "^18.5.0",
52
52
  "@atlaskit/visually-hidden": "^1.4.0",
53
53
  "@babel/runtime": "^7.0.0",