"use strict"; // Class definition var KTSweetAlert2Demo = function() { // Demos var initDemos = function() { // Sweetalert Demo 1 $('#kt_sweetalert_demo_1').click(function(e) { swal.fire('Good job!'); }); // Sweetalert Demo 2 $('#kt_sweetalert_demo_2').click(function(e) { swal.fire("Here's the title!", "...and here's the text!"); }); // Sweetalert Demo 3 $('#kt_sweetalert_demo_3_1').click(function(e) { swal.fire("Good job!", "You clicked the button!", "warning"); }); $('#kt_sweetalert_demo_3_2').click(function(e) { swal.fire("Good job!", "You clicked the button!", "error"); }); $('#kt_sweetalert_demo_3_3').click(function(e) { swal.fire("Good job!", "You clicked the button!", "success"); }); $('#kt_sweetalert_demo_3_4').click(function(e) { swal.fire("Good job!", "You clicked the button!", "info"); }); $('#kt_sweetalert_demo_3_5').click(function(e) { swal.fire("Good job!", "You clicked the button!", "question"); }); // Sweetalert Demo 4 $('#kt_sweetalert_demo_4').click(function(e) { swal.fire({ title: "Good job!", text: "You clicked the button!", type: "success", buttonsStyling: false, confirmButtonText: "Confirm me!", confirmButtonClass: "btn btn-brand" }); }); // Sweetalert Demo 5 $('#kt_sweetalert_demo_5').click(function(e) { swal.fire({ title: "Good job!", text: "You clicked the button!", type: "success", buttonsStyling: false, confirmButtonText: " I am game!", confirmButtonClass: "btn btn-danger", showCancelButton: true, cancelButtonText: " No, thanks", cancelButtonClass: "btn btn-default" }); }); $('#kt_sweetalert_demo_6').click(function(e) { swal.fire({ position: 'top-right', type: 'success', title: 'Your work has been saved', showConfirmButton: false, timer: 1500 }); }); $('#kt_sweetalert_demo_7').click(function(e) { swal.fire({ title: 'jQuery HTML example', html: $('