Skip to content

Commit

Permalink
fix footnote marker
Browse files Browse the repository at this point in the history
  • Loading branch information
peterstadler committed Mar 18, 2024
1 parent 66f28a7 commit e5c2754
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions xsl/common_main.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,14 @@
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:variable name="class">
<xsl:choose>
<xsl:when test="$marker castable as xs:int">arabic</xsl:when>
<xsl:otherwise><xsl:value-of select="$marker"/></xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:element name="a">
<xsl:attribute name="class" select="string-join(('noteMarker', $marker), ' ')"/>
<xsl:attribute name="class" select="string-join(('noteMarker', $class), ' ')"/>
<xsl:attribute name="id" select="wega:get-backref-id($id)"/>
<xsl:attribute name="data-toggle">popover</xsl:attribute>
<xsl:attribute name="data-trigger">focus</xsl:attribute>
Expand All @@ -73,6 +79,9 @@
<xsl:when test="$marker eq 'arabic'">
<xsl:value-of select="count(preceding::tei:note[@type=('commentary','definition','textConst')]) + 1"/>
</xsl:when>
<xsl:when test="$marker castable as xs:int">
<xsl:value-of select="$marker"/>
</xsl:when>
<xsl:when test="not($marker) and self::tei:note[not(@type='textConst')]">
<xsl:text>*</xsl:text>
</xsl:when>
Expand Down Expand Up @@ -701,7 +710,7 @@
-->
<xsl:template match="tei:footNote[@n]" priority="2">
<xsl:call-template name="popover">
<xsl:with-param name="marker" select="'arabic'"/>
<xsl:with-param name="marker" select="@n"/>
</xsl:call-template>
</xsl:template>

Expand Down

0 comments on commit e5c2754

Please sign in to comment.