Files
mobile-darmasaba/components/modalSelect.tsx
amel e8ec2278d3 upd: list anggota
Deskripsi:
- ui list anggota

- note : blm selesai

No Issues
2025-02-28 17:22:02 +08:00

42 lines
1.4 KiB
TypeScript

import { Pressable, Text, View } from "react-native"
import DrawerBottom from "./drawerBottom"
import Styles from "@/constants/Styles"
import { AntDesign } from "@expo/vector-icons"
import { useState } from "react"
type Props = {
open: boolean
close: (value: boolean) => void
title: string
category: 'group'
choose: string
onSelect: (value: { val: string, label: string }) => void
}
export default function ModalSelect({ open, close, title, category, choose, onSelect }: Props) {
const [isChoose, setChoose] = useState(choose)
return (
<DrawerBottom animation="none" isVisible={open} setVisible={close} title={title} height={75}>
<View>
<Pressable style={[Styles.itemSelectModal]} onPressOut={() => {
onSelect({ val: 'dinas', label: 'Dinas' })
setChoose('dinas')
close(false)
}}>
<Text style={[Styles.textDefaultSemiBold]}>Dinas</Text>
<AntDesign name="check" size={20} />
</Pressable>
<Pressable style={[Styles.itemSelectModal]}>
<Text>Adat</Text>
</Pressable>
<Pressable style={[Styles.itemSelectModal]}>
<Text>Karang Taruna</Text>
</Pressable>
<Pressable style={[Styles.itemSelectModal]}>
<Text>PKK</Text>
</Pressable>
</View>
</DrawerBottom>
)
}