@carbon/ibm-products 2.42.1-canary.4 → 2.42.1-canary.7

Sign up to get free protection for your applications and to get access to all the features.
@@ -445,7 +445,7 @@ var InlineEditCell = function InlineEditCell(_ref) {
445
445
  "data-inline-type": type,
446
446
  onClick: !nonEditCell ? handleInlineCellClick : addActiveState,
447
447
  onKeyDown: !nonEditCell ? handleKeyDown : null,
448
- className: cx("".concat(blockClass, "__inline-edit--outer-cell-button"), _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(blockClass, "__inline-edit--outer-cell-button--").concat(rowSize), rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--lg"), !rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--invalid"), config === null || config === void 0 || (_config$validator = config.validator) === null || _config$validator === void 0 ? void 0 : _config$validator.call(config, cellValue)), "".concat(blockClass, "__static--outer-cell"), !disabledCell))
448
+ className: cx("".concat(blockClass, "__inline-edit--outer-cell-button"), _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(blockClass, "__inline-edit--outer-cell-button--").concat(rowSize), rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--lg"), !rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--invalid"), inEditMode && (config === null || config === void 0 || (_config$validator = config.validator) === null || _config$validator === void 0 ? void 0 : _config$validator.call(config, cellValue))), "".concat(blockClass, "__static--outer-cell"), !disabledCell))
449
449
  }, !nonEditCell && !disabledCell && renderRegularCell(), (!inEditMode || disabledCell) && /*#__PURE__*/React__default.createElement(InlineEditButton, {
450
450
  isActiveCell: cellId === activeCellId,
451
451
  renderIcon: setRenderIcon(),
@@ -11,7 +11,7 @@ type SidePanelBaseProps = {
11
11
  /**
12
12
  * Sets the action toolbar buttons
13
13
  */
14
- actionToolbarButtons?: ButtonProps[];
14
+ actionToolbarButtons?: ButtonProps<any>[];
15
15
  /**
16
16
  * The primary actions to be shown in the side panel. Each action is
17
17
  * specified as an object that will render expressive Buttons. Any Button
@@ -20,7 +20,7 @@ type SidePanelBaseProps = {
20
20
  *
21
21
  * See https://react.carbondesignsystem.com/?path=/docs/components-button--default#component-api
22
22
  */
23
- actions?: ButtonProps[];
23
+ actions?: ButtonProps<any>[];
24
24
  /**
25
25
  * Determines if the title will animate on scroll
26
26
  */
@@ -323,12 +323,12 @@ var SidePanel = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
323
323
  if (primeFocusEl) {
324
324
  primeFocusEl === null || primeFocusEl === void 0 || primeFocusEl.focus();
325
325
  }
326
- } else {
326
+ } else if (!slideIn) {
327
327
  firstElement === null || firstElement === void 0 || firstElement.focus();
328
328
  }
329
329
  }, 0);
330
330
  }
331
- }, [animationComplete, firstElement, open, selectorPrimaryFocus]);
331
+ }, [animationComplete, firstElement, open, selectorPrimaryFocus, slideIn]);
332
332
  var primaryActionContainerClassNames = cx(["".concat(blockClass, "__actions-container"), _defineProperty({}, "".concat(blockClass, "__actions-container--condensed"), condensedActions)]);
333
333
  var mainPanelClassNames = cx([blockClass, className, "".concat(blockClass), "".concat(blockClass, "--").concat(size), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(blockClass, "--right-placement"), placement === 'right'), "".concat(blockClass, "--left-placement"), placement === 'left'), "".concat(blockClass, "--slide-in"), slideIn), "".concat(blockClass, "--has-slug"), slug), "".concat(blockClass, "--condensed-actions"), condensedActions), "".concat(blockClass, "--has-overlay"), includeOverlay)]);
