import React from "react"; import {ActivityIndicator, StyleSheet, TouchableOpacity} from "react-native"; import PropTypes from "prop-types"; import styles from "./styles"; import {Color} from "../../config/Color"; import Text from '../Text'; export default function Button(props) { const { style, styleText, icon, outline, full, round, loading, children, ...rest } = props; return ( {icon ? icon : null} {children || "Button"} {loading ? ( ) : null} ); } Button.propTypes = { style: PropTypes.oneOfType([PropTypes.object, PropTypes.array]), icon: PropTypes.node, outline: PropTypes.bool, full: PropTypes.bool, round: PropTypes.bool, loading: PropTypes.bool }; Button.defaultProps = { style: {}, icon: null, outline: false, full: false, round: false, loading: false };