Problem/Motivation
When testing a patch for #1493324: Inline form errors for accessibility and UX a test for the set shortcut set form failed. Upon investigation I found issues with the form itself.
- Selecting new set and attempting to submit the form with no label is confusing in Chrome and FF because the machine name is hidden but required. Chrome tries to show a popup on the field itself but can't because it is hidden.
- The label for the label field should not be hidden, it is unclear what the text area is for.
- When you remove the required attribute on the machine name and submit the form with it blank, the form is not validated correctly and an exception occurs. This is because it tries to make an entity with no machine name.
- The label field doesn't get marked as having an error.
Steps to reproduce:
As a logged in user visit /user and click the shortcuts tab.


Select new set, leave text field blank and click change set. Observe error message in corner on firefox

Proposed resolution
- Possibly require the label field.
- Unhide the label for the label field.
Remaining tasks
- Mark the label input field as having an error when there is an error for it.
User interface changes
API changes
Beta phase evaluation
| Issue category | Bug because it posses accessibility and usability problems |
|---|---|
| Issue priority | Major because it blocks another major #1493324: Inline form errors for accessibility and UX |
| Unfrozen changes | Unfrozen because it only changes markup by adding a required attribute to an input field label for required errors to attach |
| Prioritized changes | The main goal of this issue is usability/accessibility |
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | switch_shortcut_set-2409885-11.patch | 1.88 KB | nlisgo |
| #11 | switch_shortcut_set-2409885-11-test-only.patch | 812 bytes | nlisgo |
| #11 | interdiff-2409885-7-11.txt | 812 bytes | nlisgo |
| #7 | switch_shortcut_set-2409885-7.patch | 1.09 KB | nlisgo |
| #7 | interdiff-2409885-3-7.txt | 746 bytes | nlisgo |
Comments
Comment #1
crasx commentedadded screenshots and steps to reproduce
Comment #2
nitesh pawar commentedTested with Safari and Chrome on Mac OS X Yosemite. Issue not replicated.
Comment #3
tstoecklerSo in the meantime #2427161: shortcut.admin.js broken, replace with #states actually made the label of that field visible. The misplaced HTML5 required notification was still valid, though. I could fix this locally by adding an additional
requiredstate. Apparently, #states support HTML5. Yay!Please test.
Comment #4
dmsmidtThe patch successfully applies and adds the HTML5 required state.
However, when there is no HTML5 required checks and the form submits, the element is not marked as having an error.
This currently still blocks #1493324: Inline form errors for accessibility and UX, there is no inline message and makes the tests fail.
Comment #5
tstoecklerTaking a look at this...
Thanks for the review, I should have tested the non HTML5 version, but I tend to forget. Much appreciated.
Comment #6
nlisgo commentedI'm going to try an help out on this issue this afternoon. I will unassign myself at the end of the day if I have been unable to assist.
Comment #7
nlisgo commentedComment #8
dmsmidtWorks great, also in combination with inline errors.
Lets get it in!
Comment #9
tim.plunkettI don't think we can yet test the #states change, but we absolutely can test that validate change.
Comment #10
nlisgo commentedI'm going to take on the writing of this test.
Comment #11
nlisgo commentedThis test should address the feedback in #9.
Comment #13
tim.plunkettLooks good!
Comment #14
joelpittetAdded beta evaluation.
Comment #15
alexpottCommitted c83565f and pushed to 8.0.x. Thanks!
Thanks for adding the beta evaluation to the issue summary.
Comment #17
mgiffordExcellent.. This got fixed before I even saw it. Thanks everyone!