Summary
We'll need some sort of generic dropdown menu component. Think of Bootstrap's Dropdown component, or even the ones here in GitHub:
| Example |
 |
Implementation suggestions
- Should be implemented as a generic component under
src/shared/
- Component itself should only be worried about positioning itself and rendering the
children it receives, logic and state handling regarding visibility toggling can be handled in a separate component (so it can be used with the existing Button component, for example)
- Considering all the edge-cases that exist, it might be a good idea to use an existing library to handle the positioning logic. I suggest Popper.js.
- Don't worry too much about styling. As long as it vaguely fits with the rest of the system, we can adjust down the line if necessary.