lib/isodoc/itu/itu.service-publication.xsl in metanorma-itu-1.4.4 vs lib/isodoc/itu/itu.service-publication.xsl in metanorma-itu-1.4.5

- old
+ new

@@ -1634,11 +1634,11 @@ </xsl:if> <xsl:apply-templates/> </fo:block> </xsl:template> - <xsl:template match="itu:title"> + <xsl:template match="itu:title" name="title"> <xsl:variable name="level"> <xsl:call-template name="getLevel"/> </xsl:variable> @@ -4605,10 +4605,11 @@ </xsl:if> </xsl:if> --> </xsl:template><xsl:template match="*[local-name()='dd']" mode="dl"/><xsl:template match="*[local-name()='dd']" mode="dl_process"> <xsl:apply-templates/> </xsl:template><xsl:template match="*[local-name()='dd']"/><xsl:template match="*[local-name()='dd']" mode="process"> + <xsl:apply-templates select="@language"/> <xsl:apply-templates/> </xsl:template><xsl:template match="*[local-name()='dd']/*[local-name()='p']" mode="inline"> <fo:inline><xsl:text> </xsl:text><xsl:apply-templates/></fo:inline> </xsl:template><xsl:template match="*[local-name()='em']"> <fo:inline font-style="italic"> @@ -6813,10 +6814,53 @@ <!-- <fo:block font-weight="bold">Review:</fo:block> <xsl:apply-templates /> --> </xsl:template><xsl:template match="*[local-name() = 'name']/text()"> <!-- 0xA0 to space replacement --> <xsl:value-of select="java:replaceAll(java:java.lang.String.new(.),' ',' ')"/> + </xsl:template><xsl:variable name="ul_labels_"> + + + + + + + + + + + + + + + + + + </xsl:variable><xsl:variable name="ul_labels" select="xalan:nodeset($ul_labels_)"/><xsl:template name="setULLabel"> + <xsl:variable name="list_level_" select="count(ancestor::*[local-name() = 'ul']) + count(ancestor::*[local-name() = 'ol'])"/> + <xsl:variable name="list_level"> + <xsl:choose> + <xsl:when test="$list_level_ &lt;= 3"><xsl:value-of select="$list_level_"/></xsl:when> + <xsl:otherwise><xsl:value-of select="$list_level_ mod 3"/></xsl:otherwise> + </xsl:choose> + </xsl:variable> + <xsl:choose> + <xsl:when test="$ul_labels/label[not(@level)]"> <!-- one label for all levels --> + <xsl:apply-templates select="$ul_labels/label[not(@level)]" mode="ul_labels"/> + </xsl:when> + <xsl:when test="$list_level mod 3 = 0"> + <xsl:apply-templates select="$ul_labels/label[@level = 3]" mode="ul_labels"/> + </xsl:when> + <xsl:when test="$list_level mod 2 = 0"> + <xsl:apply-templates select="$ul_labels/label[@level = 2]" mode="ul_labels"/> + </xsl:when> + <xsl:otherwise> + <xsl:apply-templates select="$ul_labels/label[@level = 1]" mode="ul_labels"/> + </xsl:otherwise> + </xsl:choose> + </xsl:template><xsl:template match="label" mode="ul_labels"> + <xsl:copy-of select="@*[not(local-name() = 'level')]"/> + <xsl:value-of select="."/> </xsl:template><xsl:template match="*[local-name() = 'ul'] | *[local-name() = 'ol']"> <xsl:choose> <xsl:when test="parent::*[local-name() = 'note'] or parent::*[local-name() = 'termnote']"> <fo:block-container> <xsl:attribute name="margin-left"> @@ -7266,9 +7310,13 @@ <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" viewBox="0 0 2 2"> <rect x="0" y="0" width="2" height="2" fill="black"/> </svg> </fo:instream-foreign-object> </fo:inline> + </xsl:template><xsl:template match="@language"> + <xsl:copy-of select="."/> + </xsl:template><xsl:template match="*[local-name() = 'p'][@type = 'floating-title']" priority="4"> + <xsl:call-template name="title"/> </xsl:template><xsl:template name="convertDate"> <xsl:param name="date"/> <xsl:param name="format" select="'short'"/> <xsl:variable name="year" select="substring($date, 1, 4)"/> <xsl:variable name="month" select="substring($date, 6, 2)"/> \ No newline at end of file