mozilla / pontoon

Mozilla's Localization Platform
https://pontoon.mozilla.org
BSD 3-Clause "New" or "Revised" License
1.46k stars 528 forks source link

Naming the dialog-y panel-y pop-up-y things in code #2523

Open eemeli opened 2 years ago

eemeli commented 2 years ago

As identified in https://github.com/mozilla/pontoon/pull/2513#discussion_r867823082, the codebase needs a generic name for UI boxes that are (usually) opened by clicking on a thing. Ideas floated so far include "popup", "panel", and "dialog".

keunes commented 2 years ago

'modal'?

flodolo commented 2 years ago

A modal is a dialog which requires interaction and blocks the user, which is not the case here (if I understand correctly).

eemeli commented 2 years ago

Some examples of the things this is talking about:

That's probably not an exhaustive list, but it does include stuff that is very drop-down-menu-like, and stuff that's purely informative, and things in between with various levels of interaction.

All of those share some characteristics though:

While we could split this list into two or three categories and call them different things in the code, that feels a bit artificial to me. Hence when needing to use some term, I initially defaulted to "dialog" as it seemed sufficiently inclusive and not misleading. Something like "popup" could work as well, but I'd prefer to avoid "panel", as that sounds like it would be a part of the normal UI flow.