upd: task divisi
Deskripsi: - list task divisi - create task divisi - detail task divisi - tambah tugas task divisi - tambah file tasi divisi - edit task divisi - pembatalan task divisi No Issues
This commit is contained in:
70
components/task/headerTaskDetail.tsx
Normal file
70
components/task/headerTaskDetail.tsx
Normal file
@@ -0,0 +1,70 @@
|
||||
import Styles from "@/constants/Styles"
|
||||
import { AntDesign, MaterialCommunityIcons, MaterialIcons } from "@expo/vector-icons"
|
||||
import { useState } from "react"
|
||||
import { View } from "react-native"
|
||||
import ButtonMenuHeader from "../buttonMenuHeader"
|
||||
import DrawerBottom from "../drawerBottom"
|
||||
import MenuItemRow from "../menuItemRow"
|
||||
import { router } from "expo-router"
|
||||
|
||||
type Props = {
|
||||
id: string | string[]
|
||||
}
|
||||
|
||||
export default function HeaderRightTaskDetail({ id }: Props) {
|
||||
const [isVisible, setVisible] = useState(false)
|
||||
|
||||
return (
|
||||
<>
|
||||
<ButtonMenuHeader onPress={() => { setVisible(true) }} />
|
||||
<DrawerBottom animation="slide" isVisible={isVisible} setVisible={setVisible} title="Menu">
|
||||
<View style={Styles.rowItemsCenter}>
|
||||
<MenuItemRow
|
||||
icon={<AntDesign name="pluscircle" color="black" size={25} />}
|
||||
title="Tambah Tugas"
|
||||
onPress={() => {
|
||||
setVisible(false)
|
||||
router.push(`./${id}/add-task`)
|
||||
}}
|
||||
/>
|
||||
<MenuItemRow
|
||||
icon={<MaterialCommunityIcons name="file-plus" color="black" size={25} />}
|
||||
title="Tambah File"
|
||||
onPress={() => {
|
||||
setVisible(false)
|
||||
router.push(`./${id}/add-file`)
|
||||
}}
|
||||
/>
|
||||
|
||||
<MenuItemRow
|
||||
icon={<MaterialIcons name="groups" color="black" size={25} />}
|
||||
title="Tambah Anggota"
|
||||
onPress={() => {
|
||||
// setVisible(false)
|
||||
|
||||
}}
|
||||
/>
|
||||
|
||||
</View>
|
||||
<View style={[Styles.rowItemsCenter, Styles.mt15]}>
|
||||
<MenuItemRow
|
||||
icon={<MaterialCommunityIcons name="pencil-outline" color="black" size={25} />}
|
||||
title="Edit"
|
||||
onPress={() => {
|
||||
setVisible(false)
|
||||
router.push(`./${id}/edit`)
|
||||
}}
|
||||
/>
|
||||
<MenuItemRow
|
||||
icon={<MaterialIcons name="close" color="black" size={25} />}
|
||||
title="Batal"
|
||||
onPress={() => {
|
||||
setVisible(false)
|
||||
router.push(`./${id}/cancel`)
|
||||
}}
|
||||
/>
|
||||
</View>
|
||||
</DrawerBottom>
|
||||
</>
|
||||
)
|
||||
}
|
||||
Reference in New Issue
Block a user