mirror of
https://github.com/BlueWallet/BlueWallet.git
synced 2025-02-22 15:04:50 +01:00
REF: CoinSelected to TSX
This commit is contained in:
parent
5bc04e4bdb
commit
da5fa92378
1 changed files with 7 additions and 8 deletions
|
@ -1,5 +1,4 @@
|
|||
import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { View, Text, TouchableOpacity, StyleSheet } from 'react-native';
|
||||
import { Avatar } from 'react-native-elements';
|
||||
|
||||
|
@ -34,7 +33,13 @@ const styles = StyleSheet.create({
|
|||
},
|
||||
});
|
||||
|
||||
const CoinsSelected = ({ number, onContainerPress, onClose }) => (
|
||||
interface CoinsSelectedProps {
|
||||
number: number;
|
||||
onContainerPress: () => void;
|
||||
onClose: () => void;
|
||||
}
|
||||
|
||||
const CoinsSelected: React.FC<CoinsSelectedProps> = ({ number, onContainerPress, onClose }) => (
|
||||
<TouchableOpacity accessibilityRole="button" style={styles.root} onPress={onContainerPress}>
|
||||
<View style={styles.labelContainer}>
|
||||
<Text style={styles.labelText}>{loc.formatString(loc.cc.coins_selected, { number })}</Text>
|
||||
|
@ -45,10 +50,4 @@ const CoinsSelected = ({ number, onContainerPress, onClose }) => (
|
|||
</TouchableOpacity>
|
||||
);
|
||||
|
||||
CoinsSelected.propTypes = {
|
||||
number: PropTypes.number.isRequired,
|
||||
onContainerPress: PropTypes.func.isRequired,
|
||||
onClose: PropTypes.func.isRequired,
|
||||
};
|
||||
|
||||
export default CoinsSelected;
|
Loading…
Add table
Reference in a new issue