Hi Jason,
Here is a quick summary of an approach, untested.
1. You can start by copying the template with match="d:appendix" from component.xsl
to your customization layer and changing the match attribute to add the role
qualifier. That template will give you the basic elements and title processing.
2. Replace <xsl:apply-templates/> with <xsl:call-template name="process.endnotes"/>
3. Copy the template named 'process.footnotes' from footnote.xsl to your
customization, renaming it to 'process.endnotes'.
4. Modify process.endnotes to replace:
<xsl:variable name="footnotes" select=".//d:footnote"/>
with:
<xsl:variable name="footnotes" select="//d:footnote"/>
Removing the leading dot in the select statement converts it from selecting footnotes
only as descendants of the current element to descendants of the root element.
I didn't have a chance to test this, but it should get you started.
Bob Stayton
Sagehill Enterprises
bobs@sagehill.net