|
@@ -0,0 +1,15 @@
|
|
1
|
+import React from 'react';
|
|
2
|
+import { Text, TouchableOpacity } from 'react-native';
|
|
3
|
+
|
|
4
|
+import { styles } from '../config/styles';
|
|
5
|
+import colors from '../config/colors';
|
|
6
|
+
|
|
7
|
+function CustomButton( {title, onPress, color = "skyblue", marginTop} ) {
|
|
8
|
+ return (
|
|
9
|
+ <TouchableOpacity style={[styles.regbutton, { backgroundColor: colors[color] }, { marginTop: marginTop }]} onPress={onPress}>
|
|
10
|
+ <Text style={styles.regbuttontext}>{title}</Text>
|
|
11
|
+ </TouchableOpacity>
|
|
12
|
+ );
|
|
13
|
+}
|
|
14
|
+
|
|
15
|
+export default CustomButton;
|