From 1b59fdf32cc1325d7cc60a41a1909a95af0b911a Mon Sep 17 00:00:00 2001 From: Ava Gaiety W Date: Tue, 11 Jun 2024 13:39:28 -0500 Subject: [PATCH] added additional common safe but invalid --- doc/rule-descriptions.md | 8 ++++---- lib/commons/text/is-valid-autocomplete.js | 2 +- .../rules/autocomplete-valid/autocomplete-valid.html | 4 ++++ .../rules/autocomplete-valid/autocomplete-valid.json | 8 +++++++- 4 files changed, 16 insertions(+), 6 deletions(-) diff --git a/doc/rule-descriptions.md b/doc/rule-descriptions.md index 75787363d5..0b941ae991 100644 --- a/doc/rule-descriptions.md +++ b/doc/rule-descriptions.md @@ -77,10 +77,10 @@ ## WCAG 2.1 Level A & AA Rules -| Rule ID | Description | Impact | Tags | Issue Type | ACT Rules | -| :----------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------------------- | :------ | :-------------------------------------------------------------- | :--------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------- | -| [autocomplete-valid](https://dequeuniversity.com/rules/axe/4.9/autocomplete-valid?application=RuleDescription) | Ensure the autocomplete attribute is correct and suitable for the form field | Serious | cat.forms, wcag21aa, wcag135, EN-301-549, EN-9.1.3.5, ACT | failure | [73f2c2](https://act-rules.github.io/rules/73f2c2) | -| [avoid-inline-spacing](https://dequeuniversity.com/rules/axe/4.9/avoid-inline-spacing?application=RuleDescription) | Ensure that text spacing set through style attributes can be adjusted with custom stylesheets | Serious | cat.structure, wcag21aa, wcag1412, EN-301-549, EN-9.1.4.12, ACT | failure | [24afc2](https://act-rules.github.io/rules/24afc2), [9e45ec](https://act-rules.github.io/rules/9e45ec), [78fd32](https://act-rules.github.io/rules/78fd32) | +| Rule ID | Description | Impact | Tags | Issue Type | ACT Rules | +| :----------------------------------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------------------- | :------ | :-------------------------------------------------------------- | :------------------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------- | +| [autocomplete-valid](https://dequeuniversity.com/rules/axe/4.9/autocomplete-valid?application=RuleDescription) | Ensure the autocomplete attribute is correct and suitable for the form field | Serious | cat.forms, wcag21aa, wcag135, EN-301-549, EN-9.1.3.5, ACT | failure, needs review | [73f2c2](https://act-rules.github.io/rules/73f2c2) | +| [avoid-inline-spacing](https://dequeuniversity.com/rules/axe/4.9/avoid-inline-spacing?application=RuleDescription) | Ensure that text spacing set through style attributes can be adjusted with custom stylesheets | Serious | cat.structure, wcag21aa, wcag1412, EN-301-549, EN-9.1.4.12, ACT | failure | [24afc2](https://act-rules.github.io/rules/24afc2), [9e45ec](https://act-rules.github.io/rules/9e45ec), [78fd32](https://act-rules.github.io/rules/78fd32) | ## WCAG 2.2 Level A & AA Rules diff --git a/lib/commons/text/is-valid-autocomplete.js b/lib/commons/text/is-valid-autocomplete.js index 2ad0b4f6d6..116550e783 100644 --- a/lib/commons/text/is-valid-autocomplete.js +++ b/lib/commons/text/is-valid-autocomplete.js @@ -60,7 +60,7 @@ export const autocomplete = { 'impp' ], locations: ['billing', 'shipping'], - invalidButSafe: ['text'] + invalidButSafe: ['text', 'pronouns', 'gender', 'message', 'content'] }; function isValidAutocomplete( diff --git a/test/integration/rules/autocomplete-valid/autocomplete-valid.html b/test/integration/rules/autocomplete-valid/autocomplete-valid.html index b73d75ef2c..00b8aeb233 100644 --- a/test/integration/rules/autocomplete-valid/autocomplete-valid.html +++ b/test/integration/rules/autocomplete-valid/autocomplete-valid.html @@ -173,3 +173,7 @@ + + + + diff --git a/test/integration/rules/autocomplete-valid/autocomplete-valid.json b/test/integration/rules/autocomplete-valid/autocomplete-valid.json index 885682b0b3..110f372f3e 100644 --- a/test/integration/rules/autocomplete-valid/autocomplete-valid.json +++ b/test/integration/rules/autocomplete-valid/autocomplete-valid.json @@ -2,7 +2,13 @@ "description": "autocomplete-valid tests", "rule": "autocomplete-valid", "violations": [["#fail1"], ["#fail2"], ["#fail3"], ["#fail4"], ["#fail5"]], - "incomplete": [["#incomplete1"]], + "incomplete": [ + ["#incomplete1"], + ["#incomplete2"], + ["#incomplete3"], + ["#incomplete4"], + ["#incomplete5"] + ], "passes": [ ["#pass1"], ["#pass2"],