Patterns / URL-as-state deep-linkable dialog
URL-as-state deep-linkable dialog.
Dialogs whose open/closed state lives in the URL via replaceState. Shareable, back-button-correct, refresh-survivable. Used for transaction detail, card detail, edit drawers.
Open the dialog. Notice the URL gains ?demo-detail=open. Refresh — it
reopens. Hit back — it closes. Right-click → copy link — share that URL with anyone,
the dialog opens for them too.
URL
(loading)