abbreviated-form and keyref

Post here questions and problems related to editing and publishing DITA content.
gbv34
Posts: 105
Joined: Thu Jan 20, 2022 12:36 pm

abbreviated-form and keyref

Post by gbv34 »

The abbreviated-form element used with

Code: Select all

<abbreviated-form keyref=""/>
is pretty handy to display description from a glossary term. It offers information when hovering a link provided through a keyref and a link to the term definition on a specific topic. However, when clicking a link to a term topic, I noticed I can't choose to open a new window

Code: Select all

target="_blank"
or to be redirected within the current window. My issue is the following, is there any way to customize the target for a keyref used with the abbreviated form?

From my research, the abbrev-domain.xsl contains a relevant template with:

Code: Select all

  <xsl:template match="*[contains(@class,' abbrev-d/abbreviated-form ')]" name="topic.abbreviated-form">
    <xsl:variable name="keys" select="@keyref"/>
    <xsl:variable name="target" select="key('id', substring(@href, 2))[1]" as="element()?"/>
    ...
Has anyone already met this need?
------
Gaspard
chrispitude
Posts: 907
Joined: Thu May 02, 2019 2:32 pm

Re: abbreviated-form and keyref

Post by chrispitude »

Hi Gaspard,

Which transformation type are you using for output?

- Chris
gbv34
Posts: 105
Joined: Thu Jan 20, 2022 12:36 pm

Re: abbreviated-form and keyref

Post by gbv34 »

Hi Chris,
I'm currently using html5 transtype.
------
Gaspard
Radu
Posts: 9059
Joined: Fri Jul 09, 2004 5:18 pm

Re: abbreviated-form and keyref

Post by Radu »

Hi Gaspard,

From what I remember we have not had similar requests in the past. But indeed probably something like this can be done with an XSLT customization.
If your question is in general for the DITA XML community, you could try to ask on the DITA Users List:
https://dita-users.groups.io/g/main
Most people registered on the Oxygen XML forum have opted to receive notifications only for their specific posts.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply