mirror of
https://github.com/SerenityOS/serenity
synced 2026-05-14 10:56:35 +02:00
Adds the :modal pseudo class which matches dialogs opened with showModal(). (cherry picked from commit 63a5ff70e5f3bee10839415885a158e304719fec)
16 lines
284 B
HTML
16 lines
284 B
HTML
<style>
|
|
:modal {
|
|
display: flex;
|
|
}
|
|
</style>
|
|
|
|
<dialog id="modal">
|
|
<span>I'm a node</span>
|
|
</dialog>
|
|
|
|
<script>
|
|
document.addEventListener("DOMContentLoaded", () => {
|
|
let modal = document.getElementById('modal');
|
|
modal.showModal();
|
|
});
|
|
</script> |