feat: clubcard
This commit is contained in:
@@ -36,6 +36,7 @@ import { openCoinPackModal } from "../../utils/coinPackModal";
|
||||
import useNavigateToMusicDetails from "../../hooks/useNavigateToMusicDetails";
|
||||
import StageCard from "./components/StageCard";
|
||||
import ClubCard from "./components/ClubCard";
|
||||
import { BlurView } from "expo-blur";
|
||||
|
||||
const isProjectEmpty = (project) => {
|
||||
if (!project) {
|
||||
@@ -485,6 +486,14 @@ const Home = ({ navigation, route }) => {
|
||||
</View>
|
||||
);
|
||||
|
||||
const clubCard = (
|
||||
<ClubCard
|
||||
onPress={handleClubPress}
|
||||
containerStyle={stageCardItemStyle}
|
||||
variant="stage"
|
||||
/>
|
||||
);
|
||||
|
||||
const coinBalance = useMemo(() => {
|
||||
const value = currentUserData?.coins;
|
||||
if (typeof value === "number" && Number.isFinite(value)) {
|
||||
@@ -519,11 +528,32 @@ const Home = ({ navigation, route }) => {
|
||||
) : null;
|
||||
|
||||
const returnHomeButton = (
|
||||
<GradientButton
|
||||
title="retour à l'accueil"
|
||||
onPress={handleReturnToLanding}
|
||||
containerStyle={styles.returnButton}
|
||||
/>
|
||||
<Pressable onPress={handleReturnToLanding}>
|
||||
<BlurView
|
||||
tint="dark"
|
||||
intensity={30}
|
||||
style={{
|
||||
paddingHorizontal: 10,
|
||||
paddingVertical: 8,
|
||||
borderRadius: 12,
|
||||
overflow: "hidden",
|
||||
flexDirection: "row",
|
||||
alignItems: "center",
|
||||
justifyContent: "center",
|
||||
}}
|
||||
>
|
||||
<Text
|
||||
style={{
|
||||
fontSize: 14,
|
||||
color: Palette.white,
|
||||
fontFamily: FONT_FAMILY.InterRegular,
|
||||
marginRight: 5,
|
||||
}}
|
||||
>
|
||||
{"Retour à l'accueil"}
|
||||
</Text>
|
||||
</BlurView>
|
||||
</Pressable>
|
||||
);
|
||||
|
||||
const topBar = (
|
||||
@@ -588,7 +618,11 @@ const Home = ({ navigation, route }) => {
|
||||
|
||||
{stageCardsList}
|
||||
|
||||
<ClubCard onPress={handleClubPress} />
|
||||
{isWeb ? (
|
||||
<View style={styles.webClubWrapper}>{clubCard}</View>
|
||||
) : (
|
||||
<View style={styles.mobileClubWrapper}>{clubCard}</View>
|
||||
)}
|
||||
</>
|
||||
);
|
||||
|
||||
@@ -845,6 +879,15 @@ const styles = StyleSheet.create({
|
||||
flexDirection: "column",
|
||||
alignItems: "stretch",
|
||||
},
|
||||
webClubWrapper: {
|
||||
width: "100%",
|
||||
alignItems: "center",
|
||||
marginTop: 16,
|
||||
},
|
||||
mobileClubWrapper: {
|
||||
width: "100%",
|
||||
marginTop: 20,
|
||||
},
|
||||
webStageCard: {
|
||||
width: "48%",
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user