Dialog

Invisible

I'm not visible

Visible

Now I'm visible

Close a dialog without JavaScript

I'm a dialog. Close me using the button below.

Opening and closing without JavaScript

Open dialog

Dialog

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.

Close

Or, use some dead-simple JS calls to do the same in a saner way 🤷‍♂️

Dialog

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.

And yes, you can customize it

Custom Dialog

This is a fancy dialog box!

Index
Source: https://github.com/DBozhinovski/neat-html-tricks-demo/blob/master/src/pages/dialog.astro