Confirm User Intentions With A Beautiful Confirmation Dialog

Category: Javascript , Modal & Popup | January 13, 2022
Views Total:719 views
Official Page:Go to website
Last Update:January 13, 2022


Confirm User Intentions With A Beautiful Confirmation Dialog


Just another confirmation dialog popup library used to confirm user intentions on the web app.

How to use it:

1. Add the stylesheet ConfirmDialogue.css and JavaScript ConfirmDialogue.js to the webpage.

<link rel="stylesheet" href="ConfirmDialogue.css" />
<script src="ConfirmDialogue.js"></script>

2. Create a new confirmation dialog with the following parameters:

  • trueButtonText: Confirm button text
  • falseButtonText: Refuse button text
  • cancelButtonText: Cancel button text
  • messageText: Confirm messages
  • titleText: Confirm title
const dialogue = new ConfirmDialogue({
      trueButtonText: "Yes",
      falseButtonText: "No",
      cancelButtonText: 'Cancel',
      messageText: "This one has another option, the cancel option for when you dont want to do anything",
      titleText: "More Buttons"

3. Do something if confirmed.

if (await dialogue.respond()) {
  alert('You pressed yes');
} else {
  alert('You pressed no');



  • JS & CSS updated

You Might Be Interested In:

Leave a Reply