parent
3d45451fef
commit
2c245f9506
|
@ -20,10 +20,18 @@
|
||||||
list-style-type: none;
|
list-style-type: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.element {
|
.tag {
|
||||||
color: darkred;
|
color: darkred;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.attr {
|
||||||
|
color: darksalmon;
|
||||||
|
}
|
||||||
|
|
||||||
|
.value {
|
||||||
|
color: darkblue;
|
||||||
|
}
|
||||||
|
|
||||||
.comment {
|
.comment {
|
||||||
color: lightgrey;
|
color: lightgrey;
|
||||||
}
|
}
|
||||||
|
@ -55,15 +63,27 @@
|
||||||
<xsl:template match="*">
|
<xsl:template match="*">
|
||||||
<li>
|
<li>
|
||||||
<span class="element">
|
<span class="element">
|
||||||
<xsl:value-of select="concat('<', name(), '>')"/>
|
<
|
||||||
|
<span class="tag"><xsl:value-of select="name()"/></span>
|
||||||
|
|
||||||
|
<xsl:for-each select="@*">
|
||||||
|
<span class="attr"> <xsl:value-of select="name()"/></span>
|
||||||
|
=
|
||||||
|
"<span class="value"><xsl:value-of select="."/></span>"
|
||||||
|
</xsl:for-each>
|
||||||
|
>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
<xsl:if test="node()">
|
<xsl:if test="node()">
|
||||||
<ul>
|
<ul>
|
||||||
<xsl:apply-templates/>
|
<xsl:apply-templates/>
|
||||||
</ul>
|
</ul>
|
||||||
</xsl:if>
|
</xsl:if>
|
||||||
|
|
||||||
<span class="element">
|
<span class="element">
|
||||||
<xsl:value-of select="concat('</', name(), '>')"/>
|
</
|
||||||
|
<span class="tag"><xsl:value-of select="name()"/></span>
|
||||||
|
>
|
||||||
</span>
|
</span>
|
||||||
</li>
|
</li>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
Loading…
Reference in New Issue