24 lines
733 B
HTML
24 lines
733 B
HTML
<script src="/pagefind/pagefind-ui.js"></script>
|
|
<script src="/js/main.js"></script>
|
|
<script>
|
|
window.addEventListener("DOMContentLoaded", (event) => {
|
|
new PagefindUI({ element: "#search", showSubResults: true,highlightParam: "highlight" });
|
|
});
|
|
</script>
|
|
|
|
<script>
|
|
const dialog = document.querySelector("dialog");
|
|
const showButton = document.getElementById("createStoryBtn");
|
|
const closeButton = document.getElementById("closeStoryModal");
|
|
|
|
// "Show the dialog" button opens the dialog modally
|
|
showButton.addEventListener("click", () => {
|
|
dialog.showModal();
|
|
});
|
|
|
|
// "Close" button closes the dialog
|
|
closeButton.addEventListener("click", () => {
|
|
dialog.close();
|
|
});
|
|
</script>
|