160
rated 0 times
[
164]
[
4]
/ answers: 1 / hits: 12885
/ 3 Years ago, tue, august 3, 2021, 12:00:00
I want to change the 'title' color in SweetAlert2. How can I do that?
Thank you in advance
function CustomConfirm(title, message, type) {
return new Promise((resolve) => {
Swal.fire({
title: title,
text: message,
icon: type,
showCancelButton: true,
confirmButtonColor: '#d33',
cancelButtonColor: '#6e7d88',
confirmButtonText: 'Yes',
cancelButtonText: "No"
}).then((result) => {
if (result.isConfirmed) {
resolve(true);
} else {
resolve(false);
}
});
});
}
More From » sweetalert2