Permalink
Browse files

Add @class .new to orphaned glossary definitions

  • Loading branch information...
1 parent 15e514a commit e40ce535643dfc795ee582dfc67cb6e739102ba1 Jack Bates committed Jun 16, 2010
Showing with 18 additions and 0 deletions.
  1. +18 −0 css/new.xsl
View
18 css/new.xsl
@@ -23,4 +23,22 @@
</copy>
</template>
+ <!-- TODO Use idref()? http://thread.gmane.org/gmane.text.xml.xsl.general.mulberrytech/80527 -->
+
+ <template match="*[contains(concat(' ', @class, ' '), ' glossary ')]//*[@xml:id][not(//@href[starts-with(normalize-space(.), '#')][current()/@xml:id = substring-after(., '#')])]">
+ <copy>
+
+ <apply-templates select="@*"/>
+
+ <!-- Append to @class -->
+
+ <attribute name="class">
+ <value-of select="@class"/> new
+ </attribute>
+
+ <apply-templates select="node()"/>
+
+ </copy>
+ </template>
+
</stylesheet>

0 comments on commit e40ce53

Please sign in to comment.