carbon-react 93.0.0 → 93.0.4

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.
@@ -222,7 +222,7 @@ Dialog.propTypes = {
222
222
  help: _propTypes.default.string,
223
223
 
224
224
  /** Title displayed at top of dialog */
225
- title: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.object]),
225
+ title: _propTypes.default.node,
226
226
 
227
227
  /** Subtitle displayed at top of dialog */
228
228
  subtitle: _propTypes.default.string,
@@ -21,7 +21,7 @@ export interface DialogProps extends ModalProps {
21
21
  /** Subtitle displayed at top of dialog */
22
22
  subtitle?: string;
23
23
  /** Title displayed at top of dialog */
24
- title?: string | Record<string, unknown>;
24
+ title?: React.ReactNode;
25
25
  }
26
26
 
27
27
  declare class Dialog extends Modal<DialogProps> {}
@@ -148,7 +148,7 @@ DialogFullScreen.propTypes = {
148
148
  children: _propTypes.default.node,
149
149
 
150
150
  /** Title displayed at top of dialog */
151
- title: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.object]),
151
+ title: _propTypes.default.node,
152
152
 
153
153
  /** Subtitle displayed at top of dialog */
154
154
  subtitle: _propTypes.default.string,
@@ -15,7 +15,7 @@ export interface DialogFullScreenProps extends ModalProps {
15
15
  /** Subtitle displayed at top of dialog */
16
16
  subtitle?: string;
17
17
  /** Title displayed at top of dialog */
18
- title?: string | Record<string, unknown>;
18
+ title?: React.ReactNode;
19
19
  }
20
20
 
21
21
  declare class DialogFullScreen extends Modal<DialogFullScreenProps> {}
@@ -85,7 +85,7 @@ const PicklistGroup = /*#__PURE__*/_react.default.forwardRef(({
85
85
  } : {}), /*#__PURE__*/_react.default.createElement(_picklistGroup.StyledGroupWrapper, {
86
86
  highlighted: highlighted,
87
87
  type: type
88
- }, /*#__PURE__*/_react.default.createElement(_picklistGroup.StyledPicklistGroup, {
88
+ }, /*#__PURE__*/_react.default.createElement("ul", null, /*#__PURE__*/_react.default.createElement(_picklistGroup.StyledPicklistGroup, {
89
89
  onKeyDown: handleKeydown,
90
90
  "data-element": "picklist-group"
91
91
  }, title, /*#__PURE__*/_react.default.createElement(_picklistGroup.StyledGroupButton, {
@@ -100,7 +100,7 @@ const PicklistGroup = /*#__PURE__*/_react.default.forwardRef(({
100
100
  ref: ref
101
101
  })), /*#__PURE__*/_react.default.createElement(_reactTransitionGroup.TransitionGroup, {
102
102
  component: null
103
- }, content)));
103
+ }, content))));
104
104
  });
105
105
 
106
106
  PicklistGroup.propTypes = {
@@ -19,7 +19,7 @@ function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return
19
19
 
20
20
  function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (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; }
21
21
 
22
- const StyledGroupWrapper = _styledComponents.default.div`
22
+ const StyledGroupWrapper = _styledComponents.default.li`
23
23
  ${({
24
24
  highlighted,
25
25
  type,
@@ -210,7 +210,7 @@ Heading.propTypes = { ...marginPropTypes,
210
210
  /**
211
211
  * Defines the title for the heading.
212
212
  */
213
- title: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.object]),
213
+ title: _propTypes.default.node,
214
214
 
215
215
  /**
216
216
  * Defines the title id for the heading.
@@ -220,7 +220,7 @@ Heading.propTypes = { ...marginPropTypes,
220
220
  /**
221
221
  * Defines the subheader for the heading.
222
222
  */
223
- subheader: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.object]),
223
+ subheader: _propTypes.default.node,
224
224
 
225
225
  /**
226
226
  * Defines the subtitle id for the heading.
@@ -5,11 +5,11 @@ export interface HeadingProps extends MarginProps {
5
5
  /** Custom className */
6
6
  className?: string;
7
7
  /** Defines the title for the heading. */
8
- title?: string | Record<string, unknown>;
8
+ title?: React.ReactNode;
9
9
  /** Defines the title id for the heading. */
10
10
  titleId?: string;
11
11
  /** Defines the subheader for the heading. */
12
- subheader?: string | Record<string, unknown>;
12
+ subheader?: React.ReactNode;
13
13
  /** Defines the subtitle id for the heading. */
14
14
  subtitleId?: string;
15
15
  /** Defines the help text for the heading. */
@@ -48,12 +48,12 @@ Page.propTypes = {
48
48
  /**
49
49
  * The title for the page, normally a Heading component.
50
50
  */
51
- title: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.object]),
51
+ title: _propTypes.default.node.isRequired,
52
52
 
