4 ms·
Random aside. Their code snippet has this comment: // popovers have light dismiss which influences our state And I hadn't heard of that phrase before! Tur
by lelandfe 2y ago
Random aside. Their code snippet has this comment:
// popovers have light dismiss which influences our state
And I hadn't heard of that phrase before! Turns out it means "clicking elsewhere closes the thing:"
> "Light dismiss" means that clicking outside of a popover whose `popover` attribute is in the auto state will close the popover.[0]
Like what, say, a `<select>` does when open.
Strikes this dev as a pretty unintuitive way to phrase that. At first I thought it was "light" as in "light DOM," but I guess it's "light" as an antonym of "explicit?" Looks like there was some back and forth on this, and it was even proposed as an attribute: https://github.com/openui/open-ui/issues/834 https://github.com/openui/open-ui/issues/834
[0] https://html.spec.whatwg.org/multipage/popover.html#popover-light-dismiss https://html.spec.whatwg.org/multipage/popover.html#popover-...
- Izkata 2y agoI think "light" is used as in "light touch" (soft touch), something that includes brushing against a surface by accident.
- efortis 2y agoI’d guess it stands for highlight. For example a modal is often highlighted by dimming and blurring the background.
- david422 2y agoAlso random aside. I dislike this pattern for modal dialogs. Often times I will need to gather information from somewhere else, and in the process of attempting to get focus back to the dialog I've touched/tapped/clicked on something that dismisses the dialog. Very annoying.
- victorbjorklund 2y agoMost of the times that would be better solved with not using a modal.
- dylan-m 2y agoI'm okay with modal dialogs working that way as long as people get the message: dialogs are supposed to be ephemeral. If closing the dialog loses important state, or you need information from something under the dialog in order to use the dialog, what you have shouldn't be a modal dialog. And you can tell, because in most UI frameworks that widget is just begging to be closed. Unfortunately, a lot of teams don't get the message.
- phatskat 2y agoI don’t say this often, but Jira got this correct. When you’re creating a new ticket, it’s done in a modal. But if you close it or click the “X”, it minimizes to the bottom of the page so that you can look at other tickets, or look up something relevant to the one you’re making. I’ve been trained that modals are ephemeral, and I have to take a sec of “ugh I have to close this to look stuff up…wait, no I don’t” when using Jira
- jazzyjackson 2y agoJust noticed this bug in Simplifi expense tracking web app. The drop down to update the category of a transaction has multiple levels (e.g. Business:Travel:Lodging) and as soon as I hover over a nested drop down the whole thing disappears.
- deleted 2y ago[deleted]
- bartkappenburg 2y agoLight is the opposite of hard (ie hard close). It makes more sense (to me!) to use explicit vs implicit close? Clicking outside the popover means an implicit close.
- deleted 2y ago[deleted]
- deleted 2y ago[deleted]
- hatthew 2y agoAnecdotally, when I read the first two lines of your comment I immediately thought "that probably means you can click elsewhere to close it"