Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.

CustomButton.jsx 706B

123456789101112131415161718192021222324252627282930
  1. import React from 'react';
  2. import { StyleSheet, Text, TouchableOpacity } from 'react-native';
  3. const CustomButton = ({label, onPress}) => {
  4. return (
  5. <TouchableOpacity onPress={onPress} style={styles.button}>
  6. <Text style={styles.buttonText}>
  7. {label}
  8. </Text>
  9. </TouchableOpacity>
  10. )
  11. }
  12. const styles = StyleSheet.create({
  13. button: {
  14. backgroundColor: '#AD40AF',
  15. padding: 20,
  16. borderRadius: 10,
  17. marginBottom: 30
  18. },
  19. buttonText: {
  20. textAlign: 'center',
  21. fontWeight: '700',
  22. fontSize: 16,
  23. color: '#fff',
  24. fontFamily: 'poppins-semibold'
  25. }
  26. })
  27. export default CustomButton;