Merge branch 'feature/PROFILE_-_Registration' of honey.fitz.guru:eventment-app into feature/PROFILE_-_Registration
# Conflicts: # app/components/AppHeader/HeaderContentLeft.js # app/components/AppHeader/HeaderTitle/EventTitle/EventTitle.js
This commit is contained in:
@@ -6,15 +6,16 @@ import { Text, TouchableOpacity, View } from 'react-native';
|
||||
import styles from './EventTitle.styles.js';
|
||||
|
||||
export default function EventTitle({ action, date, end, name, start }) {
|
||||
const _generateEventTitle = () => {
|
||||
const whenString = `${date} | ${start} - ${end}`;
|
||||
|
||||
const whenString = `${date} | ${start} - ${end}`;
|
||||
|
||||
const _generateEventTitle = () => (
|
||||
<View style={styles.eventInfo}>
|
||||
<Text style={styles.eventName}>{name}</Text>
|
||||
<Text style={styles.eventDate}>{whenString}</Text>
|
||||
</View>
|
||||
);
|
||||
return (
|
||||
<View style={styles.eventInfo}>
|
||||
<Text style={styles.eventName}>{name}</Text>
|
||||
<Text style={styles.eventDate}>{whenString}</Text>
|
||||
</View>
|
||||
);
|
||||
};
|
||||
|
||||
if (action) {
|
||||
return <TouchableOpacity onPress={action}>{_generateEventTitle()}</TouchableOpacity>;
|
||||
|
||||
Reference in New Issue
Block a user