Commit 001561a0 authored by Wendell Piez's avatar Wendell Piez

Addressing #120 now as well

parent 1a9f2ec9
......@@ -71,7 +71,7 @@
<xsl:variable name="p-proxies">
<!-- Only paragraphs with contents are examined for header promotion.
matches(string(.),'\S') is true iff non-ws content is present. -->
<xsl:variable name="matching-ps" select="//div[@class = 'docx-body']/p[matches(string(.),'\S')] except //table//p"/>
<xsl:variable name="matching-ps" select="//div[@class = 'docx-body']/p[matches(string(.),'\S')] except (//table//p | //list//p)"/>
<xsl:apply-templates select="$matching-ps" mode="digest"/>
</xsl:variable>
......
......@@ -29,7 +29,7 @@
<!-- Note that generated stylesheet will error if $extra-match-criteria is anything but an XPath filter expression
i.e. '[ booleanExp ]' (with square brackets).
Exposing it as a parameter isn't recommended unless we can defend against arbitrary XPath injection. -->
<xsl:variable name="extra-match-criteria">[empty(ancestor::table)][ancestor::*/@class='docx-body'][string-length(.) &lt;= 200][matches(.,'\S')]</xsl:variable>
<xsl:variable name="extra-match-criteria">[empty(ancestor::table|ancestor::list)][ancestor::*/@class='docx-body'][string-length(.) &lt;= 200][matches(.,'\S')]</xsl:variable>
<xsl:template match="body">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment