News for hackers. Stuff that matters.
Re:Ask HN: Why are toggle switches replacing checkboxes? Isn... by IshKebab on Thursday January 19, 2023 @03:30AM (#34438014)
No, the label should always say what the toggle or checkbox does when it is enabled. If you want to make it extra extra clear (because so many apps have muddied the water by doing it wrong) you should probably put additional small text nearby that changes. Like this:

  [ ] Foo
  *Foo is disabled*

  [X] Foo
  *Foo is enabled*
Also you should not have double-negative check boxes ("disable foo").

I'm not a UI designer but I think this is pretty obvious to anyone that has used bad checkboxes (like OP). (I don't think the problem is unique to slide toggles; I've definitely seen similarly bad checkboxes.)

Re:Ask HN: Why are toggle switches replacing checkboxes? Isn... by pbhjpbhj on Thursday January 19, 2023 @03:41AM (#34438094)
>you should not have double-negative //

Hmm, I'd like it if that always made sense, but sometimes the default state, with nothing active, is for Foo to be on. So "Disable Foo" is doing something not normally required, or something most people don't want. Sometimes it does make sense that _not_ performing a reduction in Baz is default, and that default is off.

You could probably solve it by renaming a feature to used an antonym, but not everything has an antonym [that people know, or that makes sense].

Re:Ask HN: Why are toggle switches replacing checkboxes? Isn... by gisborne on Thursday January 19, 2023 @03:53AM (#34438149)
I’m puzzled why you equate “default state” with “nothing active”. If the default should be that thing the button says is on, then have the button default to being in the active state.

The language even for discussing this is tiring to read…

Re:Ask HN: Why are toggle switches replacing checkboxes? Isn... by IshKebab on Thursday January 19, 2023 @04:56AM (#34438530)
The better solution to "is this the default" is to just have some mechanism for indicating whether the value has been changed, and a way to reset it to its default.

This is quite common in UIs. It also has the benefit of working for all controls, not just checkboxes.

Re:Ask HN: Why are toggle switches replacing checkboxes? Isn... by ilyt on Thursday January 19, 2023 @08:48AM (#34440191)
> Hmm, I'd like it if that always made sense, but sometimes the default state, with nothing active, is for Foo to be on.

Then foo will be checked on by default. That's not a problem.

    [X] Send notifications
Is perfectly unambiguous.

What I'd like to see with every option like that is something showing whether it is in default state or not so user can easily glance what was changed from default. "reset to defaults" per page of settings is also appreciated.