added ShowInfo component to showDetails.tsx
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
import StackHeader from "@/components/ui/StackHeader";
|
import StackHeader from "@/components/ui/StackHeader";
|
||||||
import { useLocalSearchParams, router } from "expo-router";
|
import { useLocalSearchParams, router } from "expo-router";
|
||||||
|
import ShowInfo from "@/components/ui/ShowInfo";
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import {
|
import {
|
||||||
Dimensions,
|
Dimensions,
|
||||||
@@ -34,13 +35,11 @@ export default function ShowDetails() {
|
|||||||
}}
|
}}
|
||||||
style={styles.showImage}
|
style={styles.showImage}
|
||||||
/>
|
/>
|
||||||
<View style={styles.showMainInfoSection}>
|
<ShowInfo
|
||||||
<Text style={styles.showInfoText}>10 Staffeln</Text>
|
seasons={10}
|
||||||
<View style={styles.dot} />
|
participants={150}
|
||||||
<Text style={styles.showInfoText}>442 Teilnehmer</Text>
|
streamingService={streamingService as string}
|
||||||
<View style={styles.dot} />
|
/>
|
||||||
<Text style={styles.showInfoText}>RTL +</Text>
|
|
||||||
</View>
|
|
||||||
|
|
||||||
<View style={styles.showBannerLogoContainer}>
|
<View style={styles.showBannerLogoContainer}>
|
||||||
<Image
|
<Image
|
||||||
|
|||||||
49
components/ui/ShowInfo.tsx
Normal file
49
components/ui/ShowInfo.tsx
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
import { View, Text, StyleSheet } from "react-native";
|
||||||
|
|
||||||
|
type ShowInfoProps = {
|
||||||
|
seasons: number;
|
||||||
|
participants: number;
|
||||||
|
streamingService: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
const ShowInfo = ({
|
||||||
|
seasons,
|
||||||
|
participants,
|
||||||
|
streamingService,
|
||||||
|
}: ShowInfoProps) => {
|
||||||
|
return (
|
||||||
|
<View style={styles.showMainInfoSection}>
|
||||||
|
<Text style={styles.showInfoText}>{seasons} Staffeln</Text>
|
||||||
|
<View style={styles.dot} />
|
||||||
|
<Text style={styles.showInfoText}>{participants} Teilnehmer</Text>
|
||||||
|
<View style={styles.dot} />
|
||||||
|
<Text style={styles.showInfoText}>{streamingService}</Text>
|
||||||
|
</View>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
const styles = StyleSheet.create({
|
||||||
|
showMainInfoSection: {
|
||||||
|
width: "auto",
|
||||||
|
height: "auto",
|
||||||
|
alignSelf: "center",
|
||||||
|
flexDirection: "row",
|
||||||
|
justifyContent: "center",
|
||||||
|
alignItems: "center",
|
||||||
|
bottom: 25,
|
||||||
|
},
|
||||||
|
showInfoText: {
|
||||||
|
color: "hsl(0, 0%, 80%)",
|
||||||
|
fontSize: 14,
|
||||||
|
},
|
||||||
|
dot: {
|
||||||
|
width: 4,
|
||||||
|
height: 4,
|
||||||
|
borderRadius: 3,
|
||||||
|
backgroundColor: "hsl(0, 0%, 80%)",
|
||||||
|
marginHorizontal: 7,
|
||||||
|
marginTop: 2,
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
|
export default ShowInfo;
|
||||||
Reference in New Issue
Block a user