New repo mobile after delete ! #1
@@ -30,7 +30,7 @@ export default function EventLayout() {
|
||||
<Tabs.Screen
|
||||
name="index"
|
||||
options={{
|
||||
title: "Home",
|
||||
title: "Beranda",
|
||||
tabBarIcon: ({ color }) => (
|
||||
<Ionicons size={20} name="home" color={color} />
|
||||
),
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/* eslint-disable @typescript-eslint/no-unused-vars */
|
||||
import {
|
||||
AvatarCustom,
|
||||
AvatarUsernameAndOtherComponent,
|
||||
BaseBox,
|
||||
Grid,
|
||||
StackCustom,
|
||||
TextCustom,
|
||||
} from "@/components";
|
||||
@@ -11,6 +11,7 @@ import { router } from "expo-router";
|
||||
|
||||
export default function Event() {
|
||||
const index = "test-id-event";
|
||||
const status = "publish";
|
||||
return (
|
||||
<ViewWrapper
|
||||
hideFooter
|
||||
@@ -18,17 +19,13 @@ export default function Event() {
|
||||
<FloatingButton onPress={() => router.push("/event/create")} />
|
||||
}
|
||||
>
|
||||
{/* {Array.from({ length: 10 }).map((_, index) => (
|
||||
<BaseBox key={index}>
|
||||
{Array.from({ length: 10 }).map((_, index) => (
|
||||
<BaseBox key={index} href={`/event/${index}/${status}/detail-event`}>
|
||||
<StackCustom gap={"xs"}>
|
||||
<Grid>
|
||||
<Grid.Col span={2}>
|
||||
<AvatarCustom href={`/profile/${index}`} />
|
||||
</Grid.Col>
|
||||
<Grid.Col span={10} style={{ justifyContent: "center" }}>
|
||||
<TextCustom bold>Username</TextCustom>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<AvatarUsernameAndOtherComponent
|
||||
avatarHref={`/profile/${index}`}
|
||||
name="Lorem ipsum dolor sit"
|
||||
/>
|
||||
<TextCustom truncate bold>
|
||||
Lorem ipsum dolor sit
|
||||
</TextCustom>
|
||||
@@ -40,112 +37,7 @@ export default function Event() {
|
||||
</TextCustom>
|
||||
</StackCustom>
|
||||
</BaseBox>
|
||||
))} */}
|
||||
<BaseBox>
|
||||
<StackCustom gap={"xs"}>
|
||||
<Grid>
|
||||
<Grid.Col span={2}>
|
||||
<AvatarCustom href={`/profile/${index}`} />
|
||||
</Grid.Col>
|
||||
<Grid.Col span={10} style={{ justifyContent: "center" }}>
|
||||
<TextCustom bold>Username</TextCustom>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<TextCustom truncate bold>
|
||||
Lorem ipsum dolor sit
|
||||
</TextCustom>
|
||||
<TextCustom truncate={2}>
|
||||
Lorem ipsum dolor sit amet consectetur adipisicing elit. Porro sed
|
||||
doloremque tempora soluta. Dolorem ex quidem ipsum tempora, ipsa,
|
||||
obcaecati quia suscipit numquam, voluptates commodi porro impedit
|
||||
natus quos doloremque!
|
||||
</TextCustom>
|
||||
</StackCustom>
|
||||
</BaseBox>
|
||||
<BaseBox>
|
||||
<StackCustom gap={"xs"}>
|
||||
<Grid>
|
||||
<Grid.Col span={2}>
|
||||
<AvatarCustom href={`/profile/${index}`} />
|
||||
</Grid.Col>
|
||||
<Grid.Col span={10} style={{ justifyContent: "center" }}>
|
||||
<TextCustom bold>Username</TextCustom>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<TextCustom truncate bold>
|
||||
Lorem ipsum dolor sit
|
||||
</TextCustom>
|
||||
<TextCustom truncate={2}>
|
||||
Lorem ipsum dolor sit amet consectetur adipisicing elit. Porro sed
|
||||
doloremque tempora soluta. Dolorem ex quidem ipsum tempora, ipsa,
|
||||
obcaecati quia suscipit numquam, voluptates commodi porro impedit
|
||||
natus quos doloremque!
|
||||
</TextCustom>
|
||||
</StackCustom>
|
||||
</BaseBox>
|
||||
<BaseBox>
|
||||
<StackCustom gap={"xs"}>
|
||||
<Grid>
|
||||
<Grid.Col span={2}>
|
||||
<AvatarCustom href={`/profile/${index}`} />
|
||||
</Grid.Col>
|
||||
<Grid.Col span={10} style={{ justifyContent: "center" }}>
|
||||
<TextCustom bold>Username</TextCustom>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<TextCustom truncate bold>
|
||||
Lorem ipsum dolor sit
|
||||
</TextCustom>
|
||||
<TextCustom truncate={2}>
|
||||
Lorem ipsum dolor sit amet consectetur adipisicing elit. Porro sed
|
||||
doloremque tempora soluta. Dolorem ex quidem ipsum tempora, ipsa,
|
||||
obcaecati quia suscipit numquam, voluptates commodi porro impedit
|
||||
natus quos doloremque!
|
||||
</TextCustom>
|
||||
</StackCustom>
|
||||
</BaseBox>
|
||||
<BaseBox>
|
||||
<StackCustom gap={"xs"}>
|
||||
<Grid>
|
||||
<Grid.Col span={2}>
|
||||
<AvatarCustom href={`/profile/${index}`} />
|
||||
</Grid.Col>
|
||||
<Grid.Col span={10} style={{ justifyContent: "center" }}>
|
||||
<TextCustom bold>Username</TextCustom>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<TextCustom truncate bold>
|
||||
Lorem ipsum dolor sit
|
||||
</TextCustom>
|
||||
<TextCustom truncate={2}>
|
||||
Lorem ipsum dolor sit amet consectetur adipisicing elit. Porro sed
|
||||
doloremque tempora soluta. Dolorem ex quidem ipsum tempora, ipsa,
|
||||
obcaecati quia suscipit numquam, voluptates commodi porro impedit
|
||||
natus quos doloremque!
|
||||
</TextCustom>
|
||||
</StackCustom>
|
||||
</BaseBox>
|
||||
<BaseBox>
|
||||
<StackCustom gap={"xs"}>
|
||||
<Grid>
|
||||
<Grid.Col span={2}>
|
||||
<AvatarCustom href={`/profile/${index}`} />
|
||||
</Grid.Col>
|
||||
<Grid.Col span={10} style={{ justifyContent: "center" }}>
|
||||
<TextCustom bold>Username</TextCustom>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<TextCustom truncate bold>
|
||||
Lorem ipsum dolor sit
|
||||
</TextCustom>
|
||||
<TextCustom truncate={2}>
|
||||
Lorem ipsum dolor sit amet consectetur adipisicing elit. Porro sed
|
||||
doloremque tempora soluta. Dolorem ex quidem ipsum tempora, ipsa,
|
||||
obcaecati quia suscipit numquam, voluptates commodi porro impedit
|
||||
natus quos doloremque!
|
||||
</TextCustom>
|
||||
</StackCustom>
|
||||
</BaseBox>
|
||||
))}
|
||||
</ViewWrapper>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,11 +1,46 @@
|
||||
import ViewWrapper from "@/components/_ShareComponent/ViewWrapper";
|
||||
import { GStyles } from "@/styles/global-styles";
|
||||
import { Text } from "react-native";
|
||||
import {
|
||||
AvatarCustom,
|
||||
AvatarUsernameAndOtherComponent,
|
||||
BaseBox,
|
||||
Grid,
|
||||
StackCustom,
|
||||
TextCustom,
|
||||
ViewWrapper
|
||||
} from "@/components";
|
||||
|
||||
export default function Kontribusi() {
|
||||
return (
|
||||
<ViewWrapper>
|
||||
<Text style={GStyles.textLabel}>Kontribusi</Text>
|
||||
{Array.from({ length: 10 }).map((_, index) => (
|
||||
<BaseBox key={index} href={`/event/${index}/publish/detail-event`}>
|
||||
<StackCustom>
|
||||
<AvatarUsernameAndOtherComponent
|
||||
avatarHref={`/profile/${index}`}
|
||||
rightComponent={
|
||||
<TextCustom truncate>
|
||||
{new Date().toDateString().split(" ")[2] +
|
||||
", " +
|
||||
new Date().toDateString().split(" ")[1] +
|
||||
" " +
|
||||
new Date().toDateString().split(" ")[3]}
|
||||
</TextCustom>
|
||||
}
|
||||
/>
|
||||
|
||||
<TextCustom bold align="center" size="xlarge">
|
||||
Judul Event Disini
|
||||
</TextCustom>
|
||||
|
||||
<Grid>
|
||||
{Array.from({ length: 4 }).map((_, index2) => (
|
||||
<Grid.Col span={3} key={index2}>
|
||||
<AvatarCustom size="sm" href={`/profile/${index2}`} />
|
||||
</Grid.Col>
|
||||
))}
|
||||
</Grid>
|
||||
</StackCustom>
|
||||
</BaseBox>
|
||||
))}
|
||||
</ViewWrapper>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -7,43 +7,16 @@ import {
|
||||
Spacing,
|
||||
StackCustom,
|
||||
TextCustom,
|
||||
ViewWrapper
|
||||
ViewWrapper,
|
||||
} from "@/components";
|
||||
import { IMenuDrawerItem } from "@/components/_Interface/types";
|
||||
import LeftButtonCustom from "@/components/Button/BackButton";
|
||||
import { AccentColor } from "@/constants/color-palet";
|
||||
import { ICON_SIZE_MEDIUM } from "@/constants/constans-value";
|
||||
import Event_AlertButtonStatusSection from "@/screens/Event/AlertButtonStatusSection";
|
||||
import Event_ButtonStatusSection from "@/screens/Event/ButtonStatusSection";
|
||||
import { Ionicons } from "@expo/vector-icons";
|
||||
import { menuDrawerDraftEvent } from "@/screens/Event/menuDrawerDraft";
|
||||
import { router, Stack, useLocalSearchParams } from "expo-router";
|
||||
import { useState } from "react";
|
||||
|
||||
const listData = [
|
||||
{
|
||||
title: "Lokasi",
|
||||
value:
|
||||
"Lorem ipsum dolor sit amet consectetur adipisicing elit. Consectetur eveniet ab eum ducimus tempore a quia deserunt quisquam. Tempora, atque. Aperiam minima asperiores dicta perferendis quis adipisci, dolore optio porro!",
|
||||
},
|
||||
{
|
||||
title: "Tipe Acara",
|
||||
value: "Workshop",
|
||||
},
|
||||
{
|
||||
title: "Tanggal Mulai",
|
||||
value: "Senin, 18 Juli 2025, 10:00 WIB",
|
||||
},
|
||||
{
|
||||
title: "Tanggal Berakhir",
|
||||
value: "Selasa, 19 Juli 2025, 12:00 WIB",
|
||||
},
|
||||
{
|
||||
title: "Deskripsi",
|
||||
value:
|
||||
"Lorem ipsum dolor sit amet consectetur adipisicing elit. Consectetur eveniet ab eum ducimus tempore a quia deserunt quisquam. Tempora, atque. Aperiam minima asperiores dicta perferendis quis adipisci, dolore optio porro!",
|
||||
},
|
||||
];
|
||||
|
||||
export default function EventDetail() {
|
||||
const { id, status } = useLocalSearchParams();
|
||||
const [openDrawer, setOpenDrawer] = useState(false);
|
||||
@@ -56,20 +29,6 @@ export default function EventDetail() {
|
||||
setOpenDrawer(false);
|
||||
};
|
||||
|
||||
const drawerMenuDraftEvent = ({ id }: { id: string }) => [
|
||||
{
|
||||
icon: (
|
||||
<Ionicons
|
||||
name="create"
|
||||
size={ICON_SIZE_MEDIUM}
|
||||
color={AccentColor.white}
|
||||
/>
|
||||
),
|
||||
label: "Edit event",
|
||||
path: `/(application)/(user)/event/${id}/edit`,
|
||||
},
|
||||
];
|
||||
|
||||
return (
|
||||
<>
|
||||
<Stack.Screen
|
||||
@@ -114,7 +73,7 @@ export default function EventDetail() {
|
||||
height={250}
|
||||
>
|
||||
<MenuDrawerDynamicGrid
|
||||
data={drawerMenuDraftEvent({ id: id as string })}
|
||||
data={menuDrawerDraftEvent({ id: id as string })}
|
||||
columns={4}
|
||||
onPressItem={handlePress}
|
||||
/>
|
||||
@@ -131,3 +90,28 @@ export default function EventDetail() {
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
const listData = [
|
||||
{
|
||||
title: "Lokasi",
|
||||
value:
|
||||
"Lorem ipsum dolor sit amet consectetur adipisicing elit. Consectetur eveniet ab eum ducimus tempore a quia deserunt quisquam. Tempora, atque. Aperiam minima asperiores dicta perferendis quis adipisci, dolore optio porro!",
|
||||
},
|
||||
{
|
||||
title: "Tipe Acara",
|
||||
value: "Workshop",
|
||||
},
|
||||
{
|
||||
title: "Tanggal Mulai",
|
||||
value: "Senin, 18 Juli 2025, 10:00 WIB",
|
||||
},
|
||||
{
|
||||
title: "Tanggal Berakhir",
|
||||
value: "Selasa, 19 Juli 2025, 12:00 WIB",
|
||||
},
|
||||
{
|
||||
title: "Deskripsi",
|
||||
value:
|
||||
"Lorem ipsum dolor sit amet consectetur adipisicing elit. Consectetur eveniet ab eum ducimus tempore a quia deserunt quisquam. Tempora, atque. Aperiam minima asperiores dicta perferendis quis adipisci, dolore optio porro!",
|
||||
},
|
||||
];
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
import { ImageSourcePropType, View } from "react-native";
|
||||
import Grid from "../Grid/GridCustom";
|
||||
import AvatarCustom from "../Image/AvatarCustom";
|
||||
import TextCustom from "../Text/TextCustom";
|
||||
|
||||
const AvatarUsernameAndOtherComponent = ({
|
||||
avatarHref,
|
||||
avatar,
|
||||
name,
|
||||
rightComponent,
|
||||
}: {
|
||||
avatarHref?: string;
|
||||
avatar?: ImageSourcePropType;
|
||||
name?: string;
|
||||
rightComponent?: React.ReactNode;
|
||||
}) => {
|
||||
return (
|
||||
<>
|
||||
<View>
|
||||
<Grid containerStyle={{ zIndex: 10 }}>
|
||||
<Grid.Col span={2}>
|
||||
<AvatarCustom source={avatar} href={avatarHref as any} />
|
||||
</Grid.Col>
|
||||
<Grid.Col
|
||||
span={rightComponent ? 6 : 10}
|
||||
style={{ justifyContent: "center" }}
|
||||
>
|
||||
<TextCustom truncate bold>
|
||||
{name || "Username"}
|
||||
</TextCustom>
|
||||
</Grid.Col>
|
||||
{rightComponent && (
|
||||
<Grid.Col
|
||||
span={4}
|
||||
style={{ alignItems: "flex-end", justifyContent: "center" }}
|
||||
>
|
||||
{rightComponent}
|
||||
</Grid.Col>
|
||||
)}
|
||||
</Grid>
|
||||
</View>
|
||||
</>
|
||||
);
|
||||
};
|
||||
|
||||
export default AvatarUsernameAndOtherComponent;
|
||||
@@ -8,9 +8,6 @@ import DotButton from "./Button/DotButton";
|
||||
// Drawer
|
||||
import DrawerCustom from "./Drawer/DrawerCustom";
|
||||
import MenuDrawerDynamicGrid from "./Drawer/MenuDrawerDynamicGird";
|
||||
// ShareComponent
|
||||
import Spacing from "./_ShareComponent/Spacing";
|
||||
import ViewWrapper from "./_ShareComponent/ViewWrapper";
|
||||
// Text
|
||||
import TextCustom from "./Text/TextCustom";
|
||||
// TextInput
|
||||
@@ -40,7 +37,10 @@ import CenterCustom from "./Center/CenterCustom";
|
||||
import ClickableCustom from "./Clickable/ClickableCustom";
|
||||
// Scroll
|
||||
import ScrollableCustom from "./Scroll/ScrollCustom";
|
||||
|
||||
// ShareComponent
|
||||
import Spacing from "./_ShareComponent/Spacing";
|
||||
import ViewWrapper from "./_ShareComponent/ViewWrapper";
|
||||
import AvatarUsernameAndOtherComponent from "./_ShareComponent/AvataraAndOtherHeaderComponent";
|
||||
export {
|
||||
AlertCustom,
|
||||
// Image
|
||||
@@ -84,4 +84,6 @@ export {
|
||||
ClickableCustom,
|
||||
// Scroll
|
||||
ScrollableCustom,
|
||||
// ShareComponent
|
||||
AvatarUsernameAndOtherComponent,
|
||||
};
|
||||
|
||||
17
screens/Event/menuDrawerDraft.tsx
Normal file
17
screens/Event/menuDrawerDraft.tsx
Normal file
@@ -0,0 +1,17 @@
|
||||
import { AccentColor } from "@/constants/color-palet";
|
||||
import { ICON_SIZE_MEDIUM } from "@/constants/constans-value";
|
||||
import { Ionicons } from "@expo/vector-icons";
|
||||
|
||||
export const menuDrawerDraftEvent = ({ id }: { id: string }) => [
|
||||
{
|
||||
icon: (
|
||||
<Ionicons
|
||||
name="create"
|
||||
size={ICON_SIZE_MEDIUM}
|
||||
color={AccentColor.white}
|
||||
/>
|
||||
),
|
||||
label: "Edit event",
|
||||
path: `/(application)/(user)/event/${id}/edit`,
|
||||
},
|
||||
];
|
||||
Reference in New Issue
Block a user