onfido-sdk-ui
onfido-sdk-ui copied to clipboard
W3C validation error (accessibility support)
What was the expected behaviour?
Pass w3c validation
What happened instead?
Do not pass w3c validation
Version info:
- Onfido SDK v.5.11.1
Integration configuration:
https://latest-onfido-sdk-ui-onfido.surge.sh
Steps to reproduce:
https://latest-onfido-sdk-ui-onfido.surge.sh go to step: Scan the QR code with your phone copy source code paste into validator https://validator.w3.org/#validate_by_input validation error for QR code part
Error: Attribute shaperendering not allowed on element svg at this point.
From line 599, column 1388; to line 599, column 1465
ontainer"><svg shapeRendering="crispEdges" height="144" width="144" viewBox="0 0 29 29"><path
Demo:
https://latest-onfido-sdk-ui-onfido.surge.sh use any w3c validator online
Hi @akrasnoshchok
Thank you for raising this issue. We'll look into fixing it on our end but in the meantime have also raised a PR with the library we're using for the QR code generation to address this.
Picking this up on low prio. Can still reproduce and validate in latest version (8.1.0
).
After some investigation, It looks like:
-
shapeRendering
isn't converted toshape-rendering
by preact/compat (external PR) -
shape-rendering
is added to thesvg
tag instead of child tag (see docs) (external PR)
I will make a PR for each in there respective repos and see what they think.
Update: Both PR are accepted and ready to be merged or merged. Now we're waiting for them to bring out new releases. Once they have done that we can upgrade and this issue will be resolved.