import React from 'react';
import { TouchableOpacity, Image } from 'react-native';

import styles from './styles';

const ImageButton = ({ sourceImage, onPress, size }) => {
  return (
    <TouchableOpacity onPress={onPress} style={styles.container}>
      <Image
        resizeMode="contain"
        source={sourceImage}
        style={[styles.iconStyle, { width: size, height: size }]}
      />
    </TouchableOpacity>
  );
};
export default ImageButton;
