* Mark error lines in red, and expand subtrees containing errors
automatically.
This commit is contained in:
parent
78c72bf10e
commit
800a6ff845
|
@ -23,12 +23,14 @@
|
||||||
</html>
|
</html>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
|
|
||||||
<xsl:template match="nest">
|
<xsl:template match="nest">
|
||||||
|
|
||||||
<!-- The tree should be collapsed by default if all children are
|
<!-- The tree should be collapsed by default if all children are
|
||||||
unimportant or if the header is unimportant. -->
|
unimportant or if the header is unimportant. -->
|
||||||
<xsl:variable name="collapsed"
|
<!-- <xsl:variable name="collapsed"
|
||||||
select="count(.//line[not(@priority = 3)]) = 0 or ./head[@priority = 3]" />
|
select="count(.//line[not(@priority = 3)]) = 0 or ./head[@priority = 3]" /> -->
|
||||||
|
<xsl:variable name="collapsed" select="count(.//*[@error]) = 0"/>
|
||||||
|
|
||||||
<xsl:variable name="style"><xsl:if test="$collapsed">display: none;</xsl:if></xsl:variable>
|
<xsl:variable name="style"><xsl:if test="$collapsed">display: none;</xsl:if></xsl:variable>
|
||||||
<xsl:variable name="arg"><xsl:choose><xsl:when test="$collapsed">true</xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:variable>
|
<xsl:variable name="arg"><xsl:choose><xsl:when test="$collapsed">true</xsl:when><xsl:otherwise>false</xsl:otherwise></xsl:choose></xsl:variable>
|
||||||
|
@ -53,12 +55,17 @@
|
||||||
</ul>
|
</ul>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
|
|
||||||
<xsl:template match="head|line">
|
<xsl:template match="head|line">
|
||||||
<code>
|
<code>
|
||||||
|
<xsl:if test="@error">
|
||||||
|
<xsl:attribute name="class">error</xsl:attribute>
|
||||||
|
</xsl:if>
|
||||||
<xsl:apply-templates/>
|
<xsl:apply-templates/>
|
||||||
</code>
|
</code>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
|
|
||||||
<xsl:template match="storeref">
|
<xsl:template match="storeref">
|
||||||
<em class='storeref'>
|
<em class='storeref'>
|
||||||
<span class='popup'><xsl:apply-templates/></span>
|
<span class='popup'><xsl:apply-templates/></span>
|
||||||
|
|
|
@ -79,3 +79,8 @@ em.storeref:hover span.popup {
|
||||||
font-family: monospace;
|
font-family: monospace;
|
||||||
font-size: larger;
|
font-size: larger;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.error {
|
||||||
|
color: #ff0000;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
Loading…
Reference in a new issue