statify
statify copied to clipboard
Fix label assignment on settings page
Describe the bug The checkboxes on the settings page do not have labels assigned correctly.
Cannot confirm this.
All 4 checkboxes are - in my eyes - linked to the corresponding labels, i.e. clicking on the label toggles them. Same holds for the 3 input fields.
The 2 checkboxes on the widget backside are also linked to their labels.
Tested in v1.8.4 and dev snapshot.
Ah, I see! I tried the texts that are right from the checkbox. I checked how WordPress does it on the general settings page and there it is also the right text that is the label. But in the Statify case the meaningful labels are on the right, that’s true.
For me it’s confusing because I expect checkbox labels to are on the right of the checkbox :D Is that only me, or should we think about a way to switch the positions?
We could think of something like
Logged in users: [ ] exclude (Default: no)
and make the “exclude“ (or whatever text we place there) the actual label.
This should be uniform across all settings. For the numeric inputs I do like the left labels and there is no real meaningful text to place anywhere else without repeating ourselves. We might omit the association here and just add a “title“ attribute there for a11y reasons.
This should be uniform across all settings.
WP itself uses that only for checkboxes and radio buttons. Textfields use the left text as a label, but most those fields only have a field on the right with maybe a description below.
For the radio buttons at the top we already have the right-hand labels. I’d be fine with that for checkboxes, too. And if that matches the WP core pages, even better 👍