carbon-react 110.11.0 → 110.11.1

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.
@@ -4,7 +4,10 @@ import { defaultFocusableSelectors } from "../../../__internal__/focus-trap/focu
4
4
  export default ((mainControlRef, childrenRefs, hide) => {
5
5
  const childrenLength = useMemo(() => childrenRefs.length, [childrenRefs]);
6
6
  const handleKeyDown = useCallback(ev => {
7
- ev.preventDefault();
7
+ if (!(Events.isEnterKey(ev) || Events.isSpaceKey(ev))) {
8
+ ev.preventDefault();
9
+ }
10
+
8
11
  const currentIndex = childrenRefs === null || childrenRefs === void 0 ? void 0 : childrenRefs.findIndex(node => node.current === document.activeElement);
9
12
  let nextIndex = -1;
10
13
 
@@ -16,7 +16,10 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
16
16
  var _default = (mainControlRef, childrenRefs, hide) => {
17
17
  const childrenLength = (0, _react.useMemo)(() => childrenRefs.length, [childrenRefs]);
18
18
  const handleKeyDown = (0, _react.useCallback)(ev => {
19
- ev.preventDefault();
19
+ if (!(_events.default.isEnterKey(ev) || _events.default.isSpaceKey(ev))) {
20
+ ev.preventDefault();
21
+ }
22
+
20
23
  const currentIndex = childrenRefs === null || childrenRefs === void 0 ? void 0 : childrenRefs.findIndex(node => node.current === document.activeElement);
21
24
  let nextIndex = -1;
22
25
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "carbon-react",
3
- "version": "110.11.0",
3
+ "version": "110.11.1",
4
4
  "description": "A library of reusable React components for easily building user interfaces.",
5
5
  "files": [
6
6
  "lib",