Skip to content

Commit

Permalink
DOCTEAM-1368: Take TRD series from a parameter
Browse files Browse the repository at this point in the history
* Set json-ld-seriesname="Technical Reference Documentation"
  • Loading branch information
tomschr committed May 13, 2024
1 parent 3699d03 commit b677e27
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 3 deletions.
9 changes: 8 additions & 1 deletion trd/fo/article.titlepage.templates.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,14 @@
</fo:table-cell>
<fo:table-cell text-align="right" color="&c_jungle;">
<fo:block font-size="&x-large;pt" hyphenate="false">
<xsl:apply-templates select="d:info/d:meta[@name='series'][1]" mode="article.titlepage.recto.auto.mode"/>
<xsl:choose>
<xsl:when test="$json-ld-seriesname != ''">
<xsl:value-of select="$json-ld-seriesname"/>
</xsl:when>
<xsl:when test="d:info/d:meta[@name='series']">
<xsl:apply-templates select="d:info/d:meta[@name='series'][1]" mode="article.titlepage.recto.auto.mode"/>
</xsl:when>
</xsl:choose>
</fo:block>
<fo:block font-size="&large;pt">
<xsl:apply-templates select="d:info/d:meta[@name='type'][1]" mode="article.titlepage.recto.auto.mode"/>
Expand Down
2 changes: 1 addition & 1 deletion trd/fo/param.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
exclude-result-prefixes="d">

<xsl:param name="titlepage.logo.image"><xsl:value-of select="$styleroot"/>images/trd-lightbulb-title.svg</xsl:param>

<xsl:param name="json-ld-seriesname">Technical Reference Documentation</xsl:param>

<xsl:attribute-set name="book.titlepage.recto.style">
<xsl:attribute name="font-family"><xsl:value-of select="$title.font.family"/></xsl:attribute>
Expand Down
3 changes: 2 additions & 1 deletion trd/xhtml/book.titlepage.templates.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
</xsl:variable>
<xsl:variable name="authorgroup" select="exsl:node-set($rtf.authorgroup)"/>

<!--
<xsl:message>author[1] mode="book.titlepage.recto.auto.mode"
content of authorgroup = <xsl:value-of select="count($authorgroup/*/*)"/>
following-sibling::d:author=<xsl:value-of select="count(following-sibling::d:author)"/>
Expand All @@ -66,7 +67,7 @@
following-sibling::d:othercredit=<xsl:value-of select="count(following-sibling::d:othercredit)"/>
preceding-sibling::d:othercredit=<xsl:value-of select="count(preceding-sibling::d:othercredit)"/>
</xsl:message>

-->
<!-- Delegate all collected nodes to the authorgroup template -->
<xsl:apply-templates select="$authorgroup" mode="book.titlepage.recto.auto.mode"/>
</xsl:template>
Expand Down
1 change: 1 addition & 0 deletions trd/xhtml/param.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,5 @@
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:param name="json-ld-seriesname">Technical Reference Documentation</xsl:param>
</xsl:stylesheet>

0 comments on commit b677e27

Please sign in to comment.