confirmDialog (deprecated)
confirmDialog()
is considered deprecated
Support for the confirmDialog()
dialogs may be dropped in future versions of the JourneyApps Runtime. Please upgrade your app to use journey.dialog.confirm
to ensure that your app remains compatible with the JourneyApps Runtime.
To display a confirmation dialog to the user, use the confirmDialog()
built-in JourneyApps function in your JavaScript/TypeScript.
Simple Confirm Dialog
The simplest case of using confirmDialog()
is simply to provide the message shown in the dialog, and the return value of confirmDialog()
indicates whether the user pressed "OK" or "Cancel"
Confirm Dialog with a Title
To display a dialog with a title and message, provide two arguments to confirmDialog()
. The first parameter is the title, the second is the message. The return value of confirmDialog()
indicates whether the user pressed "OK" or "Cancel"
Customizing the Button Text
The default "OK" and "Cancel" buttons can be customized by providing two additional arguments to confirmDialog()
Customizing the button color
To customize the button color, specify an object with text
and color
as fields instead of a string with the button's text.
Last updated