Upgrade to Pro — share decks privately, control downloads, hide ads and more …

TIL about showModal (from small things big things one day come)

TIL about showModal (from small things big things one day come)

modal dialogs:
- the `dialog` element, its `open` attribute and its `showModal` and `close` methods
- the `inert` attribute
- a lightbox implemented as progressive enhancement

links to resources and codepens at https://noti.st/gunnarbittersmann/GBW9Pt/til-about-showmodal-from-small-things-big-things-one-day-come

Gunnar Bittersmann

January 13, 2023
Tweet

More Decks by Gunnar Bittersmann

Other Decks in Programming

Transcript

  1. dialog The dialog element represents a part of an application

    that a user interacts with to perform a task, for example a dialog box, inspector, or window.
  2. inert The inert attribute is a boolean attribute that indicates,

    by its presence, that the element and all its fl at tree descendants which don’t otherwise escape inertness (such as modal dialogs) are to be made inert by the user agent.