From 92bcdcd953ccd285548196ddef49a106678e6942 Mon Sep 17 00:00:00 2001
From: Danny White <3104761+dnywh@users.noreply.github.com>
Date: Wed, 11 Feb 2026 16:40:33 +1100
Subject: [PATCH] Update delete-organization dialog to TextConfirmModal
(#42670)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
## What kind of change does this PR introduce?
- ~Feat~ Chore
- Resolves DEPR-33
## What is the current behavior?
The dialog used to delete an organization uses a ”type this org’s name
in before you can press this button” interaction but:
- A) Enables the button the whole time
- B) We already have this componentized in TextConfirmModal
## What is the new behavior?
- Refactored this dialog to use `TextConfirmModal` instead
- Updated design docs to make this prop clearer
| Before | After |
| --- | --- |
| |
|
## Summary by CodeRabbit
* **Documentation**
* Updated Text Confirm Dialog documentation with clarifications: the
confirm action remains disabled until input exactly matches the required
string, and leading/trailing whitespace is trimmed from the input.
* **Refactor**
* Streamlined the organization deletion confirmation workflow for
improved user experience.
---
.../docs/fragments/text-confirm-dialog.mdx | 2 +-
.../content/docs/ui-patterns/modality.mdx | 2 +-
.../DeleteOrganizationButton.tsx | 98 +++++--------------
3 files changed, 26 insertions(+), 76 deletions(-)
diff --git a/apps/design-system/content/docs/fragments/text-confirm-dialog.mdx b/apps/design-system/content/docs/fragments/text-confirm-dialog.mdx
index 4b812ead978..12f90b69c7a 100644
--- a/apps/design-system/content/docs/fragments/text-confirm-dialog.mdx
+++ b/apps/design-system/content/docs/fragments/text-confirm-dialog.mdx
@@ -53,7 +53,7 @@ export default function TextConfirmDialogDemo() {
## Props
-- `confirmString`: The exact string the user must type to enable the confirm action
+- `confirmString`: The exact string the user must type to enable the confirm action (leading/trailing whitespace is trimmed)
- `confirmPlaceholder`: Placeholder text shown in the confirmation input
- `variant`: Visual intent of the dialog (`default`, `destructive`, or `warning`)
- Other standard modal props inherited from the underlying [Dialog](../components/dialog) component
diff --git a/apps/design-system/content/docs/ui-patterns/modality.mdx b/apps/design-system/content/docs/ui-patterns/modality.mdx
index 3da04913adf..3f593a0eb8e 100644
--- a/apps/design-system/content/docs/ui-patterns/modality.mdx
+++ b/apps/design-system/content/docs/ui-patterns/modality.mdx
@@ -43,7 +43,7 @@ There are quite a few dialog components, each suited to a different task or cont
#### Text Confirm Dialog
-[Text Confirm Dialog](../fragments/text-confirm-dialog) adds a deliberate speed bump for highly destructive actions by requiring the user to type an exact confirmation string before proceeding.
+[Text Confirm Dialog](../fragments/text-confirm-dialog) adds a deliberate speed bump for highly destructive actions by requiring the user to type an exact confirmation string before proceeding. The confirm action remains disabled until the input matches.
+ This action cannot be undone. This will + permanently delete the {orgName} organization and + remove all of its projects. +
+ > ) }