diff --git a/packages/react-sunbeam/package.json b/packages/react-sunbeam/package.json index 6c57ba1..80c03b2 100644 --- a/packages/react-sunbeam/package.json +++ b/packages/react-sunbeam/package.json @@ -1,6 +1,6 @@ { "name": "react-sunbeam", - "version": "2.0.0-beta.2", + "version": "2.0.0-beta.3", "description": "Spatial navigation and focus management for React", "keywords": [ "spatial-navigation", diff --git a/packages/react-sunbeam/src/focus/FocusableNode.ts b/packages/react-sunbeam/src/focus/FocusableNode.ts index 136f344..7064ac1 100644 --- a/packages/react-sunbeam/src/focus/FocusableNode.ts +++ b/packages/react-sunbeam/src/focus/FocusableNode.ts @@ -31,7 +31,7 @@ export class FocusableNode implements IFocusableNode { customGetPreferredChild?: CustomGetPreferredChildFn lock: Direction[] | Direction | undefined }) { - focusKey = focusKey ?? `focusable:${randomId()}` + focusKey = focusKey || `focusable:${randomId()}` this.focusKey = focusKey this.path = [...parentPath, focusKey] this.getBoundingBox = getBoundingBox