Potential Accessibility Issues in Webhelp Responsive Output
Post here questions and problems related to editing and publishing DITA content.
-
- Posts: 1
- Joined: Mon Dec 14, 2020 11:30 pm
Potential Accessibility Issues in Webhelp Responsive Output
I've recently started working with a company that publishes their online help using Oxygen's webhelp responsive templates. There is currently a push to have our web material be brought up to accessibility standards (WCAG 2.0+).
As the person that set up our publication process is no longer with the company, I'm struggling to identify how to modify the output.
Specific items I'm trying to trace the roots of and hopefully correct:
Tables are generated with empty <caption> tags.
The topic id is replicated in data-id attributes.
Modal images are generated without an alt element.
If some direction could be provided on where I might find and modify the sources of this issues, it would be appreciated. If this isn't the right spot to ask these questions, let me know and I'll direct my questions there.
Thanks.
As the person that set up our publication process is no longer with the company, I'm struggling to identify how to modify the output.
Specific items I'm trying to trace the roots of and hopefully correct:
Tables are generated with empty <caption> tags.
The topic id is replicated in data-id attributes.
Modal images are generated without an alt element.
If some direction could be provided on where I might find and modify the sources of this issues, it would be appreciated. If this isn't the right spot to ask these questions, let me know and I'll direct my questions there.
Thanks.
-
- Site Admin
- Posts: 275
- Joined: Thu Dec 24, 2009 11:21 am
Re: Potential Accessibility Issues in Webhelp Responsive Output
Hello,
The recommended way to change the HTML structure of the WebHelp Responsive output is to use an XSLT Extension: https://www.oxygenxml.com/doc/versions/ ... mport.html
This way you can override the default XSLT processing that generates the HTML pages.
However, if you do not want to provide a title or a description for your tables you can contribute an XSLT extension file in your current Publishing Template that does not allow empty caption generation.
For example, the XSLT file may look like the one below:
For example, the Menu entries corresponding to certain topics of a publication can be decorated with specific icons via CSS using a selector based on the @data-id attribute.
I would not recommend removing this attribute because in the future it might be used as base for other WebHelp features.
It is only used as a placeholder for the images in the content that are not displayed at their original size. When the user clicks on a image, this placeholder will display an enlarged version of the image.
As this <img> placeholder is meant to be ignored by the Screen Reader it has an empty @alt attribute.
(https://www.w3.org/WAI/WCAG21/Techniques/html/H67)
Regards,
Alin
The recommended way to change the HTML structure of the WebHelp Responsive output is to use an XSLT Extension: https://www.oxygenxml.com/doc/versions/ ... mport.html
This way you can override the default XSLT processing that generates the HTML pages.
You can avoid having tables with empty caption by simply providing a <title> or a <desc> element for that table in your source DITA topic:Specific items I'm trying to trace the roots of and hopefully correct:
Tables are generated with empty <caption> tags.
Code: Select all
<table frame="none">
<title>Flowers</title>
<desc>Description</desc>
<!-- ... -->.
</table>
For example, the XSLT file may look like the one below:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:table="http://dita-ot.sourceforge.net/ns/201007/dita-ot/table"
version="3.0">
<xsl:template
match="*[contains(@class, ' topic/table ')][not(*[contains(@class, ' topic/title ') or contains(@class, ' topic/desc ')])]"
mode="table:title" priority="100">
<!-- Do not generate a caption element for the tables that do not have either a description or a title -->
</xsl:template>
</xsl:stylesheet>
The @data-id attributes are generated by design for all navigation links. More exactly they are generated for each entry in the following components:The topic id is replicated in data-id attributes.
- Menu
- Breadcrumb
- Publication TOC
For example, the Menu entries corresponding to certain topics of a publication can be decorated with specific icons via CSS using a selector based on the @data-id attribute.
I would not recommend removing this attribute because in the future it might be used as base for other WebHelp features.
I assume that you are referring to the <img> element from this fragment:Modal images are generated without an alt element.
Code: Select all
<div id="modal_img_large" class="modal">
<span class="close oxy-icon oxy-icon-remove"></span>
<!-- Modal Content (The Image) -->
<img class="modal-content" id="modal-img" alt="">
<!-- Modal Caption (Image Text) -->
<div id="caption"></div>
</div>
As this <img> placeholder is meant to be ignored by the Screen Reader it has an empty @alt attribute.
(https://www.w3.org/WAI/WCAG21/Techniques/html/H67)
Regards,
Alin
Alin Balasa
Software Developer
<oXygen/> XML Editor
http://www.oxygenxml.com
Software Developer
<oXygen/> XML Editor
http://www.oxygenxml.com
Return to “DITA (Editing and Publishing DITA Content)”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service