Madalyn Parker
Madalyn Parker
@madalynrose
@madalynrose
@madalynrose
@madalynrose
✨RULES✨
@madalynrose
✨RULES✨
@madalynrose
@madalynrose
@madalynrose
Start Small
What could benefit the most?
What has the furthest reach?
@madalynrose
@madalynrose
@madalynrose
using axe.run
@madalynrose
//mount component properly
mountForA11yTest: (component) =>
dom = new DOMContext()
doc = dom.getDocument()
div = doc.createElement('div')
doc.body.appendChild(div)
wrapper = mount(component, { attachTo: div })
return { wrapper: wrapper, div: div, dom: dom }
//clean up after ourselves
cleanUpA11yMount: (div, dom) =>
dom.getDocument().body.removeChild(div)
dom.destroy()
@madalynrose
runAudit: (node, config) =>
oldNode = global.Node
global.Node = node.ownerDocument.defaultView.Node
return new Promise((resolve, reject) =>
axeCore.run(node, config, (err, results) =>
global.Node = oldNode
if err
reject(err)
else
try
assert.equal AxeCoreResults.hasViolations(results), false
assert.equal AxeCoreResults.getViolationsList(results).length, 0
resolve()
catch e
reject(e)
)
)
@madalynrose
/*
ImageComponent = ({ url, altText }) ->
<img src={url} alt={altText} />
*/
describe '<ImageComponent />', =>
it 'should have no accessibility errors', ->
url = 'https://mywebsite.com/some/path/to/an/image.jpg'
//return passesA11yTest(<ImageComponent url={url} altText={""}/>
@madalynrose
@madalynrose
@madalynrose
@madalynrose
They need to know the chat box is there.
They need to know whether a person is available to chat or not.
They need to see the call to action text.
They need to know which messages in the chat belong to whom.
They need to know when messages come in and what they say.
They need to be able to end the chat.
They need to be able to request a transcript of the chat.
They need to be able to leave feedback about their chat.
They need to be able to upload files.
@madalynrose
@madalynrose
@madalynrose
@madalynrose
@madalynrose
@madalynrose
<div
aria-live="assertive"
aria-atomic="true"
role="alert"
id={id}
style={defaultStyles}>
<p>{text}</p>
</div>
defaultStyles = {
position: 'absolute',
visibility: 'visible',
overflow: 'hidden',
display: 'block',
width: '1px',
height: '1px',
margin: '-1px',
border: '0',
padding: '0',
clip: 'rect(0px, 0px, 0px, 0px)',
clipPath: 'polygon(0px 0px, 0px 0px, 0px 0px, 0px 0px)',
whiteSpace: 'nowrap'
}
@madalynrose
control region changes in state based on chat box focus
if(chat box is focused)
add event to list of announcements
join list of announcements with periods
dump list of announcements into announcer
else
# chat box will already play a notification
# sound if it is not focused
add event to list of announcements
@madalynrose
@madalynrose
📒 RULES 📒
@madalynrose
🌈 USABILITY 🌈
@madalynrose
🌈 USABILITY 🌈
@madalynrose
21: The World Tree
@madalynrose
@madalynrose