Should a Dialog Close When Clicked Outside? 0 ▲ Adrian Roselli 1 hour ago · Tech · hide · 0 comments Maybe not, but I’ll break these down into three categories because it depends on context and intent. Pretend this post also applies for pressing Esc. Action Required If the user must complete a task that is presented by the dialog, then they should not be able to close it without completing that task — accidentally or not. Which means it’s probably a modal dialog, otherwise the user could still interact with the underlying page and avoid doing the task. It also probably has no close button, since the user could then avoid doing the task. It also probably won’t close when pressing Esc, since (say it with me) the user could then avoid doing the task. Possible cases where a user must complete a task before the dialog goes away: agreeing to a legal thing, acknowledging a thing might cause harm / kill you / summon Chet, logging in from within a protected page. In some cases consider if you’re better off making a standalone page instead of using a modal dialog. Particularly if there is any… No comments yet. Log in to reply on the Fediverse. Comments will appear here.