@carbon/ibm-products 2.54.0-canary.6 → 2.54.0-canary.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.
@@ -8,7 +8,7 @@
8
8
  import { objectWithoutProperties as _objectWithoutProperties, extends as _extends, objectSpread2 as _objectSpread2, defineProperty as _defineProperty } from '../../_virtual/_rollupPluginBabelHelpers.js';
9
9
  import React__default, { forwardRef } from 'react';
10
10
  import cx from 'classnames';
11
- import { Layer, OverflowMenu, OverflowMenuItem, Button, IconButton } from '@carbon/react';
11
+ import { Layer, unstable_FeatureFlags, OverflowMenu, MenuItem, Button, IconButton } from '@carbon/react';
12
12
  import { Incomplete, CheckmarkOutline } from '@carbon/react/icons';
13
13
  import PropTypes from '../../_virtual/index.js';
14
14
  import { CardHeader } from './CardHeader.js';
@@ -17,7 +17,7 @@ import { pkg } from '../../settings.js';
17
17
 
18
18
  var _Incomplete, _CheckmarkOutline;
19
19
  var _excluded = ["actionIcons", "actionsPlacement", "aiLabel", "metadata", "children", "className", "clickZone", "description", "disabled", "footerActionIcon", "getStarted", "label", "media", "mediaPosition", "onClick", "onKeyDown", "onPrimaryButtonClick", "overflowActions", "overflowAriaLabel", "onSecondaryButtonClick", "pictogram", "primaryButtonDisabled", "primaryButtonHref", "primaryButtonIcon", "primaryButtonKind", "primaryButtonPlacement", "primaryButtonText", "productive", "secondaryButtonDisabled", "secondaryButtonHref", "secondaryButtonIcon", "secondaryButtonKind", "secondaryButtonPlacement", "secondaryButtonText", "slug", "status", "sequence", "title", "titleSize", "iconDescription"],
20
- _excluded2 = ["id"],
20
+ _excluded2 = ["id", "itemText"],
21
21
  _excluded3 = ["id", "icon", "onClick", "iconDescription", "href"];
22
22
  var componentName = 'Card';
23
23
  var Card = /*#__PURE__*/forwardRef(function (_ref, ref) {
@@ -95,23 +95,27 @@ var Card = /*#__PURE__*/forwardRef(function (_ref, ref) {
95
95
  // actions can either be an overflow menu or series of icons
96
96
  var getActions = function getActions() {
97
97
  if (overflowActions.length > 0) {
98
- var pos = actionsPlacement === 'top' ? 'bottom' : 'top';
98
+ var pos = actionsPlacement === 'top' ? 'bottom-end' : 'top-end';
99
99
  var size = actionsPlacement === 'top' ? 'sm' : 'md';
100
100
  return /*#__PURE__*/React__default.createElement(Layer, {
101
101
  level: 2
102
+ }, /*#__PURE__*/React__default.createElement(unstable_FeatureFlags, {
103
+ enableV12Overflowmenu: true
102
104
  }, /*#__PURE__*/React__default.createElement(OverflowMenu, {
105
+ autoAlign: true,
106
+ menuAlignment: pos,
103
107
  size: size,
104
- direction: pos,
105
- flipped: true,
106
108
  "aria-label": overflowAriaLabel,
107
- iconDescription: iconDescription
109
+ label: iconDescription
108
110
  }, overflowActions.map(function (_ref2) {
109
111
  var id = _ref2.id,
112
+ itemText = _ref2.itemText,
110
113
  rest = _objectWithoutProperties(_ref2, _excluded2);
111
- return /*#__PURE__*/React__default.createElement(OverflowMenuItem, _extends({
112
- key: id
114
+ return /*#__PURE__*/React__default.createElement(MenuItem, _extends({
115
+ key: id,
116
+ label: itemText
113
117
  }, rest));
114
- })));
118
+ }))));
115
119
  }
116
120
  var icons = getIcons().map(function (_ref3) {
117
121
  var id = _ref3.id,
@@ -19,5 +19,6 @@ export interface DatagridProps {
19
19
  }
20
20
  /**
21
21
  * The `Datagrid` component is an extension of Carbon's DataTable component. At the most basic level, the `Datagrid` component takes in columns and rows and renders a data table. There is a set of data table extensions which this component provides support for, these can be found [here](https://pages.github.ibm.com/carbon/ibm-products/components/datagrid/overview/). This component is data driven and allows you to choose what pieces will be included based on the hooks/plugins that are provided.
22
+ * @deprecated
22
23
  */
23
24
  export declare let Datagrid: React.ForwardRefExoticComponent<DatagridProps & React.RefAttributes<HTMLDivElement>>;
@@ -21,6 +21,7 @@ var blockClass = "".concat(pkg.prefix, "--datagrid");
21
21
  var componentName = 'Datagrid';
22
22
  /**
23
23
  * The `Datagrid` component is an extension of Carbon's DataTable component. At the most basic level, the `Datagrid` component takes in columns and rows and renders a data table. There is a set of data table extensions which this component provides support for, these can be found [here](https://pages.github.ibm.com/carbon/ibm-products/components/datagrid/overview/). This component is data driven and allows you to choose what pieces will be included based on the hooks/plugins that are provided.
24
+ * @deprecated
24
25
  */
25
26
  var Datagrid = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
26
27
  var datagridState = _ref.datagridState,
@@ -55,6 +56,12 @@ var Datagrid = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
55
56
  }, /*#__PURE__*/React__default.createElement(DatagridContent, props)) : /*#__PURE__*/React__default.createElement(DatagridContent, props))));
56
57
  });
