Deskripsi: - ui list acara - ui tambah acara - ui history acara - ui detail acara - ui edit acara No Issues
24 lines
831 B
TypeScript
24 lines
831 B
TypeScript
import Styles from "@/constants/Styles"
|
|
import { Pressable, Text, View } from "react-native"
|
|
|
|
type Props = {
|
|
category: 'purple' | 'orange'
|
|
title: string
|
|
user: string
|
|
jamAwal: string
|
|
jamAkhir: string
|
|
onPress?: () => void
|
|
}
|
|
|
|
export default function EventItem({ category, title, user, jamAwal, jamAkhir, onPress }: Props) {
|
|
return (
|
|
<Pressable style={[Styles.itemEvent, { backgroundColor: category == 'orange' ? '#FED6C5' : '#D8D8F1' }]} onPress={onPress}>
|
|
<View style={[Styles.dividerEvent, { backgroundColor: category == 'orange' ? '#FB804C' : '#535FCA' }]} />
|
|
<View>
|
|
<Text>{jamAwal} - {jamAkhir}</Text>
|
|
<Text style={[Styles.textDefaultSemiBold, Styles.mv05]}>{title}</Text>
|
|
<Text>Dibuat oleh : {user}</Text>
|
|
</View>
|
|
</Pressable>
|
|
)
|
|
} |