Closed xscottxbrownx closed 10 months ago
Outside of the minor comment on the JSDoc, the PR changes here works as intended. Think I can approve this.
updated!
Got rid of confirmButtonText
attribute/prop in ConfirmationModal
as it was always the same as the title
text.
Creates confirmation modal when need to double-check with user
This PR:
Resolves #316
1. Changes
window.confirm
(Issue-316) when deleting a document to a modal 2. ReplacesLogoutModal
,DeleteContactModal
, and this "DeleteDocument" with this single reusable modal 3. Adds theuseNotification
hook to thehooks
index for easy importingThe files this PR effects:
Components
ConfirmationModal.jsx
Contacts.jsx
DeleteContactModal.jsx
DocumentTable.jsx
DocumentTableRow.jsx
LogoutModal.jsx
Navbar.jsx
Profile.jsx
Tests
DeleteContactModal.test.jsx
Other Files
hooks/index.js
modals/index.js
Screenshots (if applicable):
https://github.com/codeforpdx/PASS/assets/71395931/d13ae324-a43e-4e36-bbec-59aed73fc548
Additional Context (optional):
Was going to just create a new modal to delete document (replacing the window.confirm), and realized all these separate modals do the same thing - basically ask the user if they are sure and want to continue with the action.