Webhelp responsive: Adding text links to the navprev/navnext arrows

ckabstein
Posts: 107
Joined: Fri Apr 24, 2015 12:28 pm

Webhelp responsive: Adding text links to the navprev/navnext arrows

Post by ckabstein » Mon Jul 27, 2020 12:50 pm

Hi,

We would like to make some layout changes to the navprev/navnext arrow icons in the webhelp template.

We have managed to remove them from the top right area, where they appear on the same line as the breadcrumb, and move them to the bottom of the pages.

However, at the bottom, we would like to show the topic title next to the arrows, not just the arrows.

In the dita2xhtml.xsl file, I have seen that in the

Code: Select all

<xsl:template match="/|node()|@*" mode="gen-user-header">
template, the following code seems to create the links behind the arrows:

Code: Select all

 <xsl:call-template name="makelink">
                <xsl:with-param name="label" select="$textLinkBefore"/>
              </xsl:call-template>
I have checked the topicComponentsExpander.xsl file where it says:

Code: Select all

<xsl:template
        match="span[@id = 'topic_navigation_links']/span[contains(@class, 'navprev')]/a/node()"
        mode="copyNavigationLinks">
    </xsl:template>
    <xsl:template
        match="span[@id = 'topic_navigation_links']/span[contains(@class, 'navnext')]/a/node()"
        mode="copyNavigationLinks"/>
When I change node() to text() in the topicComponentsExpander.xsl file, the makelink template returns the node as text, but it adds the "navheader_label" and "navheader_separator" strings to the topic titles, which we don't want to see. We just want the topic title to appear.
I cannot remove those strings, because that would break the aria-label code for accessibility purposes.

Is there a way to only show the topic titles next to the arrows?

Thanks,
Christina
oXygen XML Editor 23.1 build 2021061407
DITA OT 3.6

ckabstein
Posts: 107
Joined: Fri Apr 24, 2015 12:28 pm

Re: Webhelp responsive: Adding text links to the navprev/navnext arrows

Post by ckabstein » Mon Aug 03, 2020 10:44 am

Just for your info: we have now moved to DITA OT 3.4.1 and Oxygen 22.1, but I presume that it will not make a difference re. my question.

Hope you can help.

Thanks,
Christina
oXygen XML Editor 23.1 build 2021061407
DITA OT 3.6

Post Reply