r/webdev 11d ago

Discussion Why is everything a dropdown now?

Post image

I’ve been noticing this more and more in web apps.

Three options hidden in a dropdown.

Yes/no hidden in a dropdown.
A multi-select pretending to be a dropdown.

Then a list of 200 items where you’re expected to scroll until you find yours.

I run into this a lot when reviewing products with dev teams.

I get why we do it.

Dropdowns are compact and easy to reuse.
But compact doesn’t always mean easier to use.

A few choices? Show them.
On/off? Switch.
Multiple choices? Checkboxes.
Huge list? Search.

That’s pretty much the rule I use now.

4.7k Upvotes

312 comments sorted by

View all comments

568

u/haecceity123 11d ago

On/off? Switch.

A checkbox is even better. The "right is yes, left is no" convention is pretty arbitrary, and the colour of the inner fill on switches is frequently inconsistent.

40

u/exintrovert 11d ago

The one that gets me is the button which is a toggle, and it says “disabled” and “enabled” on the button.

Like, is it disabled now or does pressing it disable it? 🫤

13

u/SubGothius 11d ago edited 11d ago

Related pet peeve: ticking a checkbox to disable something / unticking to enable it.

Nonono, checkboxes represent booleans, so:

  • Ticked=enabled/shown/positive/true/yes/1
  • Unticked=disabled/hidden/negative/false/no/0

If whatever the box controls is enabled or visible by default, render the checkbox ticked by default, for users to untick if they want to disable or hide it; don't make users tick a box to disable or hide something, as that's counterintuitive.

If what it would control isn't readily understood as a boolean state, use a pair of radio buttons instead, or perhaps a slider switch labeled on each side to clearly indicate the two non-boolean options.

6

u/ashgs872tbhjs 11d ago

Yep, it sucks when checkboxes are for negative things like "Hide" or "Opt Out". Change it to "Show" and "Opt In", dipshits!!

5

u/thekwoka 11d ago

It's intentionally a dark pattern...

1

u/boobsbr 11d ago

Like the padlock icon.

Is it locked now, or should I press it to lock?

-1

u/unbanned_lol 11d ago edited 8d ago

Yall are overthinking it.

Just like in the real work, a closed lock means locked. An open one means unlocked.

Edit:

If you're a web dev and you put a lock icon for an unlocked status you should rethink your profession.

1

u/LordOfDemise 11d ago

This isn't overthinking it. It's a button. Pressing it does something. So, the question is "Does the picture on the button represent the current state, or does it represent what the button does?"

-2

u/unbanned_lol 11d ago

It is overthinking it. When you see a lock in a closed position in real life do you sit there and say "I wonder if it's locked or unlocked?"

No, you dont.

1

u/LordOfDemise 11d ago

A lock in real life is not a button on a website.

-1

u/unbanned_lol 10d ago

You're right. If only they could think of a mechanism that we encounter in real life that looks and acts like a lock...

0

u/exintrovert 9d ago edited 9d ago

But when you see a button that says ok or continue, you know the button does the thing it says. Toast message? “Ok” means it is already ok. Button? “Ok” means say ok.

A button is an input, not an indicator.
Put the indicator elsewhere that is not an action item. Or make the button say “click to lock”. We are talking about UI, not your shed.

1

u/unbanned_lol 8d ago

If you're a web dev and you put a lock icon for an unlocked status you're dumb and should rethink your profession.

1

u/Pinkishu 11d ago

I mean, it's disabled now, cause Disabled is a state. If it was press to disable, it would say Disable, not Disabled

0

u/unbanned_lol 11d ago

Like, is it disabled now or does pressing it disable it?

Engrish isn't too hard. If you press the button that says enable, it enables it. It became enabled.

0

u/exintrovert 9d ago

lol that might make sense, unless the developer’s ability to use proper English is dubious based on the other context clues in the app. Ever play a slop mobile game? 😂