4 min readUpdated Mar 2, 2026

DeleteWorkflowModal Documentation

Purpose

The DeleteWorkflowModal component is designed to prompt users with a confirmation dialog before permanently deleting a workflow within the Vantage analytics platform. This modal reinforces the gravity of the action by ensuring that users explicitly confirm their intention to delete the workflow, as this action cannot be undone. It facilitates data integrity by preventing accidental deletions and enhances user experience by providing a clear, interactive interface for critical actions.

How It Works

The component uses the BaseModal component as its foundation, allowing for a flexible modal dialog structure. It requires two key props: onClose and onDelete. When the user clicks the 'Delete' button, the onDelete function is invoked to process the deletion of the workflow, followed by closing the modal. The modal also features a cancellation option which allows users to back out of the deletion if accidentally accessed.

Settings

1. title

2. onClose

3. onDelete

4. footer

5. closeOnBackdropClick

Use Cases & Examples

Use Cases

  1. User Interface Consistency: In large applications, maintaining a consistent user experience when performing destructive actions such as deletions is critical. The DeleteWorkflowModal ensures users are prompted consistently, reducing the chance of errors.

  2. Workflow Management: Organizations often need to delete outdated or unnecessary workflows from their systems. This modal provides a dedicated interface for performing this task safely.

  3. Preventing Data Loss: Accidental deletions are a common issue. By incorporating a modal confirmation, users are given an opportunity to rethink their actions and minimize the risk of important data loss.

Example Configuration

Suppose an organization wants to configure the DeleteWorkflowModal to delete a workflow named "Monthly Report Generation". Here’s how it might be set up:

javascript
function handleDelete() {
    // Logic to delete the workflow
}

function handleClose() {
    // Logic to close the modal, e.g., updating state to hide modal
}

// Usage of the DeleteWorkflow Modal
<DeleteWorkflowModal
    onClose={handleClose}
    onDelete={handleDelete}
/>

In this configuration:

By utilizing the DeleteWorkflowModal in this way, users are provided with a clear, accessible method to manage their workflows effectively while minimizing the risks associated with irreversible actions.