Side Navigation: Error message difficult to locate

XMLWordPrintable

    Issue Summary

    The error message that becomes available on submitting the empty form fields.

    Steps to Reproduce

    1. Navigate to side navigation
    2. Navigate to "Add shortcuts" button and activate it.
    3. Observe that non-modal dialog has been appeared on the screen.
    4. Verify that error messages are not difficult to locate.

    Screenshot

    Actual Results

    When users submit "Add shortcuts" form empty, error messages such as "Required" and "A URL scheme is required - did you forget https://?A URL scheme is required - did you forget https://? " get dynamically displayed between the form fields and user's focus remains on button.
    As a result, screen reader users are unaware about the occurrence of errors.

    Expected Results

    Apply the following changes: 

    • Add 'aria-describedby' attribute to the form field.
    • Reference 'id' attribute value of the containner used to display the error message to 'aria-describedby' attribute.
    • Set focus on the first field with error using the JavaScript .focus() method as soon as the form is submitted.

    Code Snippet

    <label for="shortcut-form-url">URL</label>
    <input aria-descriedby="errorurl" class="text full-width-field _aui-form-validation-initialised" type="text" id="shortcut-form-url" name="shortcut-form-url" placeholder="https://www.atlassian.com" data-aui-validation-field="" minlength="0" maxlength="450" required="true" required-msg="Required" data-aui-validation-when="stop-typing" data-aui-validation-repo-shortcut-url-scheme="" resolved="" data-aui-validation-state="invalid" data-aui-notification-error="["Required","A URL scheme is required - did you forget https://?"]">
    <li><span id="errorurl" class="aui-icon aui-icon-small aui-iconfont-error aui-icon-notification">Required</span>Required</li>

    Workaround

    Currently there is no known workaround for this behavior. A workaround will be added here when available

    Environment

    MacBook Pro (16-inch, 2019)
    macOS Ventura Version 13.3.1
    Chrome - Version 114.0.5735.198 (Official Build) (x86_64)
    Firefox- Version 112.0.1 (64-bit)
    Safari- Version 16.4 (18615.1.26.11.23)
    JAWS- Version 2022
    NVDA- Version 2020.3
    Voiceover - Version Latest

      1. image-2023-10-09-18-44-57-398.png
        730 kB
        Varsha Bansode
      2. Screen Recording 2025-02-26 at 10.57.26 AM.mov
        9.03 MB
        Rohit Yadav

          Assignee:
          Unassigned
          Reporter:
          Varsha Bansode (Inactive)
          Votes:
          0 Vote for this issue
          Watchers:
          2 Start watching this issue

            Created:
            Updated: