@carbon/ibm-products 2.43.2-canary.92 → 2.43.2-canary.94

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.
@@ -1,6 +1,67 @@
1
+ /**
2
+ * Copyright IBM Corp. 2023, 2023
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import React, { ReactNode } from 'react';
8
+ import '../../global/js/utils/props-helper';
9
+ interface EmptyStateV2Props {
10
+ /**
11
+ * Props for the action button. Refer to the Carbon Components button documentation for full list of props.
12
+ */
13
+ action?: {
14
+ text?: string;
15
+ };
16
+ /**
17
+ * Provide an optional class to be applied to the containing node.
18
+ */
19
+ className?: string;
20
+ /**
21
+ * Source for the illustration image if you choose to use your own custom image. Passing an illustration prop will supersede the kind option.
22
+ */
23
+ illustration?: string;
24
+ /**
25
+ * The alt text for the illustration
26
+ */
27
+ illustrationDescription?: string;
28
+ /**
29
+ * Designates the position of the illustration relative to the content
30
+ */
31
+ illustrationPosition?: 'top' | 'right' | 'bottom' | 'left';
32
+ /**
33
+ * Empty state illustration theme variations.
34
+ * To ensure you use the correct themed illustrations, you can conditionally specify light or dark
35
+ * based on your app's current theme value. Example:
36
+ * `illustrationTheme={appTheme === ('carbon--g100' || 'carbon--g90') ? 'dark' : 'light'}`
37
+ */
38
+ illustrationTheme?: 'light' | 'dark';
39
+ /**
40
+ * Determines which predefined illustration will be displayed
41
+ */
42
+ kind?: 'error' | 'noData' | 'noTags' | 'notFound' | 'notifications' | 'unauthorized';
43
+ /**
44
+ * Props for the link. Refer to the Carbon Components link documentation for full list of props.
45
+ */
46
+ link?: {
47
+ text?: string;
48
+ };
49
+ /**
50
+ * Empty state size
51
+ */
52
+ size?: 'sm' | 'lg';
53
+ /**
54
+ * Empty state subtext
55
+ */
56
+ subtitle?: string | ReactNode;
57
+ /**
58
+ * Empty state heading
59
+ */
60
+ title: string | ReactNode;
61
+ }
1
62
  /**
2
63
  * This is the V2 version of the `EmptyState` component. To use you must pass the `v2` prop to the V1 version of the component `EmptyState` and use the props below.
3
64
  * In order to avoid breaking changes in the future `EmptyStateV2` is not actually directly importable.
4
65
  */
5
- export let EmptyStateV2: React.ForwardRefExoticComponent<React.RefAttributes<any>>;
6
- import React from 'react';
66
+ export declare let EmptyStateV2: React.ForwardRefExoticComponent<EmptyStateV2Props & React.RefAttributes<HTMLDivElement>>;
67
+ export {};
@@ -18,7 +18,6 @@ import EmptyStateIllustration from './EmptyStateIllustration.js';
18
18
  var _excluded = ["action", "className", "illustration", "illustrationDescription", "illustrationPosition", "illustrationTheme", "kind", "link", "size", "subtitle", "title"];
19
19
  var blockClass = "".concat(pkg.prefix, "--empty-state");
20
20
  var componentName = 'EmptyStateV2';
21
-
22
21
  /**
23
22
  * This is the V2 version of the `EmptyState` component. To use you must pass the `v2` prop to the V1 version of the component `EmptyState` and use the props below.
24
23
  * In order to avoid breaking changes in the future `EmptyStateV2` is not actually directly importable.
@@ -72,6 +71,7 @@ EmptyStateV2.propTypes = {
72
71
  /**
73
72
  * Props for the action button. Refer to the Carbon Components button documentation for full list of props.
74
73
  */
74
+ /**@ts-ignore*/
75
75
  action: PropTypes.PropTypes.shape({
76
76
  text: PropTypes.string
77
77
  }),
@@ -105,6 +105,7 @@ EmptyStateV2.propTypes = {
105
105
  /**
106
106
  * Props for the link. Refer to the Carbon Components link documentation for full list of props.
107
107
  */
108
+ /**@ts-ignore*/
108
109
  link: PropTypes.shape({
109
110
  text: PropTypes.string
110
111
  }),
@@ -1,5 +1,64 @@
1
+ /**
2
+ * Copyright IBM Corp. 2024, 2024
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import React, { PropsWithChildren, ReactNode } from 'react';
8
+ import { CarbonIconType } from '@carbon/icons-react/lib/CarbonIcon';
9
+ type MetaData = {
10
+ id?: string;
11
+ icon?: () => void | object;
12
+ iconDescription?: string;
13
+ };
14
+ interface GetStartedCardProps extends PropsWithChildren {
15
+ /**
16
+ * Provide an optional class to be applied to the containing node.
17
+ */
18
+ className?: string;
19
+ /**
20
+ * Optional if the card should be disabled
21
+ */
22
+ disabled?: boolean;
23
+ /**
24
+ * Provides the action icon that's displayed at the footer of the card
25
+ */
26
+ footerActionIcon: () => void | object;
27
+ /**
28
+ * Optional label for the top of the card
29
+ */
30
+ label?: string | object | ReactNode;
31
+ /**
32
+ * Optional media content like an image to be placed in the card
33
+ */
34
+ media?: ReactNode;
35
+ /**
36
+ * Icons that are displayed on the card showing the time and skill needed
37
+ */
38
+ metadata: MetaData[];
39
+ /**
40
+ * Provides the callback for a clickable card
41
+ */
42
+ onClick?: () => void;
43
+ /**
44
+ * Provides the icon that's displayed at the top of the card
45
+ */
46
+ pictogram?: CarbonIconType;
47
+ /**
48
+ * Provides number for card for tasks in a sequential order
49
+ */
50
+ sequence?: number;
51
+ /**
52
+ * Provides the status that's displayed at the top of the card
53
+ */
54
+ status?: 'complete' | 'incomplete';
55
+ /**
56
+ * Title that's displayed at the top of the card
57
+ */
58
+ title?: string | object | ReactNode;
59
+ }
1
60
  /**
2
61
  * GetStartedCard a card with icon, number, and media variants
3
62
  */
4
- export let GetStartedCard: React.ForwardRefExoticComponent<React.RefAttributes<any>>;
5
- import React from 'react';
63
+ export declare let GetStartedCard: React.ForwardRefExoticComponent<GetStartedCardProps & React.RefAttributes<HTMLDivElement>>;
64
+ export {};
@@ -5,7 +5,7 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  */
7
7
 
8
- import { extends as _extends, objectDestructuringEmpty as _objectDestructuringEmpty } from '../../_virtual/_rollupPluginBabelHelpers.js';
8
+ import { extends as _extends, objectSpread2 as _objectSpread2 } from '../../_virtual/_rollupPluginBabelHelpers.js';
9
9
  import React__default from 'react';
10
10
  import PropTypes from '../../node_modules/prop-types/index.js';
11
11
  import { getDevtoolsProps } from '../../global/js/utils/devtools.js';
@@ -13,16 +13,14 @@ import { pkg } from '../../settings.js';
13
13
  import { Card } from '../Card/Card.js';
14
14
 
15
15
  var componentName = 'GetStartedCard';
16
-
17
16
  /**
18
17
  * GetStartedCard a card with icon, number, and media variants
19
18
  */
20
- var GetStartedCard = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
21
- var rest = _extends({}, (_objectDestructuringEmpty(_ref), _ref));
22
- return /*#__PURE__*/React__default.createElement(Card, _extends({
23
- getStarted: true,
24
- ref: ref
25
- }, rest, getDevtoolsProps(componentName)));
19
+ var GetStartedCard = /*#__PURE__*/React__default.forwardRef(function (props, ref) {
20
+ return /*#__PURE__*/React__default.createElement(Card, _extends({}, _objectSpread2(_objectSpread2({}, props), {}, {
21
+ ref: ref,
22
+ getStarted: true
23
+ }), getDevtoolsProps(componentName)));
26
24
  });
27
25
 
28
26
  // Return a placeholder if not released and not enabled by feature flag
@@ -40,6 +38,7 @@ GetStartedCard.propTypes = {
40
38
  /**
41
39
  * Provides the action icon that's displayed at the footer of the card
42
40
  */
41
+ /**@ts-ignore */
43
42
  footerActionIcon: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
44
43
  /**
45
44
  * Optional label for the top of the card
@@ -52,6 +51,7 @@ GetStartedCard.propTypes = {
52
51
  /**
53
52
  * Icons that are displayed on the card showing the time and skill needed
54
53
  */
54
+ /**@ts-ignore */
55
55
  metadata: PropTypes.arrayOf(PropTypes.shape({
56
56
  id: PropTypes.string,
57
57
  icon: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
@@ -64,6 +64,7 @@ GetStartedCard.propTypes = {
64
64
  /**
65
65
  * Provides the icon that's displayed at the top of the card
66
66
  */
67
+ /**@ts-ignore */
67
68
  pictogram: PropTypes.oneOfType([PropTypes.func, PropTypes.object]),
68
69
  /**
69
70
  * Provides number for card for tasks in a sequential order
@@ -1,6 +1,67 @@
1
+ /**
2
+ * Copyright IBM Corp. 2023, 2023
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import React, { ReactNode } from 'react';
8
+ import '../../global/js/utils/props-helper';
9
+ interface EmptyStateV2Props {
10
+ /**
11
+ * Props for the action button. Refer to the Carbon Components button documentation for full list of props.
12
+ */
13
+ action?: {
14
+ text?: string;
15
+ };
16
+ /**
17
+ * Provide an optional class to be applied to the containing node.
18
+ */
19
+ className?: string;
20
+ /**
21
+ * Source for the illustration image if you choose to use your own custom image. Passing an illustration prop will supersede the kind option.
22
+ */
23
+ illustration?: string;
24
+ /**
25
+ * The alt text for the illustration
26
+ */
27
+ illustrationDescription?: string;
28
+ /**
29
+ * Designates the position of the illustration relative to the content
30
+ */
31
+ illustrationPosition?: 'top' | 'right' | 'bottom' | 'left';
32
+ /**
33
+ * Empty state illustration theme variations.
34
+ * To ensure you use the correct themed illustrations, you can conditionally specify light or dark
35
+ * based on your app's current theme value. Example:
36
+ * `illustrationTheme={appTheme === ('carbon--g100' || 'carbon--g90') ? 'dark' : 'light'}`
37
+ */
38
+ illustrationTheme?: 'light' | 'dark';
39
+ /**
40
+ * Determines which predefined illustration will be displayed
41
+ */
42
+ kind?: 'error' | 'noData' | 'noTags' | 'notFound' | 'notifications' | 'unauthorized';
43
+ /**
44
+ * Props for the link. Refer to the Carbon Components link documentation for full list of props.
45
+ */
46
+ link?: {
47
+ text?: string;
48
+ };
49
+ /**
50
+ * Empty state size
51
+ */
52
+ size?: 'sm' | 'lg';
53
+ /**
54
+ * Empty state subtext
55
+ */
56
+ subtitle?: string | ReactNode;
57
+ /**
58
+ * Empty state heading
59
+ */
60
+ title: string | ReactNode;
61
+ }
1
62
  /**
2
63
  * This is the V2 version of the `EmptyState` component. To use you must pass the `v2` prop to the V1 version of the component `EmptyState` and use the props below.
3
64
  * In order to avoid breaking changes in the future `EmptyStateV2` is not actually directly importable.
4
65
  */
5
- export let EmptyStateV2: React.ForwardRefExoticComponent<React.RefAttributes<any>>;
6
- import React from 'react';
66
+ export declare let EmptyStateV2: React.ForwardRefExoticComponent<EmptyStateV2Props & React.RefAttributes<HTMLDivElement>>;
67
+ export {};
@@ -27,7 +27,6 @@ var cx__default = /*#__PURE__*/_interopDefaultLegacy(cx);
27
27
  var _excluded = ["action", "className", "illustration", "illustrationDescription", "illustrationPosition", "illustrationTheme", "kind", "link", "size", "subtitle", "title"];
28
28
  var blockClass = "".concat(settings.pkg.prefix, "--empty-state");
29
29
  var componentName = 'EmptyStateV2';
30
-
31
30
  /**
32
31
  * This is the V2 version of the `EmptyState` component. To use you must pass the `v2` prop to the V1 version of the component `EmptyState` and use the props below.
33
32
  * In order to avoid breaking changes in the future `EmptyStateV2` is not actually directly importable.
@@ -81,6 +80,7 @@ exports.EmptyStateV2.propTypes = {
81
80
  /**
82
81
  * Props for the action button. Refer to the Carbon Components button documentation for full list of props.
83
82
  */
83
+ /**@ts-ignore*/
84
84
  action: index["default"].PropTypes.shape({
85
85
  text: index["default"].string
86
86
  }),
@@ -114,6 +114,7 @@ exports.EmptyStateV2.propTypes = {
114
114
  /**
115
115
  * Props for the link. Refer to the Carbon Components link documentation for full list of props.
116
116
  */
117
+ /**@ts-ignore*/
117
118
  link: index["default"].shape({
118
119
  text: index["default"].string
119
120
  }),
@@ -1,5 +1,64 @@
1
+ /**
2
+ * Copyright IBM Corp. 2024, 2024
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import React, { PropsWithChildren, ReactNode } from 'react';
8
+ import { CarbonIconType } from '@carbon/icons-react/lib/CarbonIcon';
9
+ type MetaData = {
10
+ id?: string;
11
+ icon?: () => void | object;
12
+ iconDescription?: string;
13
+ };
14
+ interface GetStartedCardProps extends PropsWithChildren {
15
+ /**
16
+ * Provide an optional class to be applied to the containing node.
17
+ */
18
+ className?: string;
19
+ /**
20
+ * Optional if the card should be disabled
21
+ */
22
+ disabled?: boolean;
23
+ /**
24
+ * Provides the action icon that's displayed at the footer of the card
25
+ */
26
+ footerActionIcon: () => void | object;
27
+ /**
28
+ * Optional label for the top of the card
29
+ */
30
+ label?: string | object | ReactNode;
31
+ /**
32
+ * Optional media content like an image to be placed in the card
33
+ */
34
+ media?: ReactNode;
35
+ /**
36
+ * Icons that are displayed on the card showing the time and skill needed
37
+ */
38
+ metadata: MetaData[];
39
+ /**
40
+ * Provides the callback for a clickable card
41
+ */
42
+ onClick?: () => void;
43
+ /**
44
+ * Provides the icon that's displayed at the top of the card
45
+ */
46
+ pictogram?: CarbonIconType;
47
+ /**
48
+ * Provides number for card for tasks in a sequential order
49
+ */
50
+ sequence?: number;
51
+ /**
52
+ * Provides the status that's displayed at the top of the card
53
+ */
54
+ status?: 'complete' | 'incomplete';
55
+ /**
56
+ * Title that's displayed at the top of the card
57
+ */
58
+ title?: string | object | ReactNode;
59
+ }
1
60
  /**
2
61
  * GetStartedCard a card with icon, number, and media variants
3
62
  */
4
- export let GetStartedCard: React.ForwardRefExoticComponent<React.RefAttributes<any>>;
5
- import React from 'react';
63
+ export declare let GetStartedCard: React.ForwardRefExoticComponent<GetStartedCardProps & React.RefAttributes<HTMLDivElement>>;
64
+ export {};
@@ -21,16 +21,14 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
21
21
  var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
22
22
 
23
23
  var componentName = 'GetStartedCard';
24
-
25
24
  /**
26
25
  * GetStartedCard a card with icon, number, and media variants
27
26
  */
28
- exports.GetStartedCard = /*#__PURE__*/React__default["default"].forwardRef(function (_ref, ref) {
29
- var rest = _rollupPluginBabelHelpers["extends"]({}, (_rollupPluginBabelHelpers.objectDestructuringEmpty(_ref), _ref));
30
- return /*#__PURE__*/React__default["default"].createElement(Card.Card, _rollupPluginBabelHelpers["extends"]({
31
- getStarted: true,
32
- ref: ref
33
- }, rest, devtools.getDevtoolsProps(componentName)));
27
+ exports.GetStartedCard = /*#__PURE__*/React__default["default"].forwardRef(function (props, ref) {
28
+ return /*#__PURE__*/React__default["default"].createElement(Card.Card, _rollupPluginBabelHelpers["extends"]({}, _rollupPluginBabelHelpers.objectSpread2(_rollupPluginBabelHelpers.objectSpread2({}, props), {}, {
29
+ ref: ref,
30
+ getStarted: true
31
+ }), devtools.getDevtoolsProps(componentName)));
34
32
  });
35
33
 
36
34
  // Return a placeholder if not released and not enabled by feature flag
@@ -48,6 +46,7 @@ exports.GetStartedCard.propTypes = {
48
46
  /**
49
47
  * Provides the action icon that's displayed at the footer of the card
50
48
  */
49
+ /**@ts-ignore */
51
50
  footerActionIcon: index["default"].oneOfType([index["default"].func, index["default"].object]),
52
51
  /**
53
52
  * Optional label for the top of the card
@@ -60,6 +59,7 @@ exports.GetStartedCard.propTypes = {
60
59
  /**
61
60
  * Icons that are displayed on the card showing the time and skill needed
62
61
  */
62
+ /**@ts-ignore */
63
63
  metadata: index["default"].arrayOf(index["default"].shape({
64
64
  id: index["default"].string,
65
65
  icon: index["default"].oneOfType([index["default"].func, index["default"].object]),
@@ -72,6 +72,7 @@ exports.GetStartedCard.propTypes = {
72
72
  /**
73
73
  * Provides the icon that's displayed at the top of the card
74
74
  */
75
+ /**@ts-ignore */
75
76
  pictogram: index["default"].oneOfType([index["default"].func, index["default"].object]),
76
77
  /**
77
78
  * Provides number for card for tasks in a sequential order
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.43.2-canary.92+ef7c9b9a2",
4
+ "version": "2.43.2-canary.94+7731b3ccc",
5
5
  "license": "Apache-2.0",
6
6
  "main": "lib/index.js",
7
7
  "module": "es/index.js",
@@ -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": "ef7c9b9a234428770892220759a594f66b06a9d8"
123
+ "gitHead": "7731b3cccc30dea90b96a6811759a75c554a0729"
124
124
  }