Skip to content

[PB-7135]: feat/implement delete confirmation dialog for entities - #179

Open
jzunigax2 wants to merge 2 commits into
mainfrom
feat/delete-confirmation
Open

jzunigax2 wants to merge 2 commits into
mainfrom
feat/delete-confirmation

Conversation

@jzunigax2

Copy link
Copy Markdown
Contributor

Depends on https://github.com/internxt/object-storage-server/pull/253

What

Delete confirmation for subaccounts, partners and wholesalers in the partner, wholesaler and management panels. Before deleting, the user has to type the entity's exact name and enter a 2FA code. One shared dialog with the same steps and messages in all three panels.

How

  • New DeleteConfirmationDialog: checks the caller's 2FA status when it opens, then asks for the name (case-sensitive, trimmed), then the 6-digit code. Nothing is sent until the final Confirm. Cancel or close at any step sends nothing.
  • Users without 2FA see an "enable 2FA first" message with a link to their settings, and no delete button.
  • Errors from the API change the dialog step: wrong code stays on the code step, a lockout shows the unlock time, a name mismatch goes back to the name step, and anything else shows a generic error and closes.
  • Sub-accounts with no name use their email as the value to type.
  • Replaces the old delete confirm modals in all six places a delete can start.

- Introduced DeleteConfirmationDialog component to handle deletion confirmations for various entities.
- Added utility functions for name matching and generating deletion messages.
- Updated management and partners services to support deletion with two-factor authentication.
- Refactored existing components to utilize the new delete confirmation flow, enhancing user experience and security.
- Added unit tests for new functionalities to ensure reliability and correctness.
@jzunigax2
jzunigax2 requested a review from sg-gs November 18, 2026 21:10
@jzunigax2 jzunigax2 self-assigned this Nov 18, 2026
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
object-storage-management-web 3deb5bf Commit Preview URL

Branch Preview URL
Nov 19 2026, 02:11 PM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant