Here is an example snippet of HTML code that showcases a SweetAlert2 date picker popup for a button titled "Click me!":
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap/dist/css/bootstrap.min.css" integrity="sha384-rbsA2VBKQhggwzxH7pPCaAqO46MgnOM80zW1RWuH61DGLwZJEdK2Kadq2F9CUG65" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/datepicker-bs5/dist/css/datepicker-bs5.min.css">
<link rel="stylesheet" type="text/css" href="https://unpkg.com/notie/dist/notie.min.css">
<style>
.my-footer {
background-color: #163b65;
color: #ffffff;
margin-top: 1.5em;
height: 5em;
padding: 1em;
font-size: 80%;
}
.room-image {
max-width: 50%;
}
.redText {
color: red;
}
.notie-container {
box-shadow: none;
}
.swal2-confirm {
z-index: -1;
}
.swal2-deny {
z-index: -1;
}
.date-picker-modal {
z-index: 10000;
}
</style>
<!-- Other things -->
<title>My nice page</title>
</head>
<body>
<!-- Navbar and other contents -->
<!-- Various scripts -->
<script src="https://cdn.jsdelivr.net/npm/bootstrap/dist/js/bootstrap.bundle.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/datepicker-full.min.js"></script>
<script src="https://unpkg.com/notie"></script>
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
<!-- Additional JavaScript code section -->
</body>
</html>
There seems to be an issue where the "OK" and "Cancel" buttons are obstructing the vanillajs-datepicker. You've tried adjusting the z-index, but it doesn't seem to be effective.
https://i.sstatic.net/6QsAg.png
Have you considered revisiting the implementation of the date picker to address this issue?
UPDATE:
After reviewing Limon's code example, it appears that the problem may be related to the usage of the "await" keyword. When utilized, the date picker is still being obstructed by the button. Further investigation is required to resolve this issue.