Salla Docs
Merchant
Merchant
  • Merchant API
  • Salla OAuth 2.0
  • Merchant Dashboard
Partner APIs
Partner APIs
  • App API
  • Shipments & Fulfillment APIs
  • Salla AWB
  • Recurring Payments API
  • App Functions
  • Billing System Salla partners
Storefront
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Ecommerce Events
  • Change Log
Salla CLI
Merchant
Merchant
  • Merchant API
  • Salla OAuth 2.0
  • Merchant Dashboard
Partner APIs
Partner APIs
  • App API
  • Shipments & Fulfillment APIs
  • Salla AWB
  • Recurring Payments API
  • App Functions
  • Billing System Salla partners
Storefront
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Ecommerce Events
  • Change Log
Salla CLI
Salla - Opensource
Salla - Developers Community
  1. UI Module
  • Embedded SDK
    • Overview
    • Getting Started
    • Installation
    • Authentication
    • App Design Guidelines
    • Create an Embedded App
    • Playground
  • Auth Module
    • Get Token
    • Client Introspect
    • Refresh Token
  • Page Module
    • Iframe Resizing
    • External Redirects
    • Navigation
    • Set Page Title
    • UI Module
      • Confirm Dialogs
      • Toast Notifications
      • Loading States
  • Nav Module
    • Create Navbar Action
    • Listen for Nav Actions
    • Clearing Nav Actions
  • Endpoints
    • Token Introspect
      POST
  • Resources
    • Support
Merchant
Merchant
  • Merchant API
  • Salla OAuth 2.0
  • Merchant Dashboard
Partner APIs
Partner APIs
  • App API
  • Shipments & Fulfillment APIs
  • Salla AWB
  • Recurring Payments API
  • App Functions
  • Billing System Salla partners
Storefront
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Ecommerce Events
  • Change Log
Salla CLI
Merchant
Merchant
  • Merchant API
  • Salla OAuth 2.0
  • Merchant Dashboard
Partner APIs
Partner APIs
  • App API
  • Shipments & Fulfillment APIs
  • Salla AWB
  • Recurring Payments API
  • App Functions
  • Billing System Salla partners
Storefront
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Ecommerce Events
  • Change Log
Salla CLI
Salla - Opensource
Salla - Developers Community
  1. UI Module

Confirm Dialogs

Confirm dialogs are used to interrupt the user and require an explicit "Confirm" or "Cancel" action. These are essential for destructive actions like deletions or major configuration changes.

Usage#

Unlike toasts, embedded.ui.confirm returns a Promise that resolves with the user's choice.

Options#

The confirm method accepts a configuration object:
OptionTypeDefaultDescription
titlestring-The title of the dialog.
messagestring-The body text explaining the action.
confirmTextstring"Confirm"Text for the confirmation button.
cancelTextstring"Cancel"Text for the cancellation button.
variantstring"info"Visual style: "info", "warning", or "danger".

Return Value#

The method returns a Promise<ConfirmResult>:
💡
Best Practices
Use Danger Variant for Deletions: Always use variant: "danger" for destructive actions to visually warn the user.
Clear Consequences: The message should clearly state what will happen if the user confirms.
Keep it Action-Oriented: Use button text like "Save Changes" or "Delete" instead of just "Yes" or "No".
Modified at 2026-02-02 10:34:37
Previous
UI Module
Next
Toast Notifications