From 8caa2bc1439bd605dd1e4956abd0534a69fc82ba Mon Sep 17 00:00:00 2001 From: bazz Date: Tue, 15 Nov 2022 13:03:14 +0100 Subject: [PATCH] Add Modal --- src/App.jsx | 22 ++++++---------------- src/App/component/Dialog.jsx | 22 ++++++++++++++++++---- 2 files changed, 24 insertions(+), 20 deletions(-) diff --git a/src/App.jsx b/src/App.jsx index e45b27b..38ace8e 100644 --- a/src/App.jsx +++ b/src/App.jsx @@ -16,17 +16,17 @@ function App() { const modal = useRef(); function handleModal() { - DOMMethods.showModal(modal.current) + modal.current.showModal() } function handleClose() { - DOMMethods.closeModal(modal.current) + modal.current.close() } return ( <> -