all crud ops

This commit is contained in:
null
2024-02-27 17:54:36 +01:00
parent 741979aee5
commit 99b78c9bd1
7 changed files with 185 additions and 55 deletions
+19
View File
@@ -0,0 +1,19 @@
document.addEventListener('DOMContentLoaded', documentReady, false);
window.onmessage = (event) => {
if (event.data == "close") {
document.querySelector("dialog[open]").close();
}
}
function documentReady() {
const iframe = document.querySelector("iframe");
iframe.onload=(event) => {
const openDialog = document.querySelector("dialog[open]");
if (openDialog) {
openDialog.close();
window.location.reload();
} else {
document.querySelector("dialog").showModal()
}
}
}