Files
hipmi-mobile/screens/Voting/ComponentDetailDataSection.tsx
Bagasbanuna02 ce79d7c240 Voting
Add:
- api-client/api-voting: kumpulan fetching api voting

Fix:
- UI create dan (tabs) status udah terintegrasi ke API

### No Isuue
2025-09-17 17:31:44 +08:00

32 lines
1022 B
TypeScript

import { BadgeCustom, StackCustom, TextCustom } from "@/components";
import { GStyles } from "@/styles/global-styles";
import { dateTimeView } from "@/utils/dateTimeView";
import dayjs from "dayjs";
import { View } from "react-native";
export function Voting_ComponentDetailDataSection({ data }: { data?: any }) {
return (
<>
<TextCustom align="center" bold size="large">
{data?.title || "-"}
</TextCustom>
<TextCustom>{data?.deskripsi || "-"}</TextCustom>
<StackCustom gap={"sm"}>
<TextCustom bold size="small" align="center">
Batas Voting
</TextCustom>
<BadgeCustom
style={[GStyles.alignSelfCenter, { width: "70%" }]}
variant="light"
>
{data?.awalVote &&
dateTimeView({ date: data?.awalVote, withoutTime: true })}{" "}
-{" "}
{data?.akhirVote &&
dateTimeView({ date: data?.akhirVote, withoutTime: true })}
</BadgeCustom>
</StackCustom>
</>
);
}