Skip to content

Commit 3d6203f

Browse files
committed
Update Pressable.js
1 parent 2a087e6 commit 3d6203f

File tree

1 file changed

+1
-4
lines changed
  • packages/react-native/Libraries/Components/Pressable

1 file changed

+1
-4
lines changed

packages/react-native/Libraries/Components/Pressable/Pressable.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,6 @@ function Pressable(
308308
onKeyDown,
309309
onKeyUp,
310310
keyDownEvents,
311-
keyUpEvents,
312311
acceptsFirstMouse,
313312
mouseDownCanMoveWindow,
314313
enableFocusRing,
@@ -353,8 +352,6 @@ function Pressable(
353352

354353
const accessibilityLabel = ariaLabel ?? props.accessibilityLabel;
355354

356-
const _keyDownEvents = keyDownEvents ?? [{key: ' '}, {key: 'Enter'}];
357-
358355
const restPropsWithDefaults: React.ElementConfig<typeof View> = {
359356
...restProps,
360357
...android_rippleConfig?.viewProps,
@@ -370,7 +367,7 @@ function Pressable(
370367
// [macOS
371368
acceptsFirstMouse: acceptsFirstMouse !== false && !disabled,
372369
enableFocusRing: enableFocusRing !== false && !disabled,
373-
keyDownEvents: _keyDownEvents,
370+
keyDownEvents: keyDownEvents ?? [{key: ' '}, {key: 'Enter'}],
374371
mouseDownCanMoveWindow: false,
375372
// macOS]
376373
};

0 commit comments

Comments
 (0)