Modal dialogs

Give a link an [up-layer=new] attribute to extract a CSS selector from the destination and open the fragment in a modal dialog. No server-side changes required.

preview.html
<main>

  <p>Story summary</p>

  <a href="/?originalUrl=https%3A%2F%2Funpoly.com%2F%26quot%3Bfull.html%26quot%3B%2520up-layer%3D%26quot%3Bnew%26quot%3B%26gt%3B%2520%2520%2520%2520Read%2520full%2520story%2520%2520%26lt%3B%2Fa%26gt%3B%26lt%3B%2Fmain%26gt%3B%253C%2Fcode">
full.html
<main>

  <h2>Full story</h2>

  <p>Lorem ipsum dolor sit amet.</p>

</main>