Skip to content

Commit

Permalink
updating with origin
Browse files Browse the repository at this point in the history
  • Loading branch information
ajanec01 committed Feb 17, 2021
2 parents 1f735b0 + f1b55d3 commit 091255c
Show file tree
Hide file tree
Showing 50 changed files with 4,223 additions and 218 deletions.
7 changes: 7 additions & 0 deletions __tests__/spelling-ignore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@
- accesskey
- Accesskeys
- kerning
- drawImage
- pragma

# spell checker checks against strict casing & hence some repeated words here
- Autocomplete
Expand Down Expand Up @@ -127,10 +129,14 @@
- GitHub

# Test case anamolies
- brewitt-taylor
- level2-frame1
- level1-frame2
- level1-frame1
- XYZ
- Yu
- Sumei
- Tuttle

# Attributes (repeated words with casing as retext-spell has no config to ignore casing)
- href
Expand Down Expand Up @@ -196,6 +202,7 @@
- programmatically
- personalization
- autofill
- dismissible
- implementers
- presentational
- backtick
Expand Down
2 changes: 1 addition & 1 deletion _rules/aria-required-context-role-ff89c9.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ The applicability of this rule is limited to the [WAI-ARIA 1.1 Recommendation][a

An example of an element that has an [implicit semantic role][] that is identical to its [explicit semantic role][] is a `<li role="listitem">` element. These elements are not applicable because they have extra requirements and should thus be checked separately.

The definition of [owned by][] used in this rule is different from the definition of ["owned element" in WAI-ARIA](https://www.w3.org/TR/wai-aria-1.1/#dfn-owned-element).
The definition of [owned by][] used in this rule is different from the definition of ["owned element" in WAI-ARIA](https://www.w3.org/TR/wai-aria-1.1/#dfn-owned-element). In this rule "owned by" includes only direct children of the owner element, whereas an "owned element" is any descendant of the owner.

[Subclass roles][subclass role] of [required context roles][] are not automatically included as possible [required context roles][]. For example, the [`feed`](https://www.w3.org/TR/wai-aria-1.1/#feed) role is not a possible [required context role][] for [`listitem`](https://www.w3.org/TR/wai-aria-1.1/#listitem), even though [`feed`](https://www.w3.org/TR/wai-aria-1.1/#feed) is a [subclass role][] of the [`list`](https://www.w3.org/TR/wai-aria-1.1/#list) role.

Expand Down
27 changes: 20 additions & 7 deletions _rules/autocomplete-valid-value-73f2c2.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ acknowledgments:
This rule applies to any HTML `input`, `select` and `textarea` element with an `autocomplete` [attribute value][] that is neither empty (`""`) nor only [ASCII whitespace][], except if one of the following is true:

- **hidden**: the element is not [visible][], and not [included in the accessibility tree][]; or
- **disabled**: the element has the `disabled` attribute or the `aria-disabled` [attribute value][] of `true`; or
- **disabled**: the element is a [disabled element]; or
- **fixed value**: the element is an `input` element with a `type` [attribute value][] of either `hidden`, `button`, `submit` or `reset`; or
- **static**: the element is not part of [sequential focus navigation][] and has a [semantic role][] that is not a [widget role][].

Expand All @@ -45,6 +45,8 @@ Each test target's `autocomplete` [attribute value][] has a [correct autocomplet

The `autocomplete` attribute is used on form fields that correspond to [Input Purposes for User Interface Components](https://www.w3.org/TR/WCAG21/#input-purposes) and collect information about the user.

If the `autocomplete` attribute is used to describe "custom" taxonomy, for example `<input type="text" autocomplete="banner" />`, success Criterion [1.3.5 Identify Input Purpose][sc135] may be satisfied even if this rule failed.

The `type` attribute is used correctly according to the intended purpose of `input` elements. If an incorrect `type` attribute is used for `input` elements, this rule may fail elements that satisfy success Criterion [1.3.5 Identify Input Purpose][sc135]. For example if an `input` element has a `type` of `number`, but is expecting an e-mail address.

The `aria-disabled` state is used on `input` elements which are not part of [sequential focus navigation][] and are not otherwise [operable](https://www.w3.org/TR/wai-aria-1.2/#dfn-operable). If this is not the case, this rule may be inapplicable on elements that are still [operable](https://www.w3.org/TR/wai-aria-1.2/#dfn-operable) and require a valid `autocomplete` attribute to satisfy success Criterion [1.3.5 Identify Input Purpose][sc135].
Expand Down Expand Up @@ -84,11 +86,13 @@ This `autocomplete` [attribute value][] only has the required token, and is vali

```html
<form autocomplete="off">
<label for="bday">Birthday month</label>
<select id="bday" autocomplete="bday-month">
<option>January</option>
<option>...</option>
</select>
<label
>Birthday month
<select autocomplete="bday-month">
<option>January</option>
<option>...</option>
</select>
</label>
</form>
```

Expand All @@ -97,7 +101,7 @@ This `autocomplete` [attribute value][] only has the required token, and is vali
This `autocomplete` [attribute value][] only has the required token, and is valid for a `textarea` element. Mixing upper and lower case letters is allowed for `autocomplete` attributes.

```html
<label for="sAddress">Street address</label> <textarea id="sAdress" autocomplete="Street-Address"></textarea>
<label> Street address<textarea autocomplete="Street-Address"></textarea></label>
```

#### Passed Example 4
Expand Down Expand Up @@ -174,6 +178,14 @@ This `autocomplete` [attribute value][] is not appropriate for the field. The fo
<label>Quantity<input type="number" autocomplete="email"/></label>
```

#### Failed Example 6

The `autocomplete` attribute value is on an `input` element that does not have a semantic role that is a widget role, but still participates in [sequential focus navigation][] because of the `tabindex` attribute.

```html
<label>Username<input role="banner" tabindex="0" autocomplete="banner"/></label>
```

### Inapplicable

#### Inapplicable Example 1
Expand Down Expand Up @@ -244,6 +256,7 @@ This `autocomplete` attribute is ignored because it is on an element with a [sem
[attribute value]: #attribute-value 'Definition of Attribute Value'
[appropriate field for the form control]: #appropriate-field-for-the-form-control 'Definition of Appropriate field for the form control'
[correct autocomplete field]: #correct-autocomplete-field 'Definition of Correct autocomplete field'
[disabled element]: #disabled-element 'Definition of Disabled Element'
[html specification for autofill detail tokens]: https://html.spec.whatwg.org/#autofill-detail-tokens 'HTML Autofill Detail, 2020/08/12'
[included in the accessibility tree]: #included-in-the-accessibility-tree 'Definition of Included in the accessibility tree'
[presentational roles conflict resolution]: https://www.w3.org/TR/wai-aria-1.1/#conflict_resolution_presentation_none 'Presentational Roles Conflict Resolution'
Expand Down
Loading

0 comments on commit 091255c

Please sign in to comment.