lib/asciidoctor/m3d/isodoc.rng in asciidoctor-m3d-0.3.3 vs lib/asciidoctor/m3d/isodoc.rng in asciidoctor-m3d-0.3.4
- old
+ new
@@ -16,23 +16,38 @@
for these elements, and a distinct namespace for any grammar inheriting
these elements; we just want one namespace for any child grammars
of this.
-->
<grammar xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
- <include href="biblio.rng"/>
+ <include href="biblio.rng">
+ <define name="status">
+ <element name="status">
+ <choice>
+ <value>proposal</value>
+ <value>working_draft</value>
+ <value>committee_draft</value>
+ <value>draft_standard</value>
+ <value>final_draft</value>
+ <value>published</value>
+ <value>withdrawn</value>
+ </choice>
+ </element>
+ </define>
+ </include>
<start>
<ref name="standard-document"/>
</start>
<define name="standard-document">
<element name="standard-document">
<ref name="bibdata"/>
<optional>
<ref name="version"/>
</optional>
- <oneOrMore>
- <ref name="sections"/>
- </oneOrMore>
+ <optional>
+ <ref name="preface"/>
+ </optional>
+ <ref name="sections"/>
<zeroOrMore>
<ref name="annex"/>
</zeroOrMore>
<zeroOrMore>
<ref name="references"/>
@@ -42,15 +57,10 @@
<define name="bibdata">
<element name="bibdata">
<ref name="BibData"/>
</element>
</define>
- <define name="status">
- <element name="status">
- <ref name="FormattedString"/>
- </element>
- </define>
<define name="version">
<element name="version">
<optional>
<ref name="vedition"/>
</optional>
@@ -75,10 +85,17 @@
<define name="draft">
<element name="draft">
<text/>
</element>
</define>
+ <define name="preface">
+ <element name="preface">
+ <oneOrMore>
+ <ref name="content"/>
+ </oneOrMore>
+ </element>
+ </define>
<define name="sections">
<element name="sections">
<oneOrMore>
<choice>
<ref name="content"/>
@@ -102,11 +119,13 @@
<ref name="dl"/>
</element>
</define>
<define name="section-title">
<element name="title">
- <text/>
+ <zeroOrMore>
+ <ref name="TextElement"/>
+ </zeroOrMore>
</element>
</define>
<define name="content">
<element name="content">
<ref name="Content-Section"/>
@@ -322,11 +341,11 @@
<define name="termexample">
<element name="termexample">
<attribute name="id">
<data type="ID"/>
</attribute>
- <ref name="BasicBlock"/>
+ <ref name="paragraph"/>
</element>
</define>
<define name="termsource">
<element name="termsource">
<attribute name="status">
@@ -421,11 +440,11 @@
<element name="note">
<attribute name="id">
<data type="ID"/>
</attribute>
<oneOrMore>
- <ref name="paragraph-with-footnote"/>
+ <ref name="paragraph"/>
</oneOrMore>
</element>
</define>
<define name="review">
<element name="review">
@@ -688,24 +707,23 @@
</optional>
<optional>
<ref name="tname"/>
</optional>
<choice>
- <oneOrMore>
+ <ref name="image"/>
+ <zeroOrMore>
<ref name="figure"/>
- </oneOrMore>
- <group>
- <zeroOrMore>
- <ref name="TextElement"/>
- </zeroOrMore>
- <zeroOrMore>
- <ref name="note"/>
- </zeroOrMore>
- <optional>
- <ref name="dl"/>
- </optional>
- </group>
+ </zeroOrMore>
</choice>
+ <zeroOrMore>
+ <ref name="fn"/>
+ </zeroOrMore>
+ <optional>
+ <ref name="dl"/>
+ </optional>
+ <zeroOrMore>
+ <ref name="note"/>
+ </zeroOrMore>
</element>
</define>
<define name="TextElement">
<choice>
<text/>