334
334
  var renderTitle = function renderTitle() {
@@ -448,7 +448,7 @@ var SidePanel = /*#__PURE__*/React__default.forwardRef(function (_ref, ref) {
448
448
  placement: placement,
449
449
  shouldReduceMotion: shouldReduceMotion
450
450
  },
451
- onKeyDown: keyDownListener
451
+ onKeyDown: slideIn ? undefined : keyDownListener
452
452
  }), /*#__PURE__*/React__default.createElement(React__default.Fragment, null, renderHeader(), renderMain()), /*#__PURE__*/React__default.createElement(MotionActionSet, {
453
453
  actions: actions !== null && actions !== void 0 ? actions : [],
454
454
  className: primaryActionContainerClassNames,
@@ -471,6 +471,7 @@ SidePanel.propTypes = {
471
471
  /**
472
472
  * Sets the action toolbar buttons
473
473
  */
474
+ /**@ts-ignore */
474
475
  actionToolbarButtons: PropTypes.arrayOf(PropTypes.shape({
475
476
  label: PropTypes.string,
476
477
  leading: PropTypes.bool,
@@ -504,6 +505,7 @@ SidePanel.propTypes = {
504
505
  label: PropTypes.string,
505
506
  loading: PropTypes.bool,
506
507
  // we duplicate this Button prop to improve the DocGen here
508
+ /**@ts-ignore */
507
509
  onClick: Button.propTypes.onClick
508
510
  })))]),
509
511
  /**
@@ -454,7 +454,7 @@ var InlineEditCell = function InlineEditCell(_ref) {
454
454
  "data-inline-type": type,
455
455
  onClick: !nonEditCell ? handleInlineCellClick : addActiveState,
456
456
  onKeyDown: !nonEditCell ? handleKeyDown : null,
457
- className: cx__default["default"]("".concat(blockClass, "__inline-edit--outer-cell-button"), _rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty({}, "".concat(blockClass, "__inline-edit--outer-cell-button--").concat(rowSize), rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--lg"), !rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--invalid"), config === null || config === void 0 || (_config$validator = config.validator) === null || _config$validator === void 0 ? void 0 : _config$validator.call(config, cellValue)), "".concat(blockClass, "__static--outer-cell"), !disabledCell))
457
+ className: cx__default["default"]("".concat(blockClass, "__inline-edit--outer-cell-button"), _rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty({}, "".concat(blockClass, "__inline-edit--outer-cell-button--").concat(rowSize), rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--lg"), !rowSize), "".concat(blockClass, "__inline-edit--outer-cell-button--invalid"), inEditMode && (config === null || config === void 0 || (_config$validator = config.validator) === null || _config$validator === void 0 ? void 0 : _config$validator.call(config, cellValue))), "".concat(blockClass, "__static--outer-cell"), !disabledCell))
458
458
  }, !nonEditCell && !disabledCell && renderRegularCell(), (!inEditMode || disabledCell) && /*#__PURE__*/React__default["default"].createElement(InlineEditButton.InlineEditButton, {
459
459
  isActiveCell: cellId === activeCellId,
460
460
  renderIcon: setRenderIcon(),
@@ -11,7 +11,7 @@ type SidePanelBaseProps = {
11
11
  /**
12
12
  * Sets the action toolbar buttons
13
13
  */
14
- actionToolbarButtons?: ButtonProps[];
14
+ actionToolbarButtons?: ButtonProps<any>[];
15
15
  /**
16
16
  * The primary actions to be shown in the side panel. Each action is
17
17
  * specified as an object that will render expressive Buttons. Any Button
@@ -20,7 +20,7 @@ type SidePanelBaseProps = {
20
20
  *
21
21
  * See https://react.carbondesignsystem.com/?path=/docs/components-button--default#component-api
22
22
  */
23
- actions?: ButtonProps[];
23
+ actions?: ButtonProps<any>[];
24
24
  /**
25
25
  * Determines if the title will animate on scroll
26
26
  */
@@ -332,12 +332,12 @@ exports.SidePanel = /*#__PURE__*/React__default["default"].forwardRef(function (
332
332
  if (primeFocusEl) {
333
333
  primeFocusEl === null || primeFocusEl === void 0 || primeFocusEl.focus();
334
334
  }
335
- } else {
335
+ } else if (!slideIn) {
336
336
  firstElement === null || firstElement === void 0 || firstElement.focus();
337
337
  }
338
338
  }, 0);
339
339
  }
340
- }, [animationComplete, firstElement, open, selectorPrimaryFocus]);
340
+ }, [animationComplete, firstElement, open, selectorPrimaryFocus, slideIn]);
341
341
  var primaryActionContainerClassNames = cx__default["default"](["".concat(blockClass, "__actions-container"), _rollupPluginBabelHelpers.defineProperty({}, "".concat(blockClass, "__actions-container--condensed"), condensedActions)]);
