module shop, flash message

This commit is contained in:
2024-10-16 17:54:33 +03:00
parent 209b1e3f29
commit 9af44ca95f
12 changed files with 137 additions and 54 deletions

View File

@ -16,8 +16,20 @@
$('#sidebar').toggleClass('active');
});
$("#closeAlertBtn").click(function () {
$("#mainAlert").alert("close");
});
// $(".closeAlertBtn").click(function () {
// console.log($(this).parentNode)
// $(this).parentElement.alert("close");
// });
})(jQuery);
window.addEventListener("load", function () {
let closeBtn = document.querySelectorAll(".closeAlertBtn");
closeBtn.forEach((item) => {
item.addEventListener("click", closeAlert);
});
});
function closeAlert() {
this.parentNode.setAttribute("style", "display: none;")
}