53
53
  /**
54
54
  * This component supports children.
55
55
  */
56
- children: _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.object, _propTypes.default.node])
56
+ children: _propTypes.default.node.isRequired
57
57
  };
58
58
  var _default = Page;
59
59
  exports.default = _default;
@@ -2,7 +2,7 @@ import * as React from "react";
2
2
 
3
3
  export interface PageProps {
4
4
  /** The title for the page, normally a Heading component. */
5
- title: string | Record<string, unknown>;
5
+ title: React.ReactNode;
6
6
  /** This component supports children. */
7
7
  children: React.ReactNode;
8
8
  }
@@ -117,7 +117,7 @@ Pages.propTypes = {
117
117
  pageIndex: _propTypes.default.oneOfType([_propTypes.default.number, _propTypes.default.string]),
118
118
 
119
119
  /** Individual tabs */
120
- children: _propTypes.default.oneOfType([_propTypes.default.array, _propTypes.default.object]),
120
+ children: _propTypes.default.oneOfType([_propTypes.default.arrayOf(_propTypes.default.node), _propTypes.default.node]),
121
121
 
122
122
  /** Controls which transition to use. */
123
123
  transition: _propTypes.default.string
@@ -9,7 +9,7 @@ export interface PagesProps {
9
9
  initialpageIndex?: number | string;
10
10
  pageIndex?: number | string;
11
11
  /** Individual tabs */
12
- children?: React.ReactNode | Record<string, unknown>;
12
+ children?: React.ReactNode[] | React.ReactNode;
13
13
  /** Controls which transition to use. */
14
14
  transition?: string;
15
15
  }
@@ -326,7 +326,7 @@ Tabs.propTypes = { ...marginPropTypes,
326
326
  selectedTabId: _propTypes.default.string,
327
327
 
328
328
  /** The child elements of Tabs need to be Tab components. */
329
- children: _propTypes.default.oneOfType([_propTypes.default.array, _propTypes.default.object]).isRequired,
329
+ children: _propTypes.default.oneOfType([_propTypes.default.arrayOf(_propTypes.default.node), _propTypes.default.node]).isRequired,
330
330
 
331
331
  /** Sets the alignment of the tab titles. Possible values include. */
332
332
  align: _propTypes.default.oneOf(["left", "right"]),
@@ -9,7 +9,7 @@ export interface TabsProps extends MarginProps {
9
9
  /** Allows manual control over the currently selected tab. */
10
10
  selectedTabId?: string;
11
11
  /** The child elements of Tabs need to be Tab components. */
12
- children: React.ReactNode[] | Record<string, unknown>;
12
+ children: React.ReactNode[] | React.ReactNode;
13
13
  /** Sets the alignment of the tab titles. Possible values include. */
14
14
  align?: "left" | "right";
15
15
  /** A callback for when a tab is changed. You can use this to manually control
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "carbon-react",
3
- "version": "93.0.0",
3
+ "version": "93.0.4",
4
4
  "description": "A library of reusable React components for easily building user interfaces.",
5
5
  "engineStrict": true,
6
6
  "engines": {