feat: slicing modal for backoffice 'validasi transaksi' page

- Tambah fungsi untuk handle aksi ketika button pada modal ditekan
This commit is contained in:
Hafid Nur
2025-03-31 21:40:00 +07:00
parent 3b979119ed
commit 989503f930
8 changed files with 255 additions and 136 deletions
@@ -4,13 +4,13 @@ import { Modal } from '@imphnen-frontend-service/ui/molecules';
interface IModalDeleteItem {
isOpen: boolean;
onClose: () => void;
onDeleteItem: () => void;
handleDeleteItem?: () => void;
}
const ModalDeleteItem = ({
isOpen,
onClose,
onDeleteItem,
handleDeleteItem,
}: IModalDeleteItem) => {
return (
<Modal
@@ -48,7 +48,9 @@ const ModalDeleteItem = ({
variant="danger"
size="lg"
className="w-full"
onClick={() => onDeleteItem()}
onClick={() => {
handleDeleteItem && handleDeleteItem();
}}
>
Hapus Item
</Button>