Passage sur SweetAlert2 car maintenu + ajout d'une image dans la popup mail

This commit is contained in:
Anthony Dumas 2019-03-24 01:03:46 +01:00
parent 27cb219db0
commit d3f3f1b873
4 changed files with 18 additions and 10 deletions

View File

@ -4,9 +4,13 @@ $btnMail.removeAttr("disabled");
$btnMail.click(function (evt) {
evt.preventDefault();
swal({
text: "anthony@dumas.cc",
icon: "info",
button: true,
});
Swal.fire({
title: 'Email',
html: "Vous pouvez m'envoyer un mail à <strong>anthony@dumas.cc</strong> !",
imageUrl: './images/mail.jpg',
imageWidth: 400,
imageHeight: 200,
imageAlt: 'Custom image',
animation: false
})
});

BIN
images/mail.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 57 KiB

View File

@ -249,7 +249,7 @@
</footer>
<script type="text/javascript" src="node_modules/jquery/dist/jquery.min.js"></script>
<script type="text/javascript" src="lib/main.js"></script>
<script src="https://unpkg.com/sweetalert/dist/sweetalert.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@8"></script>
</body>
</html>

View File

@ -6,9 +6,13 @@ $btnMail.removeAttr("disabled");
$btnMail.click(function (evt) {
evt.preventDefault();
swal({
text: "anthony@dumas.cc",
icon: "info",
button: true
Swal.fire({
title: 'Email',
html: "Vous pouvez m'envoyer un mail à <strong>anthony@dumas.cc</strong> !",
imageUrl: './images/mail.jpg',
imageWidth: 400,
imageHeight: 200,
imageAlt: 'Custom image',
animation: false
});
});