Skip to content

Commit

Permalink
Merge pull request #1774 from IBMa/phill-983-blockquote-cite
Browse files Browse the repository at this point in the history
fixrule(`blockquote_cite_exists`): Add cite to messages
  • Loading branch information
ErickRenteria authored Dec 13, 2023
2 parents 3788a6b + f57823b commit 4d5c2d0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,16 @@ <h3 id="ruleMessage"></h3>

### Why is this important?

The HTML `<blockquote>` element tells assistive technologies which content is part of a quotation or citation. Using the element for indention or formatting can mislead assistive technology users as to its meaning and purpose.
The `<blockquote>` element tells assistive technologies which content is part of a quotation or citation from another source.
Using the element for indention or formatting only can mislead assistive technology users as to its meaning and purpose.

<!-- This is where the code snippet is injected -->
<div id="locSnippet"></div>

### What to do

* Verify that `<blockquote>` is being used for actual quoted text;
* **Or**, do not use `<blockquote>` for this content.
* Verify that `<blockquote>` is being used for an actual quotation and correctly uses a `cite` attribute
* **Or**, do not use `<blockquote>` and otherwise use CSS to achieve the desired visual indentation

</script></mark-down>
<!-- End main panel -->
Expand All @@ -67,10 +68,11 @@ <h3 id="ruleMessage"></h3>
### About this requirement

* [IBM 1.3.1 Info and Relationships](https://www.ibm.com/able/requirements/requirements/#1_3_1)
* [W3C HTML5 for authors - Blockquote](https://www.w3.org/TR/html5-author/the-blockquote-element.html#the-blockquote-element)

### Who does this affect?

* People using a screen reader, including blind, low vision and neurodivergent people
* People using a screen reader, including blind, low vision, and neurodivergent people
* People using text only, monochrome or braille displays
* People using text-based browsers (e.g., Lynx) or audio interfaces

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export let blockquote_cite_exists: Rule = {
messages: {
"en-US": {
"Pass_0": "Rule Passed",
"Potential_1": "Verify that <blockquote> should not be used only for quotations, not indentation",
"Potential_1": "Verify that <blockquote> should have a 'cite' attribute and not be used for indentation only",
"group": "Use <blockquote> only for quotations, not indentation"
}
},
Expand All @@ -55,4 +55,4 @@ export let blockquote_cite_exists: Rule = {
if (!passed) return RulePotential("Potential_1");

}
}
}

0 comments on commit 4d5c2d0

Please sign in to comment.