A couple CSS tricks for HTML Dialog elements

January 17, 2025

I recently was messing around with the HTML element. It’s really handy for native dialogs without a ton of JavaScript.

If you want to see a decent quick example of them in action, you can check out my game Jumblie and click the Settings gear button at the top.

Anyway! There’s a couple tricks that you might find handy when you’re implementing your own s on your websites!

Source: A couple CSS tricks for HTML Dialog elements

HTNL Dialogs and the popover API are the sort of thing. a lot of developers want to see from the Web platform. Common UI patterns that have been built over and over again, in countless frameworks, usually less than perfectly from a UX and accessibility perspective, now done right in the browser.

But which allow us to still customise the UI.

Here Cassidy Williams looks at customising HTML Dialogs with CSS to add a little something extra.