jrshikoku/components/atom/TextBox.js
2022-10-08 18:43:40 +09:00

24 lines
556 B
JavaScript

import { TouchableOpacity, View } from "react-native";
export const TextBox = (props) => {
const { backgroundColor, flex, onPressButton, children } = props;
return (
<TouchableOpacity
style={{
flex: flex,
backgroundColor: backgroundColor,
padding: 10,
height: 70,
alignItems: "center",
alignContent: "center",
margin: 2,
}}
onPress={onPressButton}
>
<View style={{ flex: 1 }} />
{children}
<View style={{ flex: 1 }} />
</TouchableOpacity>
);
};