57
58
 
59
+ /**@ts-ignore*/
60
+ Datagrid.deprecated = {
61
+ level: 'warn',
62
+ details: "For more information, please refer to the migration docs https://github.com/carbon-design-system/tanstack-carbon"
63
+ };
64
+
58
65
  // Return a placeholder if not released and not enabled by feature flag
59
66
  Datagrid = pkg.checkComponentEnabled(Datagrid, componentName);
60
67
 
@@ -19,7 +19,7 @@ var settings = require('../../settings.js');
19
19
 
20
20
  var _Incomplete, _CheckmarkOutline;
21
21
  var _excluded = ["actionIcons", "actionsPlacement", "aiLabel", "metadata", "children", "className", "clickZone", "description", "disabled", "footerActionIcon", "getStarted", "label", "media", "mediaPosition", "onClick", "onKeyDown", "onPrimaryButtonClick", "overflowActions", "overflowAriaLabel", "onSecondaryButtonClick", "pictogram", "primaryButtonDisabled", "primaryButtonHref", "primaryButtonIcon", "primaryButtonKind", "primaryButtonPlacement", "primaryButtonText", "productive", "secondaryButtonDisabled", "secondaryButtonHref", "secondaryButtonIcon", "secondaryButtonKind", "secondaryButtonPlacement", "secondaryButtonText", "slug", "status", "sequence", "title", "titleSize", "iconDescription"],
22
- _excluded2 = ["id"],
22
+ _excluded2 = ["id", "itemText"],
23
23
  _excluded3 = ["id", "icon", "onClick", "iconDescription", "href"];
24
24
  var componentName = 'Card';
25
25
  var Card = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
@@ -97,23 +97,27 @@ var Card = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
97
97
  // actions can either be an overflow menu or series of icons
98
98
  var getActions = function getActions() {
99
99
  if (overflowActions.length > 0) {
100
- var pos = actionsPlacement === 'top' ? 'bottom' : 'top';
100
+ var pos = actionsPlacement === 'top' ? 'bottom-end' : 'top-end';
101
101
  var size = actionsPlacement === 'top' ? 'sm' : 'md';
102
102
  return /*#__PURE__*/React.createElement(react.Layer, {
103
103
  level: 2
104
+ }, /*#__PURE__*/React.createElement(react.unstable_FeatureFlags, {
105
+ enableV12Overflowmenu: true
104
106
  }, /*#__PURE__*/React.createElement(react.OverflowMenu, {
107
+ autoAlign: true,
108
+ menuAlignment: pos,
105
109
  size: size,
106
- direction: pos,
107
- flipped: true,
108
110
  "aria-label": overflowAriaLabel,
109
- iconDescription: iconDescription
111
+ label: iconDescription
110
112
  }, overflowActions.map(function (_ref2) {
111
113
  var id = _ref2.id,
114
+ itemText = _ref2.itemText,
112
115
  rest = _rollupPluginBabelHelpers.objectWithoutProperties(_ref2, _excluded2);
113
- return /*#__PURE__*/React.createElement(react.OverflowMenuItem, _rollupPluginBabelHelpers.extends({
114
- key: id
116
+ return /*#__PURE__*/React.createElement(react.MenuItem, _rollupPluginBabelHelpers.extends({
117
+ key: id,
118
+ label: itemText
115
119
  }, rest));
116
- })));
120
+ }))));
117
121
  }
