style : update style
This commit is contained in:
@@ -176,7 +176,7 @@ export default function AddMemberDetailProject() {
|
||||
borderBottom: `1px solid ${"#E0DFDF"}`
|
||||
}}>
|
||||
{selectedFiles.length > 0 ? (
|
||||
<Carousel dragFree slideGap={"xs"} align="start" slideSize={"xs"} withIndicators withControls={false}>
|
||||
<Carousel dragFree slideGap={"xs"} align="start" slideSize={"xs"} withControls={false}>
|
||||
{selectedFiles.map((v: any, i: any) => {
|
||||
return (
|
||||
<Carousel.Slide key={i}>
|
||||
|
||||
@@ -58,7 +58,7 @@ export default function ViewDateEndTask({ onClose, onSet }: {onClose: (val: bool
|
||||
<HiChevronLeft size={20} color='white' />
|
||||
</ActionIcon>
|
||||
</Box>
|
||||
} title={"Tanggal Tugas"} menu />
|
||||
} title={"Tanggal dan Tugas"} menu />
|
||||
<Box p={20}>
|
||||
<Group
|
||||
justify="center"
|
||||
@@ -107,7 +107,7 @@ export default function ViewDateEndTask({ onClose, onSet }: {onClose: (val: bool
|
||||
borderRadius: 10,
|
||||
},
|
||||
}}
|
||||
placeholder="Input Nama Tahapan"
|
||||
placeholder="Input Judul Tahapan"
|
||||
label="Judul Tahapan"
|
||||
required
|
||||
size="md"
|
||||
@@ -119,7 +119,7 @@ export default function ViewDateEndTask({ onClose, onSet }: {onClose: (val: bool
|
||||
onBlur={() => setTouched({ ...touched, title: true })}
|
||||
error={
|
||||
touched.title && (
|
||||
title == "" ? "Judul Tidak Boleh Kosong" : null
|
||||
title == "" ? "Judul Tahapan Tidak Boleh Kosong" : null
|
||||
)
|
||||
}
|
||||
/>
|
||||
|
||||
@@ -138,15 +138,20 @@ export default function CreateProject() {
|
||||
<Box>
|
||||
<LayoutNavbarNew back="/project" title="tambah Kegiatan" menu />
|
||||
<Box p={20}>
|
||||
<Stack>
|
||||
<Box>
|
||||
{
|
||||
(roleLogin.get() == "supadmin") && (
|
||||
<Select
|
||||
placeholder="Grup"
|
||||
label="Grup"
|
||||
size="md"
|
||||
styles={{
|
||||
input: {
|
||||
border: `1px solid ${"#D6D8F6"}`,
|
||||
borderRadius: 10,
|
||||
},
|
||||
}}
|
||||
required
|
||||
radius={40}
|
||||
data={dataGroup?.map((pro: any) => ({
|
||||
value: String(pro.id),
|
||||
label: pro.name
|
||||
@@ -174,6 +179,7 @@ export default function CreateProject() {
|
||||
borderRadius: 10,
|
||||
},
|
||||
}}
|
||||
mt={10}
|
||||
required withAsterisk
|
||||
placeholder="Nama Kegiatan"
|
||||
size="md"
|
||||
@@ -189,7 +195,7 @@ export default function CreateProject() {
|
||||
)
|
||||
}
|
||||
/>
|
||||
<Box onClick={() => { setOpenTugas(true) }}>
|
||||
<Box onClick={() => { setOpenTugas(true) }} mt={15}>
|
||||
<Group
|
||||
justify="space-between"
|
||||
p={10}
|
||||
@@ -213,11 +219,12 @@ export default function CreateProject() {
|
||||
// setOpenDrawer(true)
|
||||
openRef.current?.()
|
||||
}
|
||||
mt={15}
|
||||
>
|
||||
<Text>Upload File</Text>
|
||||
<IoIosArrowDropright size={25} />
|
||||
</Group>
|
||||
<Box onClick={() => { onToChooseAnggota() }}>
|
||||
<Box onClick={() => { onToChooseAnggota() }} mt={15}>
|
||||
<Group
|
||||
justify="space-between"
|
||||
p={10}
|
||||
@@ -230,7 +237,7 @@ export default function CreateProject() {
|
||||
<IoIosArrowDropright size={25} />
|
||||
</Group>
|
||||
</Box>
|
||||
</Stack>
|
||||
</Box>
|
||||
<Box pb={100}>
|
||||
|
||||
{
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
"use client"
|
||||
import { LayoutNavbarNew, SkeletonSingle, TEMA } from '@/module/_global';
|
||||
import { LayoutNavbarNew, SkeletonList, SkeletonSingle, SkeletonUser, TEMA } from '@/module/_global';
|
||||
import { useHookstate } from '@hookstate/core';
|
||||
import { ActionIcon, Avatar, Box, Button, Center, Divider, Flex, Grid, Indicator, Input, rem, SimpleGrid, Skeleton, Stack, Text, TextInput } from '@mantine/core';
|
||||
import { useShallowEffect } from '@mantine/hooks';
|
||||
import { useMediaQuery, useShallowEffect } from '@mantine/hooks';
|
||||
import { useRouter } from 'next/navigation';
|
||||
import React, { useState } from 'react';
|
||||
import { HiChevronLeft, HiMagnifyingGlass } from 'react-icons/hi2';
|
||||
@@ -24,6 +24,7 @@ export default function CreateUsersProject({ grup, onClose }: { grup?: string, o
|
||||
const [openTugas, setOpenTugas] = useState(false)
|
||||
const [onClickSearch, setOnClickSearch] = useState(false)
|
||||
const tema = useHookstate(TEMA)
|
||||
const isMobile2 = useMediaQuery("(max-width: 438px)");
|
||||
|
||||
const handleFileClick = (index: number) => {
|
||||
if (selectedFiles.some((i: any) => i.idUser == dataMember[index].id)) {
|
||||
@@ -136,7 +137,7 @@ export default function CreateUsersProject({ grup, onClose }: { grup?: string, o
|
||||
borderBottom: `1px solid ${"#E0DFDF"}`
|
||||
}}>
|
||||
{selectedFiles.length > 0 ? (
|
||||
<Carousel dragFree slideGap={"xs"} align="start" slideSize={"xs"} withIndicators withControls={false}>
|
||||
<Carousel dragFree slideGap={"xs"} align="start" slideSize={"xs"} withControls={false}>
|
||||
{selectedFiles.map((v: any, i: any) => {
|
||||
return (
|
||||
<Carousel.Slide key={i}>
|
||||
@@ -175,35 +176,43 @@ export default function CreateUsersProject({ grup, onClose }: { grup?: string, o
|
||||
.fill(null)
|
||||
.map((_, i) => (
|
||||
<Box key={i}>
|
||||
<SkeletonSingle />
|
||||
<SkeletonList />
|
||||
</Box>
|
||||
))
|
||||
:
|
||||
dataMember.map((v, index) => {
|
||||
const isSelected = selectedFiles.some((i: any) => i.idUser == dataMember[index].id);
|
||||
return (
|
||||
<Box mb={15} key={index} onClick={() => handleFileClick(index)}>
|
||||
<Box mb={10} key={index} onClick={() => handleFileClick(index)}>
|
||||
<Grid align='center'>
|
||||
<Grid.Col span={{
|
||||
base: 3,
|
||||
xl: 2
|
||||
}}>
|
||||
<Grid.Col span={{
|
||||
base: 1,
|
||||
xs: 1,
|
||||
sm: 1,
|
||||
md: 1,
|
||||
lg: 1,
|
||||
xl: 1,
|
||||
}}>
|
||||
<Avatar src={`https://wibu-storage.wibudev.com/api/files/${v.img}`} alt="it's me" size="lg" />
|
||||
</Grid.Col>
|
||||
<Grid.Col span={{
|
||||
base: 9,
|
||||
xl: 10
|
||||
}}>
|
||||
base: 11,
|
||||
xs: 11,
|
||||
sm: 11,
|
||||
md: 11,
|
||||
lg: 11,
|
||||
xl: 11,
|
||||
}}>
|
||||
<Flex justify='space-between' align={"center"}>
|
||||
<Flex direction={'column'} align="flex-start" justify="flex-start">
|
||||
<Text lineClamp={1}>{v.name}</Text>
|
||||
<Text lineClamp={1} pl={isMobile2 ? 40 : 30}>{v.name}</Text>
|
||||
</Flex>
|
||||
{isSelected ? <FaCheck /> : null}
|
||||
</Flex>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<Box mt={10}>
|
||||
<Divider size={"xs"} />
|
||||
<Divider my={10} />
|
||||
</Box>
|
||||
</Box>
|
||||
);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
"use client"
|
||||
import { currentScroll, globalRole, TEMA, WARNA } from '@/module/_global';
|
||||
import { currentScroll, globalRole, SkeletonList, SkeletonUser, TEMA, WARNA } from '@/module/_global';
|
||||
import { ActionIcon, Avatar, Badge, Box, Card, Center, Divider, Flex, Grid, Group, Skeleton, Text, TextInput, Title } from '@mantine/core';
|
||||
import { useRouter, useSearchParams } from 'next/navigation';
|
||||
import React, { useEffect, useState } from 'react';
|
||||
@@ -123,86 +123,91 @@ export default function ListProject() {
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<Box pt={20}>
|
||||
{roleLogin.get() == 'supadmin' && <Text>Filter by: {nameGroup}</Text>}
|
||||
{loading ?
|
||||
<Box>
|
||||
<Skeleton width={"100%"} height={100} radius={"md"} />
|
||||
</Box>
|
||||
:
|
||||
<Box bg={tema.get().bgTotalKegiatan} p={10} style={{ borderRadius: 10 }}>
|
||||
<Text fw={'bold'} c={tema.get().utama}>Total Kegiatan</Text>
|
||||
<Flex justify={'center'} align={'center'} h={'100%'}>
|
||||
<Text fz={40} fw={'bold'} c={tema.get().utama}>{totalData}</Text>
|
||||
</Flex>
|
||||
</Box>
|
||||
}
|
||||
{roleLogin.get() == 'supadmin' && <Text mb={5}>Filter by: {nameGroup}</Text>}
|
||||
<Box bg={tema.get().bgTotalKegiatan} p={10} style={{ borderRadius: 10 }}>
|
||||
<Text fw={'bold'} c={tema.get().utama}>Total Kegiatan</Text>
|
||||
<Flex justify={'center'} align={'center'} h={'100%'}>
|
||||
<Text fz={40} fw={'bold'} c={tema.get().utama}>{totalData}</Text>
|
||||
</Flex>
|
||||
</Box>
|
||||
{isList ? (
|
||||
<Box pt={20}>
|
||||
{isData.map((v, i) => {
|
||||
return (
|
||||
<Box key={i}>
|
||||
<Grid align='center' onClick={() => router.push(`/project/${v.id}`)}>
|
||||
<Grid.Col span={{
|
||||
base: 1,
|
||||
xs: 1,
|
||||
sm: 1,
|
||||
md: 1,
|
||||
lg: 1,
|
||||
xl: 1
|
||||
}}>
|
||||
<Group >
|
||||
<Center>
|
||||
<ActionIcon
|
||||
variant="gradient"
|
||||
size={50}
|
||||
aria-label="Gradient action icon"
|
||||
radius={100}
|
||||
// gradient={{
|
||||
// from: '#DFDA7C',
|
||||
// to: '#F2AF46',
|
||||
// deg: 174
|
||||
// }}
|
||||
bg={tema.get().bgFiturHome}
|
||||
>
|
||||
<HiMiniPresentationChartBar size={25} color={tema.get().utama} />
|
||||
</ActionIcon>
|
||||
</Center>
|
||||
</Group>
|
||||
</Grid.Col>
|
||||
<Grid.Col span={{
|
||||
base: 11,
|
||||
xs: 11,
|
||||
sm: 11,
|
||||
md: 11,
|
||||
lg: 11,
|
||||
xl: 11,
|
||||
}}>
|
||||
<Group justify='space-between' align='center'>
|
||||
<Box>
|
||||
<Box w={{
|
||||
base: isMobile ? 200 : 230,
|
||||
xl: 430
|
||||
}}>
|
||||
<Text truncate="end" pl={paddingLift ? 30 : 20}>
|
||||
{v.title}
|
||||
</Text>
|
||||
</Box>
|
||||
|
||||
</Box>
|
||||
<RiCircleFill size={12} color={
|
||||
v.status === 0 ? '#1372C4' :
|
||||
v.status === 1 ? '#C5771A' :
|
||||
v.status === 2 ? '#0B6025' :
|
||||
v.status === 3 ? '#BB1F1F' :
|
||||
""
|
||||
} />
|
||||
</Group>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<Divider my="sm" />
|
||||
{loading ?
|
||||
Array(3)
|
||||
.fill(null)
|
||||
.map((_, i) => (
|
||||
<Box key={i}>
|
||||
<SkeletonList/>
|
||||
</Box>
|
||||
))
|
||||
:
|
||||
_.isEmpty(isData)
|
||||
?
|
||||
<Box style={{ display: 'flex', justifyContent: 'center', alignItems: 'center', height: '50vh' }}>
|
||||
<Text c="dimmed" ta={"center"} fs={"italic"}>Tidak ada Kegiatan</Text>
|
||||
</Box>
|
||||
);
|
||||
})}
|
||||
:
|
||||
isData.map((v, i) => {
|
||||
return (
|
||||
<Box key={i}>
|
||||
<Grid align='center' onClick={() => router.push(`/project/${v.id}`)}>
|
||||
<Grid.Col span={{
|
||||
base: 1,
|
||||
xs: 1,
|
||||
sm: 1,
|
||||
md: 1,
|
||||
lg: 1,
|
||||
xl: 1
|
||||
}}>
|
||||
<Group >
|
||||
<Center>
|
||||
<ActionIcon
|
||||
variant="gradient"
|
||||
size={50}
|
||||
aria-label="Gradient action icon"
|
||||
radius={100}
|
||||
bg={tema.get().bgFiturHome}
|
||||
>
|
||||
<HiMiniPresentationChartBar size={25} color={tema.get().utama} />
|
||||
</ActionIcon>
|
||||
</Center>
|
||||
</Group>
|
||||
</Grid.Col>
|
||||
<Grid.Col span={{
|
||||
base: 11,
|
||||
xs: 11,
|
||||
sm: 11,
|
||||
md: 11,
|
||||
lg: 11,
|
||||
xl: 11,
|
||||
}}>
|
||||
<Group justify='space-between' align='center'>
|
||||
<Box>
|
||||
<Box w={{
|
||||
base: isMobile ? 200 : 230,
|
||||
xl: 430
|
||||
}}>
|
||||
<Text truncate="end" pl={paddingLift ? 30 : 20}>
|
||||
{v.title}
|
||||
</Text>
|
||||
</Box>
|
||||
|
||||
</Box>
|
||||
<RiCircleFill size={12} color={
|
||||
v.status === 0 ? '#1372C4' :
|
||||
v.status === 1 ? '#C5771A' :
|
||||
v.status === 2 ? '#0B6025' :
|
||||
v.status === 3 ? '#BB1F1F' :
|
||||
""
|
||||
} />
|
||||
</Group>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
<Divider my="sm" />
|
||||
</Box>
|
||||
);
|
||||
})
|
||||
}
|
||||
</Box>
|
||||
) : (
|
||||
<Box pt={20}>
|
||||
|
||||
Reference in New Issue
Block a user