From fd7cd5797163cb9c4bf6c2e4b27406fc679d7350 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Ska=C5=82ka?= Date: Mon, 5 Jun 2023 15:09:30 +0200 Subject: [PATCH] migrate EmojiPickerMenuItem to PressableWithoutFeedback --- src/components/EmojiPicker/EmojiPickerMenuItem.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/components/EmojiPicker/EmojiPickerMenuItem.js b/src/components/EmojiPicker/EmojiPickerMenuItem.js index bbb809174218..597046904991 100644 --- a/src/components/EmojiPicker/EmojiPickerMenuItem.js +++ b/src/components/EmojiPicker/EmojiPickerMenuItem.js @@ -1,10 +1,10 @@ import React, {PureComponent} from 'react'; import PropTypes from 'prop-types'; -import {Pressable} from 'react-native'; import styles from '../../styles/styles'; import * as StyleUtils from '../../styles/StyleUtils'; import getButtonState from '../../libs/getButtonState'; import Text from '../Text'; +import PressableWithoutFeedback from '../Pressable/PressableWithoutFeedback'; const propTypes = { /** The unicode that is used to display the emoji */ @@ -61,7 +61,7 @@ class EmojiPickerMenuItem extends PureComponent { render() { return ( - this.props.onPress(this.props.emoji)} onHoverIn={this.props.onHoverIn} onHoverOut={this.props.onHoverOut} @@ -74,9 +74,11 @@ class EmojiPickerMenuItem extends PureComponent { this.props.isHighlighted && !this.props.isUsingKeyboardMovement ? styles.emojiItemHighlighted : {}, styles.emojiItem, ]} + accessibilityLabel={this.props.emoji} + accessibilityRole="button" > {this.props.emoji} - + ); } }