Skip to content

Commit

Permalink
migrated EmojiSkinToneList to PressableWithoutFeedback
Browse files Browse the repository at this point in the history
  • Loading branch information
Skalakid committed Jun 5, 2023
1 parent 5269e2a commit 0faf297
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/components/EmojiPicker/EmojiSkinToneList.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
import _ from 'underscore';
import React, {useState, useCallback} from 'react';
import {View, Pressable} from 'react-native';
import {View} from 'react-native';
import PropTypes from 'prop-types';
import styles from '../../styles/styles';
import * as Emojis from '../../../assets/emojis';
import withLocalize, {withLocalizePropTypes} from '../withLocalize';
import Text from '../Text';
import EmojiPickerMenuItem from './EmojiPickerMenuItem';
import getSkinToneEmojiFromIndex from './getSkinToneEmojiFromIndex';
import PressableWithoutFeedback from '../Pressable/PressableWithoutFeedback';

const propTypes = {
/** Stores user's preferred skin tone */
Expand Down Expand Up @@ -42,15 +43,17 @@ function EmojiSkinToneList(props) {
return (
<View style={[styles.flexRow, styles.p3, styles.ph4, styles.emojiPickerContainer]}>
{!isSkinToneListVisible && (
<Pressable
<PressableWithoutFeedback
onPress={toggleIsSkinToneListVisible}
style={[styles.flex1, styles.flexRow, styles.alignSelfCenter, styles.justifyContentStart, styles.alignItemsCenter]}
accessibilityLabel={props.translate('emojiPicker.skinTonePickerLabel')}
accessibilityRole="button"
>
<View style={[styles.emojiItem, styles.justifyContentCenter]}>
<Text style={[styles.emojiText, styles.ph2, styles.textNoWrap]}>{currentSkinTone.code}</Text>
</View>
<Text style={[styles.emojiSkinToneTitle]}>{props.translate('emojiPicker.skinTonePickerLabel')}</Text>
</Pressable>
</PressableWithoutFeedback>
)}
{isSkinToneListVisible && (
<View style={[styles.flexRow, styles.flex1]}>
Expand Down

0 comments on commit 0faf297

Please sign in to comment.