HTML: Dialog (modal)
A short, tested HTML example for dialog (modal). Copy it and adjust the names and paths for your project.
HTML
<dialog id="d">
<p>Are you sure?</p>
<form method="dialog"><button>OK</button></form>
</dialog>
<button onclick="document.getElementById('d').showModal()">Open</button>Find it in Zest
Search for “html dialog (modal)” in Zest and this example appears above the results, with other matches to choose from. Searches stay private.