Donasi
# feat - Tampilan user selesai - Tampilan admin in progres ### No Issue
This commit is contained in:
22
src/app_modules/donasi/component/box_informasi.tsx
Normal file
22
src/app_modules/donasi/component/box_informasi.tsx
Normal file
@@ -0,0 +1,22 @@
|
||||
import { Center, Grid, Group, Paper, Text, Title } from "@mantine/core";
|
||||
|
||||
export default function BoxInformasiDonasi({
|
||||
informasi,
|
||||
}: {
|
||||
informasi: string;
|
||||
}) {
|
||||
return (
|
||||
<>
|
||||
<Paper bg={"blue.3"} p={"sm"}>
|
||||
<Group>
|
||||
|
||||
|
||||
<Text fz={"xs"} fs={"italic"}>
|
||||
<Text span inherit c={"red"}>* </Text>
|
||||
{informasi}
|
||||
</Text>
|
||||
</Group>
|
||||
</Paper>
|
||||
</>
|
||||
);
|
||||
}
|
||||
23
src/app_modules/donasi/component/footer_button_donasi.tsx
Normal file
23
src/app_modules/donasi/component/footer_button_donasi.tsx
Normal file
@@ -0,0 +1,23 @@
|
||||
"use client";
|
||||
import { RouterDonasi } from "@/app/lib/router_hipmi/router_donasi";
|
||||
import { Footer, Center, Button } from "@mantine/core";
|
||||
import { useRouter } from "next/navigation";
|
||||
|
||||
export default function ButtonDonasi() {
|
||||
const router = useRouter();
|
||||
return (
|
||||
<>
|
||||
<Footer height={70} px={"md"} sx={{ borderStyle: "none" }}>
|
||||
<Center h={70}>
|
||||
<Button
|
||||
w={"100%"}
|
||||
radius={"xl"}
|
||||
onClick={() => router.push(RouterDonasi.masukan_donasi)}
|
||||
>
|
||||
Donasi
|
||||
</Button>
|
||||
</Center>
|
||||
</Footer>
|
||||
</>
|
||||
);
|
||||
}
|
||||
20
src/app_modules/donasi/component/footer_close_donasi.tsx
Normal file
20
src/app_modules/donasi/component/footer_close_donasi.tsx
Normal file
@@ -0,0 +1,20 @@
|
||||
"use client";
|
||||
|
||||
import { Footer, Center, Button } from "@mantine/core";
|
||||
import { useRouter } from "next/navigation";
|
||||
|
||||
|
||||
export default function FooterDonasi() {
|
||||
const router = useRouter()
|
||||
return (
|
||||
<>
|
||||
<Footer height={70} px={"md"}>
|
||||
<Center h={"100%"}>
|
||||
<Button w={"100%"} radius={"xl"} onClick={() => router.back()}>
|
||||
Tutup
|
||||
</Button>
|
||||
</Center>
|
||||
</Footer>
|
||||
</>
|
||||
);
|
||||
}
|
||||
67
src/app_modules/donasi/component/header_tamplate.tsx
Normal file
67
src/app_modules/donasi/component/header_tamplate.tsx
Normal file
@@ -0,0 +1,67 @@
|
||||
"use client";
|
||||
|
||||
import { Header, Group, ActionIcon, Text, Title } from "@mantine/core";
|
||||
import { IconArrowLeft, IconChevronLeft } from "@tabler/icons-react";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useState } from "react";
|
||||
|
||||
export default function HeaderTamplateDonasi({
|
||||
hideBack,
|
||||
route,
|
||||
route2,
|
||||
title,
|
||||
icon,
|
||||
bg,
|
||||
}: {
|
||||
hideBack?: boolean;
|
||||
route?: any;
|
||||
route2?: any;
|
||||
title: string;
|
||||
icon?: any;
|
||||
bg?: any;
|
||||
}) {
|
||||
const router = useRouter();
|
||||
return (
|
||||
<>
|
||||
<Header
|
||||
height={50}
|
||||
sx={{ borderStyle: "none" }}
|
||||
bg={bg === null ? "" : bg}
|
||||
>
|
||||
<Group h={50} position="apart" px={"md"}>
|
||||
{hideBack ? (
|
||||
<ActionIcon variant="transparent" disabled></ActionIcon>
|
||||
) : (
|
||||
<ActionIcon
|
||||
variant="transparent"
|
||||
onClick={() => {
|
||||
if (route === null || route === undefined) {
|
||||
return router.back();
|
||||
} else {
|
||||
return router.push(route);
|
||||
}
|
||||
}}
|
||||
>
|
||||
<IconChevronLeft />
|
||||
</ActionIcon>
|
||||
)}
|
||||
<Title order={5}>{title}</Title>
|
||||
{(() => {
|
||||
if (route2 === null || route2 === undefined) {
|
||||
return <ActionIcon disabled variant="transparent"></ActionIcon>;
|
||||
} else {
|
||||
return (
|
||||
<ActionIcon
|
||||
variant="transparent"
|
||||
onClick={() => router.push(route2)}
|
||||
>
|
||||
{icon}
|
||||
</ActionIcon>
|
||||
);
|
||||
}
|
||||
})()}
|
||||
</Group>
|
||||
</Header>
|
||||
</>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user