axe-core icon indicating copy to clipboard operation
axe-core copied to clipboard

Put help-same-as-label into its own rule

Open WilcoFiers opened this issue 5 years ago • 1 comments

The help-same-as-label check is the only check in axe-core disabled by default. This is confusing. We should either put it in its own rule, have it run as a best practice, or we should remove it.

WilcoFiers avatar Jan 17 '19 11:01 WilcoFiers

Should be a best practice rule

dylanb avatar Jun 16 '19 16:06 dylanb

Looking at this some more. I don't think the current check is suitable to be put into its own rule. Doing a simple strA !== strB isn't particularly insightful. I don't think I can justify working to create a new best practice, given the other priorities we have. I don't think this check should be deprecated. It has some use for custom rules, but it's not suitable to run by default.

Instead, I'm going to enable this check for anyone who wants it in a custom rule, and I'm going to remove it from the label and select-name rules so that this check doesn't run by default, and its impact doesn't get listed in the rule-descriptions.md file.

WilcoFiers avatar Jun 28 '23 12:06 WilcoFiers

Valdiated using latest axe-core develop branch code base,

'label' and 'select-name' rules - now having impact only critical there is no minor impact' .

but not seeing any new rules listed in rules with label-same-as-description

Image

padmavemulapati avatar Aug 03 '23 12:08 padmavemulapati

@straker , can you please help me to get the html snippet to raise an issue for the rule label-same-as-description

padmavemulapati avatar Aug 03 '23 12:08 padmavemulapati

@padmavemulapati You'll need to create a custom rule to use it since we don't have any rules that use it by default anymore.

<input title="Username" aria-label="Select Username">
<script>
axe.configure({
  rules: [
    {
      id: 'help-same-as-label',
      any: ['help-same-as-label']
    }
  ]
});

await axe.run()
</script>

straker avatar Aug 03 '23 14:08 straker

@straker , thank you , it is working with custom-rule configuration for help-same-as-label rule.

https://github.com/dequelabs/axe-core/assets/47409579/a4a92708-07a1-4033-b0dc-c0a4edc3ad84

padmavemulapati avatar Aug 03 '23 14:08 padmavemulapati

@padmavemulapati Please add environment details in the closing comments.

somaalapati avatar Aug 03 '23 14:08 somaalapati

@padmavemulapati Please add environment details in the closing comments.

@somaalapati , axe-core tickets validating on the latest develop branch code base, and adding the axe.js file in source - snippets running the source to axe.run() so obviously it is testing in chrome browser - developer tool.

padmavemulapati avatar Aug 03 '23 14:08 padmavemulapati