118
122
  var icons = getIcons().map(function (_ref3) {
119
123
  var id = _ref3.id,
@@ -19,5 +19,6 @@ export interface DatagridProps {
19
19
  }
20
20
  /**
21
21
  * The `Datagrid` component is an extension of Carbon's DataTable component. At the most basic level, the `Datagrid` component takes in columns and rows and renders a data table. There is a set of data table extensions which this component provides support for, these can be found [here](https://pages.github.ibm.com/carbon/ibm-products/components/datagrid/overview/). This component is data driven and allows you to choose what pieces will be included based on the hooks/plugins that are provided.
22
+ * @deprecated
22
23
  */
23
24
  export declare let Datagrid: React.ForwardRefExoticComponent<DatagridProps & React.RefAttributes<HTMLDivElement>>;
@@ -23,6 +23,7 @@ var blockClass = "".concat(settings.pkg.prefix, "--datagrid");
23
23
  var componentName = 'Datagrid';
24
24
  /**
25
25
  * The `Datagrid` component is an extension of Carbon's DataTable component. At the most basic level, the `Datagrid` component takes in columns and rows and renders a data table. There is a set of data table extensions which this component provides support for, these can be found [here](https://pages.github.ibm.com/carbon/ibm-products/components/datagrid/overview/). This component is data driven and allows you to choose what pieces will be included based on the hooks/plugins that are provided.
26
+ * @deprecated
26
27
  */
27
28
  exports.Datagrid = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
28
29
  var datagridState = _ref.datagridState,
@@ -57,6 +58,12 @@ exports.Datagrid = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
57
58
  }, /*#__PURE__*/React.createElement(DatagridContent.DatagridContent, props)) : /*#__PURE__*/React.createElement(DatagridContent.DatagridContent, props))));
58
59
  });
59
60
 
61
+ /**@ts-ignore*/
62
+ exports.Datagrid.deprecated = {
63
+ level: 'warn',
64
+ details: "For more information, please refer to the migration docs https://github.com/carbon-design-system/tanstack-carbon"
65
+ };
66
+
60
67
  // Return a placeholder if not released and not enabled by feature flag
61
68
  exports.Datagrid = settings.pkg.checkComponentEnabled(exports.Datagrid, componentName);
62
69
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@carbon/ibm-products",
3
3
  "description": "Carbon for IBM Products",
4
- "version": "2.54.0-canary.6+69b296895",
4
+ "version": "2.54.0-canary.8+8bcae57ce",
5
5
  "license": "Apache-2.0",
6
6
  "main": "lib/index.js",
7
7
  "module": "es/index.js",
@@ -96,7 +96,7 @@
96
96
  "dependencies": {
97
97
  "@babel/runtime": "^7.23.9",
98
98
  "@carbon/feature-flags": "^0.24.0",
99
- "@carbon/ibm-products-styles": "^2.50.0-canary.6+69b296895",
99
+ "@carbon/ibm-products-styles": "^2.50.0-rc.0",
100
100
  "@carbon/telemetry": "^0.1.0",
101
101
  "@dnd-kit/core": "^6.0.8",
102
102
  "@dnd-kit/modifiers": "^7.0.0",
@@ -120,5 +120,5 @@
120
120
  "react": "^16.8.6 || ^17.0.1 || ^18.2.0",
121
121
  "react-dom": "^16.8.6 || ^17.0.1 || ^18.2.0"
122
122
  },
123
- "gitHead": "69b296895cc35695cf6c4c7eb35dd12a9edf2395"
123
+ "gitHead": "8bcae57ced1c44c00c9c51b4e675093cd6b3bab0"
124
124
  }