342
342
  var mainPanelClassNames = cx__default["default"]([blockClass, className, "".concat(blockClass), "".concat(blockClass, "--").concat(size), _rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty(_rollupPluginBabelHelpers.defineProperty({}, "".concat(blockClass, "--right-placement"), placement === 'right'), "".concat(blockClass, "--left-placement"), placement === 'left'), "".concat(blockClass, "--slide-in"), slideIn), "".concat(blockClass, "--has-slug"), slug), "".concat(blockClass, "--condensed-actions"), condensedActions), "".concat(blockClass, "--has-overlay"), includeOverlay)]);
343
343
  var renderTitle = function renderTitle() {
@@ -457,7 +457,7 @@ exports.SidePanel = /*#__PURE__*/React__default["default"].forwardRef(function (
457
457
  placement: placement,
458
458
  shouldReduceMotion: shouldReduceMotion
459
459
  },
460
- onKeyDown: keyDownListener
460
+ onKeyDown: slideIn ? undefined : keyDownListener
461
461
  }), /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, renderHeader(), renderMain()), /*#__PURE__*/React__default["default"].createElement(MotionActionSet, {
462
462
  actions: actions !== null && actions !== void 0 ? actions : [],
463
463
  className: primaryActionContainerClassNames,
@@ -480,6 +480,7 @@ exports.SidePanel.propTypes = {
480
480
  /**
481
481
  * Sets the action toolbar buttons
482
482
  */
483
+ /**@ts-ignore */
483
484
  actionToolbarButtons: index["default"].arrayOf(index["default"].shape({
484
485
  label: index["default"].string,
485
486
  leading: index["default"].bool,
@@ -513,6 +514,7 @@ exports.SidePanel.propTypes = {
513
514
  label: index["default"].string,
514
515
  loading: index["default"].bool,
515
516
  // we duplicate this Button prop to improve the DocGen here
517
+ /**@ts-ignore */
516
518
  onClick: react.Button.propTypes.onClick
517
519
  })))]),
518
520
  /**
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.42.1-canary.4+7442150e7",
4
+ "version": "2.42.1-canary.7+793b7d211",
5
5
  "license": "Apache-2.0",
6
6
  "main": "lib/index.js",
7
7
  "module": "es/index.js",
@@ -97,7 +97,7 @@
97
97
  "dependencies": {
98
98
  "@babel/runtime": "^7.23.9",
99
99
  "@carbon/feature-flags": "^0.20.0",
100
- "@carbon/ibm-products-styles": "^2.38.2-canary.4+7442150e7",
100
+ "@carbon/ibm-products-styles": "^2.38.1",
101
101
  "@carbon/telemetry": "^0.1.0",
102
102
  "@dnd-kit/core": "^6.0.8",
103
103
  "@dnd-kit/modifiers": "^7.0.0",
@@ -121,5 +121,5 @@
121
121
  "react": "^16.8.6 || ^17.0.1 || ^18.2.0",
122
122
  "react-dom": "^16.8.6 || ^17.0.1 || ^18.2.0"
123
123
  },
124
- "gitHead": "7442150e758ba89967e09233bc45c944bdb8c37f"
124
+ "gitHead": "793b7d211624906e2dea5e39fa5995572b3c1628"
125
125
  }