modal dialog without JS

The command and commandfor attributes enable you to open and close modal dialogs without JavaScript.
<button commandfor="my-modal" command="show-modal" aria-haspopup="dialog">
  Login
</button>

<dialog id="my-modal" closedby="any">
  <button command="close" commandfor="my-modal">close</button>

  <h1>Login</h1>
</dialog>