import React, { ReactElement } from "react"; import { Pressable, Text, StyleSheet, ViewStyle, StyleProp } from "react-native"; interface NormalButtonProps { title: ReactElement; extendedStyle?: StyleProp; onPress: () => void; disabled?: boolean; } const NormalButton: React.FC = ({ title, extendedStyle, onPress, disabled }) => { return ( [styles.button, pressed ? styles.buttonPressed : null, extendedStyle]} > {title} ); }; const styles = StyleSheet.create({ button: { maxWidth: "100%", fontSize: 16, backgroundColor: "#025c72", justifyContent: "center", alignItems: "center", borderRadius: 12, padding: 20, }, buttonPressed: { backgroundColor: "#28495c", }, }); export default NormalButton;