Modal vs Drawer
Both are panels that cover part of the screen. A modal pops up in the middle and says 'do this first', while a drawer slides in from the side to show a menu or settings.
Modal (Popup)
A box that pops up in the middle of the screen. Everything behind it is dimmed and blocked.
Drawer
A panel that slides in from the side (or bottom) of the screen.
At a glance
| Modal (Popup) | Drawer | |
|---|---|---|
| Where it appears | Middle of the screen | Side or bottom of the screen |
| Feeling | 'Wait! Do this first' | 'Pull it out when you need it' |
| Good for | Confirmations, short inputs | Menus, filters, carts |
| Size | Small, focused box | Tall panel |
Use “Modal (Popup)” when…
- When you need an answer, like confirming a delete
- For short inputs like logging in or paying
- To show a photo in a bigger size
🤖 Say it to your AI like this
When someone clicks the 'Delete' button, open a modal in the middle of the screen. Dim the background, and add the text 'Are you sure you want to delete this?' with [Cancel] [Delete] buttons. Close it when they click outside it or press ESC.
Use “Drawer” when…
- To show the menu list on phones
- For things you browse while choosing, like a cart or filters
- When you don't want to fully cover the main content
🤖 Say it to your AI like this
On phone screens, when someone taps the hamburger button, slide a drawer menu in from the left. Make it 80% of the screen width, dim the background slightly, and close it when they tap outside it.
💡 How not to mix them up
If you just say 'popup', the AI may build either one. Say 'modal' for the middle, or 'drawer' for one that slides in from the side.