From 23ff7ce5d1946065866de4375b00014cb43720fd Mon Sep 17 00:00:00 2001 From: amel Date: Wed, 10 Jul 2024 17:21:37 +0800 Subject: [PATCH] upd: beranda Deskripsi: - pengaplikasian caraousel pada list proyek dan divisi No Issues --- src/module/home/components/list_divisi.tsx | 57 ++++++++----- src/module/home/components/list_project.tsx | 89 +++++++++++---------- 2 files changed, 82 insertions(+), 64 deletions(-) diff --git a/src/module/home/components/list_divisi.tsx b/src/module/home/components/list_divisi.tsx index c455c80..66e1bb4 100644 --- a/src/module/home/components/list_divisi.tsx +++ b/src/module/home/components/list_divisi.tsx @@ -1,25 +1,21 @@ 'use client' import { WARNA } from "@/module/_global"; -import { Box, Card, Flex, Title, Group, Badge, Avatar, Text } from "@mantine/core"; +import { Carousel } from "@mantine/carousel"; +import { Box, Card, Flex, Title, Text } from "@mantine/core"; import _ from "lodash"; import { useRouter } from "next/navigation"; -import { MdAccountCircle } from "react-icons/md"; const dataProject = [ - // { - // id: 4, - // title: 'Project 4', - // description: 'Tempat berkumpul semua anggota / staff perbekal darmasaba', - // status: 'PROSES', - // color: '#C5771A' - // }, - // { - // id: 5, - // title: 'Project5', - // description: 'Tempat berkumpul semua anggota / staff perbekal darmasaba', - // status: 'PROSES', - // color: '#C5771A' - // }, + { + id: 4, + title: 'Divisi Keuangan', + total: 24 + }, + { + id: 5, + title: 'Divisi Kesekretariatan', + total: 18 + }, { id: 6, title: 'Divisi Kemasyarakatan', @@ -33,7 +29,28 @@ export default function ListDivisi() { <> Divisi Terbaru - {dataProject.map((v, i) => { + + {dataProject.map((v) => + + + + + + + {_.toUpper(v.title)} + + + + + PROYEK + {v.total} + + + + + )} + + {/* {dataProject.map((v, i) => { return ( @@ -44,14 +61,14 @@ export default function ListDivisi() { - - PROYEK + + PROYEK {v.total} ); - })} + })} */} ) diff --git a/src/module/home/components/list_project.tsx b/src/module/home/components/list_project.tsx index 5ce4640..be03d22 100644 --- a/src/module/home/components/list_project.tsx +++ b/src/module/home/components/list_project.tsx @@ -1,30 +1,33 @@ 'use client' import { WARNA } from "@/module/_global"; -import { Box, Card, Flex, Title, Group, Badge, Avatar, Text } from "@mantine/core"; +import { Carousel } from "@mantine/carousel"; +import { Box, Card, Flex, Title, Text, Progress, Stack } from "@mantine/core"; import { useRouter } from "next/navigation"; -import { MdAccountCircle } from "react-icons/md"; const dataProject = [ - // { - // id: 4, - // title: 'Project 4', - // description: 'Tempat berkumpul semua anggota / staff perbekal darmasaba', - // status: 'PROSES', - // color: '#C5771A' - // }, - // { - // id: 5, - // title: 'Project5', - // description: 'Tempat berkumpul semua anggota / staff perbekal darmasaba', - // status: 'PROSES', - // color: '#C5771A' - // }, + { + id: 4, + title: 'Project 4', + description: 'Tempat berkumpul semua anggota / staff perbekal darmasaba', + status: 'PROSES', + progress: 60, + date: '05 Mei 2024' + }, + { + id: 5, + title: 'Project5', + description: 'Tempat berkumpul semua anggota / staff perbekal darmasaba', + status: 'PROSES', + progress: 80, + date: '08 Juni 2024' + }, { id: 6, title: 'Project 6', description: 'Tempat berkumpul semua anggota / staff perbekal darmasaba', status: 'PROSES', - color: '#C5771A' + progress: 47, + date: '10 Mei 2024' }, ] export default function ListProjects() { @@ -34,33 +37,31 @@ export default function ListProjects() { <> Proyek Terbaru - {dataProject.map((v, i) => { - return ( - - router.push(`/project/${v.id}`)}> - - - - {v.title} - - - - - {v.description} - - {v.status} - - - - - +5 - - - - - - ); - })} + + {dataProject.map((v) => + + + router.push(`/project/${v.id}`)}> + + + + {v.title} + + + + + + + {v.progress}% + + + Progres {v.date} + + + + + )} + )