metanorma-plateau 1.2.15 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0014e7cf98799f9ee7a921932aaeadd753071bba0a34e5892c4a8a21b65c3ca4
4
- data.tar.gz: 01a2c307f33cd0ef465dab9b61feaa2ee4e46c40ea04bcc4bcc5f913fa0ac8d6
3
+ metadata.gz: 841d6f094941f393720ad4f1674e228f1d675fbf7281f1081de541050b36dc29
4
+ data.tar.gz: 0f6cebfa9ccc94ab21bb351c4a634a515b364368600a5dea5786acb15d4db5d5
5
5
  SHA512:
6
- metadata.gz: 63106ef098edcb00a800ada211bfaa7fd660393f62ffdc87394993bab4452181b885149b5decadc80463ae571e60fd5ba97f7e0cd02c4f792e7706892ae2420d
7
- data.tar.gz: c17d6c95177e33d7c12e4352c1ba14fc9b145c70cbb0356b99c62d5508551f177508fd775c729ee4c1828cfe6c09de5b6dae4d9abf32a08d63b2ad9da76c796b
6
+ metadata.gz: ad228185eaa88a41386fefbc702a69ed224880c334e6d900b008aef45651b1c943db623564d8a97729ecc35ea57483f0b147278736af5e5bb2e149e2f7985421
7
+ data.tar.gz: 7210cec6b601df8a84bd9d7e22307fa45824997bed4c99abf9814b4a76b1a5434bf8a2bbac5425921e438d25c9df80775202e1309c73583a1520d335afc10f54
@@ -704,7 +704,7 @@
704
704
  <xsl:if test="$doctype = 'technical-report'">
705
705
  <xsl:attribute name="margin-left">5.5mm</xsl:attribute>
706
706
  </xsl:if>
707
- <fo:instream-foreign-object content-width="24mm" fox:alt-text="PLATEAU Logo">
707
+ <fo:instream-foreign-object content-width="24mm" fox:alt-text="PLATEAU Logo" fox:placement="Block">
708
708
  <xsl:if test="$doctype = 'technical-report'">
709
709
  <xsl:attribute name="content-width">20.5mm</xsl:attribute>
710
710
  </xsl:if>
@@ -1203,14 +1203,14 @@
1203
1203
  </xsl:when> -->
1204
1204
  <xsl:when test="parent::mn:ul and $list_item_label = '→'">
1205
1205
  <fo:inline>
1206
- <fo:instream-foreign-object content-width="2.5mm" fox:alt-text="ul list label">
1206
+ <fo:instream-foreign-object content-width="2.5mm" fox:alt-text="ul list label" fox:placement="Inline">
1207
1207
  <xsl:copy-of select="$list_label_arrow"/>
1208
1208
  </fo:instream-foreign-object>
1209
1209
  </fo:inline>
1210
1210
  </xsl:when>
1211
1211
  <xsl:when test="parent::mn:ul and $list_item_label = '☆'">
1212
1212
  <fo:inline>
1213
- <fo:instream-foreign-object content-width="2.5mm" fox:alt-text="ul list label">
1213
+ <fo:instream-foreign-object content-width="2.5mm" fox:alt-text="ul list label" fox:placement="Inline">
1214
1214
  <xsl:copy-of select="$list_label_star"/>
1215
1215
  </fo:instream-foreign-object>
1216
1216
  </fo:inline>
@@ -1325,7 +1325,7 @@
1325
1325
  <xsl:template match="mn:preprocess-xslt" mode="update_xml_pres"/>
1326
1326
  <xsl:template match="mn:stem" mode="update_xml_pres"/>
1327
1327
 
1328
- <xsl:template match="mn:span[ @class = 'fmt-caption-label' or @class = 'fmt-element-name' or @class = 'fmt-caption-delim' or @class = 'fmt-autonum-delim']" mode="update_xml_pres" priority="3">
1328
+ <xsl:template match="mn:span[ @class = 'fmt-caption-label' or @class = 'fmt-element-name' or @class = 'fmt-caption-delim' or @class = 'fmt-autonum-delim' or @class = 'fmt-clause-delim']" mode="update_xml_pres" priority="3">
1329
1329
  <xsl:apply-templates mode="update_xml_pres"/>
1330
1330
  </xsl:template>
1331
1331
 
@@ -2990,7 +2990,7 @@
2990
2990
  </xsl:element>
2991
2991
  </xsl:template> -->
2992
2992
 
2993
- <xsl:template match="mn:span[ @class = 'fmt-caption-label' or @class = 'fmt-element-name' or @class = 'fmt-caption-delim' or @class = 'fmt-autonum-delim']" mode="update_xml_step1" priority="3">
2993
+ <xsl:template match="mn:span[ @class = 'fmt-caption-label' or @class = 'fmt-element-name' or @class = 'fmt-caption-delim' or @class = 'fmt-autonum-delim' or @class = 'fmt-clause-delim']" mode="update_xml_step1" priority="3">
2994
2994
  <xsl:apply-templates mode="update_xml_step1"/>
2995
2995
  </xsl:template>
2996
2996
 
@@ -4120,6 +4120,9 @@
4120
4120
 
4121
4121
  <xsl:template name="refine_sourcecode-style">
4122
4122
  <xsl:call-template name="setKeepAttributes"/>
4123
+ <xsl:if test="ancestor::mn:sourcecode and parent::mn:td">
4124
+ <xsl:attribute name="role">SKIP</xsl:attribute>
4125
+ </xsl:if>
4123
4126
  </xsl:template> <!-- refine_sourcecode-style -->
4124
4127
 
4125
4128
  <xsl:attribute-set name="sourcecode-number-style">
@@ -4446,30 +4449,30 @@
4446
4449
  </xsl:template>
4447
4450
 
4448
4451
  <!-- outer table with line numbers for sourcecode -->
4449
- <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] | -->
4450
- <fo:block>
4451
- <fo:table width="100%" table-layout="fixed">
4452
+ <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table" priority="3"> <!-- *[local-name()='table'][@type = 'sourcecode'] | -->
4453
+ <fo:block role="SKIP">
4454
+ <fo:table width="100%" table-layout="fixed" role="SKIP">
4452
4455
  <xsl:copy-of select="@id"/>
4453
4456
  <fo:table-column column-width="8%"/>
4454
4457
  <fo:table-column column-width="92%"/>
4455
- <fo:table-body>
4458
+ <fo:table-body role="SKIP">
4456
4459
  <xsl:apply-templates/>
4457
4460
  </fo:table-body>
4458
4461
  </fo:table>
4459
4462
  </fo:block>
4460
4463
  </xsl:template>
4461
- <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table/mn:tbody" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']/*[local-name() = 'tbody'] | -->
4464
+ <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table/mn:tbody" priority="3"> <!-- *[local-name()='table'][@type = 'sourcecode']/*[local-name() = 'tbody'] | -->
4462
4465
  <xsl:apply-templates/>
4463
4466
  </xsl:template>
4464
- <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table//mn:tr" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode']//*[local-name()='tr'] | -->
4465
- <fo:table-row>
4467
+ <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table//mn:tr" priority="3"> <!-- *[local-name()='table'][@type = 'sourcecode']//*[local-name()='tr'] | -->
4468
+ <fo:table-row role="SKIP">
4466
4469
  <xsl:apply-templates/>
4467
4470
  </fo:table-row>
4468
4471
  </xsl:template>
4469
4472
  <!-- first td with line numbers -->
4470
- <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table//mn:tr/*[local-name() = 'td'][not(preceding-sibling::*)]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
4471
- <fo:table-cell>
4472
- <fo:block>
4473
+ <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table//mn:tr/*[local-name() = 'td'][not(preceding-sibling::*)]" priority="3"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
4474
+ <fo:table-cell role="SKIP">
4475
+ <fo:block role="SKIP">
4473
4476
 
4474
4477
  <!-- set attibutes for line numbers - same as sourcecode -->
4475
4478
  <xsl:variable name="sourcecode_attributes">
@@ -4477,7 +4480,7 @@
4477
4480
  <xsl:call-template name="get_sourcecode_attributes"/>
4478
4481
  </xsl:for-each>
4479
4482
  </xsl:variable>
4480
- <xsl:for-each select="xalan:nodeset($sourcecode_attributes)/sourcecode_attributes/@*[not(starts-with(local-name(), 'margin-') or starts-with(local-name(), 'space-'))]">
4483
+ <xsl:for-each select="xalan:nodeset($sourcecode_attributes)/sourcecode_attributes/@*[not(starts-with(local-name(), 'margin-') or starts-with(local-name(), 'space-') or starts-with(local-name(), 'role'))]">
4481
4484
  <xsl:attribute name="{name()}">
4482
4485
  <xsl:value-of select="."/>
4483
4486
  </xsl:attribute>
@@ -4489,8 +4492,8 @@
4489
4492
  </xsl:template>
4490
4493
 
4491
4494
  <!-- second td with sourcecode -->
4492
- <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table//mn:tr/*[local-name() = 'td'][preceding-sibling::*]" priority="2"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
4493
- <fo:table-cell>
4495
+ <xsl:template match="mn:sourcecode[@linenums = 'true']/mn:table//mn:tr/*[local-name() = 'td'][preceding-sibling::*]" priority="3"> <!-- *[local-name()='table'][@type = 'sourcecode'] -->
4496
+ <fo:table-cell role="SKIP">
4494
4497
  <fo:block role="SKIP">
4495
4498
  <xsl:apply-templates/>
4496
4499
  </fo:block>
@@ -5076,7 +5079,7 @@
5076
5079
  <xsl:param name="value"/>
5077
5080
  <xsl:variable name="add_width" select="string-length($value) * 20"/>
5078
5081
  <xsl:variable name="maxwidth" select="60 + $add_width"/>
5079
- <fo:instream-foreign-object fox:alt-text="OpeningTag" baseline-shift="-10%"><!-- alignment-baseline="middle" -->
5082
+ <fo:instream-foreign-object fox:alt-text="OpeningTag" baseline-shift="-10%" fox:placement="Inline"><!-- alignment-baseline="middle" -->
5080
5083
  <xsl:attribute name="height">3.5mm</xsl:attribute> <!-- 5mm -->
5081
5084
  <xsl:attribute name="content-width">100%</xsl:attribute>
5082
5085
  <xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
@@ -5305,11 +5308,12 @@
5305
5308
  <xsl:choose>
5306
5309
 
5307
5310
  <xsl:when test="ancestor::mn:sourcecode[@linenums = 'true'] and ancestor::*[local-name() = 'td'][1][not(preceding-sibling::*)]"> <!-- pre in the first td in the table with @linenums = 'true' -->
5311
+ <xsl:attribute name="role">SKIP</xsl:attribute>
5308
5312
  <xsl:if test="ancestor::mn:tr[1]/following-sibling::mn:tr"> <!-- is current tr isn't last -->
5309
5313
  <xsl:attribute name="margin-top">0pt</xsl:attribute>
5310
5314
  <xsl:attribute name="margin-bottom">0pt</xsl:attribute>
5311
5315
  </xsl:if>
5312
- <fo:instream-foreign-object fox:alt-text="{.}" content-width="95%">
5316
+ <fo:instream-foreign-object fox:alt-text="{.}" content-width="95%" fox:placement="Inline" role="artifact">
5313
5317
  <math xmlns="http://www.w3.org/1998/Math/MathML">
5314
5318
  <mtext><xsl:value-of select="."/></mtext>
5315
5319
  </math>
@@ -6870,19 +6874,22 @@
6870
6874
  <xsl:if test="normalize-space() != ''">
6871
6875
 
6872
6876
  <fo:block xsl:use-attribute-sets="table-name-style">
6873
-
6874
6877
  <xsl:call-template name="refine_table-name-style">
6875
6878
  <xsl:with-param name="continued" select="$continued"/>
6876
6879
  </xsl:call-template>
6877
6880
 
6878
- <xsl:choose>
6879
- <xsl:when test="$continued = 'true'">
6880
- </xsl:when>
6881
- <xsl:otherwise>
6882
- <xsl:apply-templates/>
6883
- </xsl:otherwise>
6884
- </xsl:choose>
6881
+ <!-- <Caption><P> tags, see https://github.com/metanorma/metanorma-pdfa/issues/81 -->
6882
+ <fo:block role="P">
6885
6883
 
6884
+ <xsl:choose>
6885
+ <xsl:when test="$continued = 'true'">
6886
+ </xsl:when>
6887
+ <xsl:otherwise>
6888
+ <xsl:apply-templates/>
6889
+ </xsl:otherwise>
6890
+ </xsl:choose>
6891
+
6892
+ </fo:block>
6886
6893
  </fo:block>
6887
6894
 
6888
6895
  <!-- <xsl:if test="$namespace = 'bsi' or $namespace = 'pas' or $namespace = 'iec' or $namespace = 'iso'"> -->
@@ -7366,7 +7373,7 @@
7366
7373
 
7367
7374
  <xsl:variable name="tableWithNotesAndFootnotes">
7368
7375
 
7369
- <fo:table keep-with-previous="always" role="SKIP">
7376
+ <fo:table keep-with-previous="always" role="TFoot">
7370
7377
  <xsl:for-each select="xalan:nodeset($table_attributes)/table_attributes/@*">
7371
7378
  <xsl:variable name="name" select="local-name()"/>
7372
7379
  <xsl:choose>
@@ -7404,14 +7411,14 @@
7404
7411
  </xsl:choose>
7405
7412
 
7406
7413
  <fo:table-body role="SKIP">
7407
- <fo:table-row role="SKIP">
7414
+ <fo:table-row>
7408
7415
  <xsl:for-each select="ancestor::mn:table[1]">
7409
7416
  <xsl:call-template name="setTableStyles">
7410
7417
  <xsl:with-param name="scope">ancestor_table</xsl:with-param>
7411
7418
  </xsl:call-template>
7412
7419
  </xsl:for-each>
7413
7420
 
7414
- <fo:table-cell xsl:use-attribute-sets="table-footer-cell-style" number-columns-spanned="{$cols-count}" role="SKIP">
7421
+ <fo:table-cell xsl:use-attribute-sets="table-footer-cell-style" number-columns-spanned="{$cols-count}">
7415
7422
 
7416
7423
  <xsl:call-template name="refine_table-footer-cell-style"/>
7417
7424
 
@@ -9756,6 +9763,16 @@
9756
9763
  </xsl:if>
9757
9764
  </xsl:template> <!-- refine_note-style -->
9758
9765
 
9766
+ <xsl:attribute-set name="note-block-style">
9767
+ <xsl:attribute name="role">SKIP</xsl:attribute>
9768
+ </xsl:attribute-set> <!-- note-block-style -->
9769
+
9770
+ <xsl:template name="refine_note-block-style">
9771
+ <xsl:if test="ancestor::mn:figure">
9772
+ <xsl:attribute name="margin-left"><xsl:value-of select="$tableAnnotationIndent"/></xsl:attribute>
9773
+ </xsl:if>
9774
+ </xsl:template> <!-- refine_note-block-style -->
9775
+
9759
9776
  <xsl:variable name="note-body-indent">10mm</xsl:variable>
9760
9777
  <xsl:variable name="note-body-indent-table">5mm</xsl:variable>
9761
9778
 
@@ -9830,9 +9847,9 @@
9830
9847
  <xsl:call-template name="refine_note-style"/>
9831
9848
 
9832
9849
  <fo:block-container margin-left="0mm" margin-right="0mm" role="SKIP">
9833
- <fo:block role="SKIP">
9850
+ <fo:block xsl:use-attribute-sets="note-block-style">
9834
9851
 
9835
- <xsl:call-template name="refine_note_block_style"/>
9852
+ <xsl:call-template name="refine_note-block-style"/>
9836
9853
 
9837
9854
  <fo:inline xsl:use-attribute-sets="note-name-style">
9838
9855
 
@@ -9871,12 +9888,6 @@
9871
9888
  </fo:block-container>
9872
9889
  </xsl:template>
9873
9890
 
9874
- <xsl:template name="refine_note_block_style">
9875
- <xsl:if test="ancestor::mn:figure">
9876
- <xsl:attribute name="margin-left"><xsl:value-of select="$tableAnnotationIndent"/></xsl:attribute>
9877
- </xsl:if>
9878
- </xsl:template> <!-- refine_note_block_style -->
9879
-
9880
9891
  <xsl:template match="mn:note/mn:p">
9881
9892
  <xsl:variable name="num"><xsl:number/></xsl:variable>
9882
9893
  <xsl:choose>
@@ -9997,9 +10008,9 @@
9997
10008
  <!-- ====== -->
9998
10009
 
9999
10010
  <xsl:attribute-set name="quote-container-style">
10011
+ <xsl:attribute name="role">BlockQuote</xsl:attribute>
10000
10012
  <xsl:attribute name="margin-left">12mm</xsl:attribute>
10001
10013
  <xsl:attribute name="margin-right">12mm</xsl:attribute>
10002
- <xsl:attribute name="role">SKIP</xsl:attribute>
10003
10014
  <xsl:attribute name="margin-bottom">6pt</xsl:attribute>
10004
10015
  <xsl:attribute name="margin-left">0mm</xsl:attribute>
10005
10016
  <xsl:attribute name="margin-right">0mm</xsl:attribute>
@@ -10023,6 +10034,7 @@
10023
10034
  </xsl:template> <!-- refine_quote-style -->
10024
10035
 
10025
10036
  <xsl:attribute-set name="quote-source-style">
10037
+ <xsl:attribute name="role">Caption</xsl:attribute>
10026
10038
  <xsl:attribute name="text-align">right</xsl:attribute>
10027
10039
  <xsl:attribute name="margin-right">-12mm</xsl:attribute>
10028
10040
  </xsl:attribute-set> <!-- quote-source-style -->
@@ -10056,7 +10068,7 @@
10056
10068
  <xsl:call-template name="refine_quote-style"/>
10057
10069
 
10058
10070
  <fo:block-container margin-left="0mm" margin-right="0mm" role="SKIP">
10059
- <fo:block role="BlockQuote">
10071
+ <fo:block role="SKIP"> <!-- BlockQuote -->
10060
10072
  <xsl:apply-templates select="./node()[not(self::mn:author) and not(self::mn:fmt-source) and not(self::mn:attribution)]"/> <!-- process all nested nodes, except author and source -->
10061
10073
  </fo:block>
10062
10074
  </fo:block-container>
@@ -10065,11 +10077,15 @@
10065
10077
  <fo:block-container margin-left="0mm" margin-right="0mm" role="SKIP">
10066
10078
  <fo:block xsl:use-attribute-sets="quote-source-style">
10067
10079
  <xsl:call-template name="refine_quote-source-style"/>
10068
- <!-- — ISO, ISO 7301:2011, Clause 1 -->
10069
- <xsl:apply-templates select="mn:author"/>
10070
- <xsl:apply-templates select="mn:fmt-source"/>
10071
- <!-- added for https://github.com/metanorma/isodoc/issues/607 -->
10072
- <xsl:apply-templates select="mn:attribution/mn:p/node()"/>
10080
+
10081
+ <!-- <Caption><P> tags, see https://github.com/metanorma/metanorma-pdfa/issues/81 -->
10082
+ <fo:block role="P">
10083
+ <!-- ISO, ISO 7301:2011, Clause 1 -->
10084
+ <xsl:apply-templates select="mn:author"/>
10085
+ <xsl:apply-templates select="mn:fmt-source"/>
10086
+ <!-- added for https://github.com/metanorma/isodoc/issues/607 -->
10087
+ <xsl:apply-templates select="mn:attribution/mn:p/node()"/>
10088
+ </fo:block>
10073
10089
  </fo:block>
10074
10090
  </fo:block-container>
10075
10091
  </xsl:if>
@@ -10545,7 +10561,7 @@
10545
10561
 
10546
10562
  <!-- debug scale='<xsl:value-of select="$scale"/>', indent='<xsl:value-of select="$indent"/>' -->
10547
10563
 
10548
- <fo:external-graphic src="{$src}" vertical-align="middle">
10564
+ <fo:external-graphic src="{$src}" vertical-align="middle" fox:placement="Inline">
10549
10565
  <xsl:call-template name="addAltText"/>
10550
10566
 
10551
10567
  <xsl:if test="parent::mn:logo"> <!-- publisher's logo -->
@@ -10610,7 +10626,7 @@
10610
10626
  <xsl:choose>
10611
10627
  <xsl:when test="$isDeleted = 'true'">
10612
10628
  <!-- enclose in svg -->
10613
- <fo:instream-foreign-object>
10629
+ <fo:instream-foreign-object fox:placement="Block">
10614
10630
  <xsl:attribute name="width">100%</xsl:attribute>
10615
10631
  <xsl:attribute name="content-height">100%</xsl:attribute>
10616
10632
  <xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
@@ -10631,7 +10647,7 @@
10631
10647
  <xsl:value-of select="concat('scale=', $scale,', indent=', $indent)"/>
10632
10648
  </fo:block> -->
10633
10649
 
10634
- <fo:external-graphic src="{$src}">
10650
+ <fo:external-graphic src="{$src}" fox:placement="Block">
10635
10651
  <xsl:call-template name="addAltText"/>
10636
10652
 
10637
10653
  <xsl:choose>
@@ -10970,7 +10986,7 @@
10970
10986
  </xsl:if>
10971
10987
  <fo:block text-depth="0" line-height="0" font-size="0">
10972
10988
 
10973
- <fo:instream-foreign-object fox:alt-text="{$alt-text}">
10989
+ <fo:instream-foreign-object fox:alt-text="{$alt-text}" fox:placement="Block">
10974
10990
  <xsl:attribute name="width">100%</xsl:attribute>
10975
10991
  <xsl:attribute name="content-height">100%</xsl:attribute>
10976
10992
  <xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
@@ -11019,7 +11035,7 @@
11019
11035
  <xsl:copy>
11020
11036
  <xsl:copy-of select="@*"/>
11021
11037
  <!-- <fo:block xsl:use-attribute-sets="image-style"> -->
11022
- <fo:instream-foreign-object fox:alt-text="{$alt-text}">
11038
+ <fo:instream-foreign-object fox:alt-text="{$alt-text}" fox:placement="Block">
11023
11039
 
11024
11040
  <xsl:choose>
11025
11041
  <xsl:when test="$image_class = 'corrigenda-tag'">
@@ -11084,6 +11100,10 @@
11084
11100
  <xsl:attribute name="content-height"><xsl:value-of select="round($scale_x * $scale_y * 100)"/>%</xsl:attribute>
11085
11101
  </xsl:if>
11086
11102
 
11103
+ <xsl:if test="self::fo:inline">
11104
+ <xsl:attribute name="fox:placement">Inline</xsl:attribute>
11105
+ </xsl:if>
11106
+
11087
11107
  <xsl:copy-of select="$svg_content"/>
11088
11108
 
11089
11109
  <!-- <debug>
@@ -11359,10 +11379,12 @@
11359
11379
  <xsl:template match="mn:figure/mn:fmt-name | mn:image/mn:fmt-name">
11360
11380
  <xsl:if test="normalize-space() != ''">
11361
11381
  <fo:block xsl:use-attribute-sets="figure-name-style">
11362
-
11363
11382
  <xsl:call-template name="refine_figure-name-style"/>
11364
11383
 
11365
- <xsl:apply-templates/>
11384
+ <!-- <Caption><P> tags, see https://github.com/metanorma/metanorma-pdfa/issues/81 -->
11385
+ <fo:block role="P">
11386
+ <xsl:apply-templates/>
11387
+ </fo:block>
11366
11388
  </fo:block>
11367
11389
  </xsl:if>
11368
11390
  </xsl:template>
@@ -11384,6 +11406,7 @@
11384
11406
 
11385
11407
  <!-- Formula's styles -->
11386
11408
  <xsl:attribute-set name="formula-style">
11409
+ <xsl:attribute name="role">P</xsl:attribute>
11387
11410
  <xsl:attribute name="margin-top">6pt</xsl:attribute>
11388
11411
  <xsl:attribute name="margin-bottom">12pt</xsl:attribute>
11389
11412
  </xsl:attribute-set> <!-- formula-style -->
@@ -11392,6 +11415,7 @@
11392
11415
  </xsl:template>
11393
11416
 
11394
11417
  <xsl:attribute-set name="formula-stem-block-style">
11418
+ <xsl:attribute name="role">SKIP</xsl:attribute>
11395
11419
  <xsl:attribute name="text-align">center</xsl:attribute>
11396
11420
  </xsl:attribute-set> <!-- formula-stem-block-style -->
11397
11421
 
@@ -11399,6 +11423,7 @@
11399
11423
  </xsl:template> <!-- refine_formula-stem-block-style -->
11400
11424
 
11401
11425
  <xsl:attribute-set name="formula-stem-number-style">
11426
+ <xsl:attribute name="role">Span</xsl:attribute>
11402
11427
  <xsl:attribute name="text-align">right</xsl:attribute>
11403
11428
  </xsl:attribute-set> <!-- formula-stem-number-style -->
11404
11429
  <!-- End Formula's styles -->
@@ -11407,12 +11432,25 @@
11407
11432
  </xsl:template>
11408
11433
 
11409
11434
  <xsl:attribute-set name="mathml-style">
11435
+ <xsl:attribute name="role">Formula</xsl:attribute>
11410
11436
  <xsl:attribute name="font-family">STIX Two Math</xsl:attribute>
11411
11437
  </xsl:attribute-set>
11412
11438
 
11413
11439
  <xsl:template name="refine_mathml-style">
11414
11440
  </xsl:template>
11415
11441
 
11442
+ <xsl:attribute-set name="mathml-instream-foreign-object-style">
11443
+ <xsl:attribute name="fox:alt-text">Math</xsl:attribute>
11444
+ <xsl:attribute name="fox:actual-text">Math</xsl:attribute>
11445
+ <xsl:attribute name="fox:placement">Inline</xsl:attribute>
11446
+ </xsl:attribute-set> <!-- mathml-instream-foreign-object-style -->
11447
+
11448
+ <xsl:template name="refine_mathml-instream-foreign-object-style">
11449
+ <xsl:if test="ancestor::mn:formula">
11450
+ <xsl:attribute name="fox:placement">Block</xsl:attribute>
11451
+ </xsl:if>
11452
+ </xsl:template> <!-- refine_mathml-instream-foreign-object-style -->
11453
+
11416
11454
  <!-- ====== -->
11417
11455
  <!-- formula -->
11418
11456
  <!-- ====== -->
@@ -11428,7 +11466,7 @@
11428
11466
  </xsl:if>
11429
11467
  <fo:block-container margin-left="0mm" role="SKIP">
11430
11468
  <xsl:call-template name="setNamedDestination"/>
11431
- <fo:block id="{@id}">
11469
+ <fo:block id="{@id}" role="SKIP">
11432
11470
  <xsl:apply-templates select="node()[not(self::mn:fmt-name)]"/> <!-- formula's number will be process in 'stem' template -->
11433
11471
  </fo:block>
11434
11472
  </fo:block-container>
@@ -11461,22 +11499,22 @@
11461
11499
 
11462
11500
  <xsl:call-template name="refine_formula-style"/>
11463
11501
 
11464
- <fo:table table-layout="fixed" width="100%">
11502
+ <fo:table table-layout="fixed" width="100%" role="SKIP">
11465
11503
  <fo:table-column column-width="95%"/>
11466
11504
  <fo:table-column column-width="5%"/>
11467
- <fo:table-body>
11468
- <fo:table-row>
11469
- <fo:table-cell display-align="center">
11470
- <fo:block xsl:use-attribute-sets="formula-stem-block-style" role="SKIP">
11505
+ <fo:table-body role="SKIP">
11506
+ <fo:table-row role="SKIP">
11507
+ <fo:table-cell display-align="center" role="SKIP">
11508
+ <fo:block xsl:use-attribute-sets="formula-stem-block-style">
11471
11509
 
11472
11510
  <xsl:call-template name="refine_formula-stem-block-style"/>
11473
11511
 
11474
11512
  <xsl:apply-templates/>
11475
11513
  </fo:block>
11476
11514
  </fo:table-cell>
11477
- <fo:table-cell display-align="center">
11515
+ <fo:table-cell display-align="center" role="SKIP">
11478
11516
 
11479
- <fo:block xsl:use-attribute-sets="formula-stem-number-style" role="SKIP">
11517
+ <fo:block xsl:use-attribute-sets="formula-stem-number-style">
11480
11518
 
11481
11519
  <xsl:for-each select="../mn:fmt-name">
11482
11520
  <xsl:call-template name="setIDforNamedDestination"/>
@@ -11624,9 +11662,9 @@
11624
11662
  <xsl:apply-templates select="." mode="mathml"/>
11625
11663
  </xsl:variable>
11626
11664
 
11627
- <fo:instream-foreign-object fox:alt-text="Math" fox:actual-text="Math">
11665
+ <fo:instream-foreign-object xsl:use-attribute-sets="mathml-instream-foreign-object-style">
11628
11666
 
11629
- <xsl:call-template name="refine_mathml_insteam_object_style"/>
11667
+ <xsl:call-template name="refine_mathml-instream-foreign-object-style"/>
11630
11668
 
11631
11669
  <xsl:if test="$isGenerateTableIF = 'false'">
11632
11670
  <!-- put MathML in Actual Text -->
@@ -11650,9 +11688,6 @@
11650
11688
  </fo:instream-foreign-object>
11651
11689
  </xsl:template>
11652
11690
 
11653
- <xsl:template name="refine_mathml_insteam_object_style">
11654
- </xsl:template> <!-- refine_mathml_insteam_object_style -->
11655
-
11656
11691
  <xsl:template match="mathml:*" mode="mathml_actual_text">
11657
11692
  <!-- <xsl:text>a+b</xsl:text> -->
11658
11693
  <xsl:text>&lt;</xsl:text>
@@ -12778,8 +12813,10 @@
12778
12813
 
12779
12814
  </xsl:template> <!-- references[not(@normative='true')]/bibitem -->
12780
12815
 
12816
+ <!-- commented 2026-08-06: from https://github.com/metanorma/metanorma-standoc/issues/1140:
12817
+ Presentation XML will no longer contain notes following bibitem, those notes will have been moved in Presentation XML to inside bibitem, and then duplicated to inside formattedref. -->
12781
12818
  <!-- bibitem's notes will be processing in 'processBibitemFollowingNotes' -->
12782
- <xsl:template match="mn:references/mn:note" priority="2"/> <!-- [not(@normative='true')] -->
12819
+ <!-- <xsl:template match="mn:references/mn:note" priority="2"/>--> <!-- [not(@normative='true')] -->
12783
12820
 
12784
12821
  <xsl:template name="insertListItem_Bibitem">
12785
12822
  <xsl:choose>
@@ -13454,7 +13491,7 @@
13454
13491
  <xsl:call-template name="set_id_metanorma_form_item">
13455
13492
  <xsl:with-param name="form_item_type" select="$form_item_type"/>
13456
13493
  </xsl:call-template>
13457
- <fo:instream-foreign-object fox:alt-text="Box" baseline-shift="-10%">
13494
+ <fo:instream-foreign-object fox:alt-text="Box" baseline-shift="-10%" fox:placement="Inline">
13458
13495
  <xsl:attribute name="height">3.5mm</xsl:attribute>
13459
13496
  <xsl:attribute name="content-width">100%</xsl:attribute>
13460
13497
  <xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
@@ -13481,7 +13518,7 @@
13481
13518
  <xsl:call-template name="set_id_metanorma_form_item">
13482
13519
  <xsl:with-param name="form_item_type" select="$form_item_type"/>
13483
13520
  </xsl:call-template>
13484
- <fo:instream-foreign-object fox:alt-text="Box" baseline-shift="-10%">
13521
+ <fo:instream-foreign-object fox:alt-text="Box" baseline-shift="-10%" fox:placement="Inline">
13485
13522
  <xsl:attribute name="height">3.5mm</xsl:attribute>
13486
13523
  <xsl:attribute name="content-width">100%</xsl:attribute>
13487
13524
  <xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
@@ -13745,7 +13782,9 @@
13745
13782
  </xsl:variable>
13746
13783
  <mnx:example id="{@id}" alt-text="{normalize-space($example_name)}">
13747
13784
  <xsl:element name="fmt-name" namespace="{$namespace_full}">
13748
- <xsl:value-of select="mn:fmt-xref-label[@container]"/>
13785
+ <xsl:call-template name="capitalize"><!-- https://github.com/metanorma/metanorma-pdfa/issues/72 -->
13786
+ <xsl:with-param name="str" select="mn:fmt-xref-label[@container]"/>
13787
+ </xsl:call-template>
13749
13788
  <xsl:if test="normalize-space($example_name) != ''">
13750
13789
  <xsl:value-of select="mn:fmt-name/mn:span[@class = 'fmt-caption-delim']"/>
13751
13790
  <xsl:copy-of select="$example_name"/>
@@ -15639,7 +15678,8 @@
15639
15678
  <xsl:template match="//mn:metanorma/mn:preface/*" priority="2" name="preface_node"> <!-- /*/mn:preface/* -->
15640
15679
  <fo:block break-after="page"/>
15641
15680
  <xsl:call-template name="setNamedDestination"/>
15642
- <fo:block>
15681
+ <fo:block role="Sect">
15682
+ <xsl:call-template name="addTagElementT"/>
15643
15683
  <xsl:call-template name="setId"/>
15644
15684
  <xsl:call-template name="addReviewHelper"/>
15645
15685
  <xsl:apply-templates/>
@@ -15728,7 +15768,7 @@
15728
15768
 
15729
15769
  <xsl:template match="mn:blacksquare" name="blacksquare">
15730
15770
  <fo:inline padding-right="2.5mm" baseline-shift="5%">
15731
- <fo:instream-foreign-object content-height="2mm" content-width="2mm" fox:alt-text="Quad">
15771
+ <fo:instream-foreign-object content-height="2mm" content-width="2mm" fox:alt-text="Quad" fox:placement="Inline">
15732
15772
  <svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" viewBox="0 0 2 2">
15733
15773
  <rect x="0" y="0" width="2" height="2" fill="black"/>
15734
15774
  </svg>
@@ -16710,13 +16750,13 @@
16710
16750
  <xsl:param name="bitmap_width" select="$pageWidth"/>
16711
16751
  <xsl:choose>
16712
16752
  <xsl:when test="*[local-name() = 'svg'] or java:endsWith(java:java.lang.String.new(@src), '.svg')">
16713
- <fo:instream-foreign-object fox:alt-text="Image Front">
16753
+ <fo:instream-foreign-object fox:alt-text="Image Front" fox:placement="Block">
16714
16754
  <xsl:attribute name="content-height"><xsl:value-of select="$svg_content_height"/>mm</xsl:attribute>
16715
16755
  <xsl:call-template name="getSVG"/>
16716
16756
  </fo:instream-foreign-object>
16717
16757
  </xsl:when>
16718
16758
  <xsl:when test="starts-with(@src, 'data:application/pdf;base64')">
16719
- <fo:external-graphic src="{@src}" fox:alt-text="Image Front"/>
16759
+ <fo:external-graphic src="{@src}" fox:alt-text="Image Front" fox:placement="Block"/>
16720
16760
  </xsl:when>
16721
16761
  <xsl:otherwise> <!-- bitmap image -->
16722
16762
  <xsl:variable name="coverimage_src" select="normalize-space(@src)"/>
@@ -16726,7 +16766,7 @@
16726
16766
  <xsl:with-param name="src" select="$coverimage_src"/>
16727
16767
  </xsl:call-template>
16728
16768
  </xsl:variable>
16729
- <fo:external-graphic src="{$coverpage}" width="{$bitmap_width}mm" content-height="scale-to-fit" scaling="uniform" fox:alt-text="Image Front"/>
16769
+ <fo:external-graphic src="{$coverpage}" width="{$bitmap_width}mm" content-height="scale-to-fit" scaling="uniform" fox:alt-text="Image Front" fox:placement="Block"/>
16730
16770
  </xsl:if>
16731
16771
  </xsl:otherwise>
16732
16772
  </xsl:choose>
@@ -954,30 +954,36 @@ in case the table cannot be rendered accessibly (HTML 5)</a:documentation>
954
954
  <define name="TdBody">
955
955
  <choice>
956
956
  <zeroOrMore>
957
- <group>
958
- <a:documentation>Table cell is a block</a:documentation>
957
+ <choice>
958
+ <a:documentation>Table cell is a block; footnotes admitted inline (metanorma-model-iso#154)</a:documentation>
959
959
  <ref name="TextElement"/>
960
- </group>
960
+ <ref name="fn"/>
961
+ </choice>
961
962
  </zeroOrMore>
962
963
  <oneOrMore>
963
- <ref name="paragraph-with-footnote">
964
- <a:documentation>Table cell contains a block</a:documentation>
965
- </ref>
964
+ <choice>
965
+ <a:documentation>Table cell contains a block; notes admitted alongside paragraphs (metanorma-model-iso#157)</a:documentation>
966
+ <ref name="paragraph-with-footnote"/>
967
+ <ref name="note"/>
968
+ </choice>
966
969
  </oneOrMore>
967
970
  </choice>
968
971
  </define>
969
972
  <define name="TdNoIdBody">
970
973
  <choice>
971
974
  <zeroOrMore>
972
- <group>
973
- <a:documentation>Table cell is a block</a:documentation>
975
+ <choice>
976
+ <a:documentation>Table cell is a block; footnotes admitted inline (metanorma-model-iso#154)</a:documentation>
974
977
  <ref name="TextElement"/>
975
- </group>
978
+ <ref name="fn"/>
979
+ </choice>
976
980
  </zeroOrMore>
977
981
  <oneOrMore>
978
- <ref name="paragraph-with-footnote-no-id">
979
- <a:documentation>Table cell contains a block</a:documentation>
980
- </ref>
982
+ <choice>
983
+ <a:documentation>Table cell contains a block; notes admitted alongside paragraphs (metanorma-model-iso#157)</a:documentation>
984
+ <ref name="paragraph-with-footnote-no-id"/>
985
+ <ref name="note-no-id"/>
986
+ </choice>
981
987
  </oneOrMore>
982
988
  </choice>
983
989
  </define>
@@ -1030,16 +1036,9 @@ in case the table cannot be rendered accessibly (HTML 5)</a:documentation>
1030
1036
  </ref>
1031
1037
  </optional>
1032
1038
  <oneOrMore>
1033
- <choice>
1039
+ <ref name="ExampleBodyContent">
1034
1040
  <a:documentation>Content of the example</a:documentation>
1035
- <ref name="formula"/>
1036
- <ref name="ul"/>
1037
- <ref name="ol"/>
1038
- <ref name="dl"/>
1039
- <ref name="quote"/>
1040
- <ref name="sourcecode"/>
1041
- <ref name="paragraph-with-footnote"/>
1042
- </choice>
1041
+ </ref>
1043
1042
  </oneOrMore>
1044
1043
  <zeroOrMore>
1045
1044
  <ref name="note">
@@ -1047,6 +1046,23 @@ in case the table cannot be rendered accessibly (HTML 5)</a:documentation>
1047
1046
  </ref>
1048
1047
  </zeroOrMore>
1049
1048
  </define>
1049
+ <define name="ExampleBodyContent">
1050
+ <a:documentation>Content alternatives of an example. Named as an extension hook: higher
1051
+ layers may admit further alternatives additively (|=) without copying the
1052
+ example model (metanorma-model-iso#160). note is admitted interleaved as
1053
+ attested authoring practice (metanorma-model-iso#157, maintainer hierarchy
1054
+ reservation recorded there)</a:documentation>
1055
+ <choice>
1056
+ <ref name="formula"/>
1057
+ <ref name="ul"/>
1058
+ <ref name="ol"/>
1059
+ <ref name="dl"/>
1060
+ <ref name="quote"/>
1061
+ <ref name="sourcecode"/>
1062
+ <ref name="paragraph-with-footnote"/>
1063
+ <ref name="note"/>
1064
+ </choice>
1065
+ </define>
1050
1066
  <define name="ExampleNoIdBody">
1051
1067
  <optional>
1052
1068
  <ref name="tname">
@@ -1054,16 +1070,9 @@ in case the table cannot be rendered accessibly (HTML 5)</a:documentation>
1054
1070
  </ref>
1055
1071
  </optional>
1056
1072
  <oneOrMore>
1057
- <choice>
1073
+ <ref name="ExampleNoIdBodyContent">
1058
1074
  <a:documentation>Content of the example</a:documentation>
1059
- <ref name="formula-no-id"/>
1060
- <ref name="ul-no-id"/>
1061
- <ref name="ol-no-id"/>
1062
- <ref name="dl-no-id"/>
1063
- <ref name="quote-no-id"/>
1064
- <ref name="sourcecode-no-id"/>
1065
- <ref name="paragraph-with-footnote-no-id"/>
1066
- </choice>
1075
+ </ref>
1067
1076
  </oneOrMore>
1068
1077
  <zeroOrMore>
1069
1078
  <ref name="note-no-id">
@@ -1071,6 +1080,20 @@ in case the table cannot be rendered accessibly (HTML 5)</a:documentation>
1071
1080
  </ref>
1072
1081
  </zeroOrMore>
1073
1082
  </define>
1083
+ <define name="ExampleNoIdBodyContent">
1084
+ <a:documentation>Content alternatives of the no-id example variant; extension hook as
1085
+ ExampleBodyContent (metanorma-model-iso#160)</a:documentation>
1086
+ <choice>
1087
+ <ref name="formula-no-id"/>
1088
+ <ref name="ul-no-id"/>
1089
+ <ref name="ol-no-id"/>
1090
+ <ref name="dl-no-id"/>
1091
+ <ref name="quote-no-id"/>
1092
+ <ref name="sourcecode-no-id"/>
1093
+ <ref name="paragraph-with-footnote-no-id"/>
1094
+ <ref name="note-no-id"/>
1095
+ </choice>
1096
+ </define>
1074
1097
  <define name="admonition">
1075
1098
  <a:documentation>A sidebar block outside of the main flow of text, conveying particular warnings or supplementary text to the reader</a:documentation>
1076
1099
  <element name="admonition">
@@ -50,6 +50,24 @@
50
50
  </choice>
51
51
  </element>
52
52
  </define>
53
+ <define name="formattedref">
54
+ <a:documentation>Footnotes are admitted in formatted references in the standoc context:
55
+ free-form bibliography entries may carry authored footnotes
56
+ (metanorma-model-iso#154)</a:documentation>
57
+ <element name="formattedref">
58
+ <optional>
59
+ <attribute name="format">
60
+ <a:documentation>format of formatted reference; Metanorma assumes references are formatted as Metanorma XML</a:documentation>
61
+ </attribute>
62
+ </optional>
63
+ <oneOrMore>
64
+ <choice>
65
+ <ref name="TextElement"/>
66
+ <ref name="fn"/>
67
+ </choice>
68
+ </oneOrMore>
69
+ </element>
70
+ </define>
53
71
  </include>
54
72
  <define name="ext">
55
73
  <a:documentation>The extension point of the bibliographic description of a standardisation document</a:documentation>
@@ -1,6 +1,6 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
2
  <grammar xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0" xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
3
- <!-- VERSION v2.2.0 -->
3
+ <!-- VERSION v2.3.0 -->
4
4
 
5
5
  <!--
6
6
  ALERT: cannot have root comments, because of https://github.com/metanorma/metanorma/issues/437
@@ -27,11 +27,89 @@
27
27
  <define name="amend">
28
28
  <a:documentation>Block expressing a machine-readable change in a document</a:documentation>
29
29
  <element name="amend">
30
+ <ref name="OptionalId"/>
30
31
  <ref name="BlockAttributes"/>
31
- <ref name="AmendType"/>
32
+ <attribute name="change">
33
+ <a:documentation>The type of change described in this block</a:documentation>
34
+ <choice>
35
+ <value>add</value>
36
+ <value>modify</value>
37
+ <value>delete</value>
38
+ <value>replace</value>
39
+ </choice>
40
+ </attribute>
41
+ <optional>
42
+ <attribute name="path"/>
43
+ </optional>
44
+ <optional>
45
+ <attribute name="path_end"/>
46
+ </optional>
47
+ <optional>
48
+ <attribute name="title"/>
49
+ </optional>
50
+ <optional>
51
+ <attribute name="position">
52
+ <choice>
53
+ <value>before</value>
54
+ <value>after</value>
55
+ </choice>
56
+ </attribute>
57
+ </optional>
58
+ <optional>
59
+ <element name="location">
60
+ <a:documentation>The location(s) in the original document which have undergone the change described in this block</a:documentation>
61
+ <zeroOrMore>
62
+ <choice>
63
+ <ref name="locality"/>
64
+ <ref name="localityStack"/>
65
+ </choice>
66
+ </zeroOrMore>
67
+ </element>
68
+ </optional>
32
69
  <zeroOrMore>
33
70
  <ref name="autonumber">
34
- <a:documentation>Specification of how blocks of a given class should be autonumbered within an AmendBlock newContent element</a:documentation>
71
+ <a:documentation>Specification of how blocks of a given class should be autonumbered within the newcontent element.
72
+ Precedes the content it numbers</a:documentation>
73
+ </ref>
74
+ </zeroOrMore>
75
+ <zeroOrMore>
76
+ <element name="description">
77
+ <a:documentation>Description(s) of the change described in this block</a:documentation>
78
+ <oneOrMore>
79
+ <ref name="BasicBlock"/>
80
+ </oneOrMore>
81
+ </element>
82
+ </zeroOrMore>
83
+ <optional>
84
+ <element name="newcontent">
85
+ <a:documentation>New content to be added to the document; applicable to add and modify.
86
+ Can be blocks and/or clauses</a:documentation>
87
+ <ref name="OptionalId"/>
88
+ <zeroOrMore>
89
+ <choice>
90
+ <ref name="BasicBlock"/>
91
+ <ref name="clause"/>
92
+ </choice>
93
+ </zeroOrMore>
94
+ </element>
95
+ </optional>
96
+ <zeroOrMore>
97
+ <element name="description">
98
+ <a:documentation>Further description(s) of the change, following the new content
99
+ (e.g. consequential renumbering instructions)</a:documentation>
100
+ <oneOrMore>
101
+ <ref name="BasicBlock"/>
102
+ </oneOrMore>
103
+ </element>
104
+ </zeroOrMore>
105
+ <zeroOrMore>
106
+ <ref name="classification">
107
+ <a:documentation>Classification of the change</a:documentation>
108
+ </ref>
109
+ </zeroOrMore>
110
+ <zeroOrMore>
111
+ <ref name="contributor">
112
+ <a:documentation>Contributor responsible for the change</a:documentation>
35
113
  </ref>
36
114
  </zeroOrMore>
37
115
  </element>
@@ -42,6 +120,27 @@ All IdRefType instances point not to `@id` in Semantic XML, which is the Content
42
120
  but to `@anchor`, the user-supplied cross-reference</a:documentation>
43
121
  <text/>
44
122
  </define>
123
+ <define name="image-no-id">
124
+ <a:documentation>Container for image content: optional ID attributes recursively (for use in Relaton, metadata).
125
+ The embedded SVG content is admitted here as in ImageBody, and is NOT subject to the no-id
126
+ convention of this model family: SVGs carry ids pervasively, and those ids cannot be stripped,
127
+ because they are load-bearing for image-map functionality (svgmap hyperlink targets)</a:documentation>
128
+ <element name="image">
129
+ <ref name="OptionalId"/>
130
+ <ref name="ImageAttributes"/>
131
+ <optional>
132
+ <element name="svg">
133
+ <a:documentation>image can contain SVG XML, which is used to access its identifiers within the Metanorma XML</a:documentation>
134
+ <oneOrMore>
135
+ <choice>
136
+ <text/>
137
+ <ref name="AnyElement"/>
138
+ </choice>
139
+ </oneOrMore>
140
+ </element>
141
+ </optional>
142
+ </element>
143
+ </define>
45
144
  <define name="review">
46
145
  <a:documentation>Generalise BasicDoc element from just review comments, to general annotations;
47
146
  the type attribute defaults to `review` for reviews</a:documentation>
@@ -49,7 +148,7 @@ the type attribute defaults to `review` for reviews</a:documentation>
49
148
  <ref name="RequiredId"/>
50
149
  <ref name="ReviewAttributes"/>
51
150
  <oneOrMore>
52
- <ref name="paragraph">
151
+ <ref name="BasicBlock">
53
152
  <a:documentation>Reviewer comments content</a:documentation>
54
153
  </ref>
55
154
  </oneOrMore>
@@ -85,10 +184,14 @@ the type attribute defaults to `review` for reviews</a:documentation>
85
184
  <define name="section-title">
86
185
  <a:documentation>Title(s) of a clause</a:documentation>
87
186
  <element name="title">
88
- <a:documentation>Title proper for a clause</a:documentation>
187
+ <a:documentation>Title proper for a clause. Footnotes on section headings are admitted
188
+ (metanorma-model-iso#154)</a:documentation>
89
189
  <ref name="RequiredId"/>
90
190
  <zeroOrMore>
91
- <ref name="TextElement"/>
191
+ <choice>
192
+ <ref name="TextElement"/>
193
+ <ref name="fn"/>
194
+ </choice>
92
195
  </zeroOrMore>
93
196
  </element>
94
197
  <zeroOrMore>
@@ -154,13 +257,17 @@ Sources are currently only rendered in metanorma-plateau</a:documentation>
154
257
  <ref name="BlockAttributes"/>
155
258
  <optional>
156
259
  <attribute name="type">
157
- <a:documentation>Type of numbering to be applied to the list items</a:documentation>
260
+ <a:documentation>Type of numbering to be applied to the list items: one of the five named
261
+ numbering styles, or a renderer-native numbering format string passed
262
+ through for the target rendering language to expand (e.g. xml2rfc v2
263
+ format strings such as "R%d", carried through by metanorma-ietf)</a:documentation>
158
264
  <choice>
159
265
  <value>roman</value>
160
266
  <value>alphabet</value>
161
267
  <value>arabic</value>
162
268
  <value>roman_upper</value>
163
269
  <value>alphabet_upper</value>
270
+ <text/>
164
271
  </choice>
165
272
  </attribute>
166
273
  </optional>
@@ -220,30 +327,23 @@ Sources are currently only rendered in metanorma-plateau</a:documentation>
220
327
  </attribute>
221
328
  </optional>
222
329
  </define>
223
- <define name="ExampleBody">
224
- <optional>
225
- <ref name="tname">
226
- <a:documentation>The caption of the example</a:documentation>
227
- </ref>
228
- </optional>
229
- <oneOrMore>
230
- <choice>
231
- <a:documentation>Content of the example</a:documentation>
232
- <ref name="formula"/>
233
- <ref name="ul"/>
234
- <ref name="ol"/>
235
- <ref name="dl"/>
236
- <ref name="quote"/>
237
- <ref name="sourcecode"/>
238
- <ref name="paragraph-with-footnote"/>
239
- <ref name="figure"/>
240
- </choice>
241
- </oneOrMore>
242
- <zeroOrMore>
243
- <ref name="note">
244
- <a:documentation>Notes whose scope is the current block</a:documentation>
245
- </ref>
246
- </zeroOrMore>
330
+ <define name="ExampleBodyContent">
331
+ <a:documentation>Content alternatives of an example in the standoc context: as basicdoc,
332
+ with figure admitted, and note admitted only trailing the example body
333
+ rather than interleaved. The content hook is overridden rather than
334
+ ExampleBody itself, so that the extension seam survives: additive
335
+ admissions (|=) from higher layers, such as illustrative provisions in
336
+ reqt, attach to the definition that governs (metanorma-model-iso#160)</a:documentation>
337
+ <choice>
338
+ <ref name="formula"/>
339
+ <ref name="ul"/>
340
+ <ref name="ol"/>
341
+ <ref name="dl"/>
342
+ <ref name="quote"/>
343
+ <ref name="sourcecode"/>
344
+ <ref name="paragraph-with-footnote"/>
345
+ <ref name="figure"/>
346
+ </choice>
247
347
  </define>
248
348
  <define name="TableBody">
249
349
  <optional>
@@ -413,20 +513,22 @@ and is intended to be referenced by a callout within the source code</a:document
413
513
  <define name="source">
414
514
  <element name="source">
415
515
  <attribute name="status">
416
- <a:documentation>The status of the term as it is used in this document, relative to its definition in the original document</a:documentation>
516
+ <a:documentation>The status of the block content, relative to the source it has been taken from</a:documentation>
417
517
  <ref name="SourceStatusType"/>
418
518
  </attribute>
419
- <attribute name="type">
420
- <a:documentation>The type of the managed term in the present context</a:documentation>
421
- <ref name="SourceTypeType"/>
422
- </attribute>
519
+ <optional>
520
+ <attribute name="type">
521
+ <a:documentation>The type of the source relation. Term-management vocabulary (authoritative/lineage);
522
+ not normally applicable to block attribution, and omitted by the generator for blocks</a:documentation>
523
+ <ref name="SourceTypeType"/>
524
+ </attribute>
525
+ </optional>
423
526
  <ref name="origin">
424
- <a:documentation>The original document and location where the term definition has been obtained from</a:documentation>
527
+ <a:documentation>The original document and location the block content has been obtained from</a:documentation>
425
528
  </ref>
426
529
  <optional>
427
530
  <ref name="modification">
428
- <a:documentation>Any changes that the definition of the term has undergone relative to the original document,
429
- in order to be applicable in this standardisation document</a:documentation>
531
+ <a:documentation>Any changes that the block content has undergone relative to the original document</a:documentation>
430
532
  </ref>
431
533
  </optional>
432
534
  </element>
@@ -852,6 +954,11 @@ titlecase, or lowercase</a:documentation>
852
954
  <a:documentation>Width of the figure block in rendering</a:documentation>
853
955
  </attribute>
854
956
  </optional>
957
+ <optional>
958
+ <attribute name="height">
959
+ <a:documentation>Height of the figure block in rendering</a:documentation>
960
+ </attribute>
961
+ </optional>
855
962
  <ref name="BlockAttributesCore"/>
856
963
  </define>
857
964
  <define name="SourceAttributes" combine="interleave">
@@ -1066,6 +1173,9 @@ parargaph sources are currently only rendered in metanorma-plateau</a:documentat
1066
1173
  <a:documentation>Internal reference (for Metanorma document collections)</a:documentation>
1067
1174
  </define>
1068
1175
  <define name="TextElement" combine="choice">
1176
+ <a:documentation>Form input elements are admitted as inline content generally, mirroring
1177
+ HTML phrasing content: inputs sit inside paragraphs and table cells
1178
+ within forms (metanorma-model-iso#145)</a:documentation>
1069
1179
  <choice>
1070
1180
  <ref name="concept"/>
1071
1181
  <ref name="add"/>
@@ -1073,13 +1183,18 @@ parargaph sources are currently only rendered in metanorma-plateau</a:documentat
1073
1183
  <ref name="span"/>
1074
1184
  <ref name="erefstack"/>
1075
1185
  <ref name="date_inline"/>
1186
+ <ref name="FormInput"/>
1187
+ <ref name="formlabel"/>
1076
1188
  </choice>
1077
1189
  </define>
1078
1190
  <define name="PureTextElement" combine="choice">
1079
1191
  <ref name="passthrough_inline"/>
1080
1192
  </define>
1081
1193
  <define name="NestedTextElement" combine="choice">
1082
- <ref name="erefstack"/>
1194
+ <choice>
1195
+ <ref name="erefstack"/>
1196
+ <ref name="concept"/>
1197
+ </choice>
1083
1198
  </define>
1084
1199
  <define name="passthrough_inline">
1085
1200
  <a:documentation>Inline text not to be processed semantically, and left in the markup of a target rendering language (e.g. raw HTML)</a:documentation>
@@ -1227,9 +1342,26 @@ That concept may be defined as a term within the current document, or it may be
1227
1342
  <ref name="termref">
1228
1343
  <a:documentation>Link to a definition of the term in a termbase</a:documentation>
1229
1344
  </ref>
1345
+ <ref name="errormsg">
1346
+ <a:documentation>Error message inserted by the Metanorma generator, replacing a concept reference
1347
+ that could not be resolved. Only ever emitted by Metanorma itself, never authored;
1348
+ its presence marks the document as not ready for publication</a:documentation>
1349
+ </ref>
1230
1350
  </choice>
1231
1351
  </element>
1232
1352
  </define>
1353
+ <define name="errormsg">
1354
+ <a:documentation>Error message inserted by the Metanorma generator, replacing markup it could not process</a:documentation>
1355
+ <element name="errormsg">
1356
+ <zeroOrMore>
1357
+ <choice>
1358
+ <ref name="PureTextElement"/>
1359
+ <ref name="index"/>
1360
+ <ref name="index-xref"/>
1361
+ </choice>
1362
+ </zeroOrMore>
1363
+ </element>
1364
+ </define>
1233
1365
  <define name="BasicBlock" combine="choice">
1234
1366
  <choice>
1235
1367
  <ref name="requirement"/>
@@ -1272,12 +1404,16 @@ That concept may be defined as a term within the current document, or it may be
1272
1404
  <a:documentation>Input form, for use under HTML</a:documentation>
1273
1405
  <element name="form">
1274
1406
  <ref name="RequiredId"/>
1275
- <attribute name="name">
1276
- <a:documentation>Name of the input form block</a:documentation>
1277
- </attribute>
1278
- <attribute name="action">
1279
- <a:documentation>Action to be taken on submission of the input form</a:documentation>
1280
- </attribute>
1407
+ <optional>
1408
+ <attribute name="name">
1409
+ <a:documentation>Name of the input form block</a:documentation>
1410
+ </attribute>
1411
+ </optional>
1412
+ <optional>
1413
+ <attribute name="action">
1414
+ <a:documentation>Action to be taken on submission of the input form</a:documentation>
1415
+ </attribute>
1416
+ </optional>
1281
1417
  <optional>
1282
1418
  <attribute name="class">
1283
1419
  <a:documentation>Class of input form</a:documentation>
@@ -1289,8 +1425,13 @@ avoid duplicating the custom-class slot in BlockAttributes. Treated like
1289
1425
  figure. See metanorma/metanorma-standoc#1197</a:documentation>
1290
1426
  </ref>
1291
1427
  <zeroOrMore>
1292
- <!-- Input form contents -->
1428
+ <!--
1429
+ Input form contents: as in HTML, a form contains block-level content,
1430
+ with form input elements appearing inline within it
1431
+ -->
1293
1432
  <choice>
1433
+ <ref name="paragraph-with-footnote"/>
1434
+ <ref name="table"/>
1294
1435
  <ref name="TextElement"/>
1295
1436
  <ref name="FormInput"/>
1296
1437
  <ref name="formlabel"/>
@@ -1734,14 +1875,18 @@ terms sections</a:documentation>
1734
1875
  </ref>
1735
1876
  </optional>
1736
1877
  <oneOrMore>
1737
- <zeroOrMore>
1878
+ <choice>
1738
1879
  <ref name="BasicBlock">
1739
- <a:documentation>Prefatory material, may be specific to each definition list</a:documentation>
1880
+ <a:documentation>Prefatory or discursive material; a symbols section may consist of prose only,
1881
+ e.g. deferring to symbols defined in another standard</a:documentation>
1740
1882
  </ref>
1741
- </zeroOrMore>
1742
- <ref name="dl">
1743
- <a:documentation>Definition list containing symbols and abbreviations</a:documentation>
1744
- </ref>
1883
+ <ref name="dl">
1884
+ <a:documentation>Definition list(s) containing symbols and abbreviations</a:documentation>
1885
+ </ref>
1886
+ <ref name="definitions">
1887
+ <a:documentation>Subsections of the symbols section</a:documentation>
1888
+ </ref>
1889
+ </choice>
1745
1890
  </oneOrMore>
1746
1891
  </element>
1747
1892
  </define>
@@ -2011,22 +2156,31 @@ used in document amendments</a:documentation>
2011
2156
  <a:documentation>Type of relation of term applicable</a:documentation>
2012
2157
  <ref name="RelatedTermType"/>
2013
2158
  </attribute>
2014
- <element name="preferred">
2015
- <a:documentation>Preferred designation of the term related to the current term</a:documentation>
2016
- <ref name="Designation"/>
2017
- </element>
2018
2159
  <choice>
2019
- <ref name="eref">
2020
- <a:documentation>Link to a definition of the term in a bibliographic entry</a:documentation>
2021
- </ref>
2022
- <ref name="erefstack">
2023
- <a:documentation>Stack of links to a definition of the term in a bibliographic entry</a:documentation>
2024
- </ref>
2025
- <ref name="xref">
2026
- <a:documentation>Link to a definition of the term in an element of the current document</a:documentation>
2027
- </ref>
2028
- <ref name="termref">
2029
- <a:documentation>Link to a definition of the term in a termbase</a:documentation>
2160
+ <group>
2161
+ <element name="preferred">
2162
+ <a:documentation>Preferred designation of the term related to the current term</a:documentation>
2163
+ <ref name="Designation"/>
2164
+ </element>
2165
+ <choice>
2166
+ <ref name="eref">
2167
+ <a:documentation>Link to a definition of the term in a bibliographic entry</a:documentation>
2168
+ </ref>
2169
+ <ref name="erefstack">
2170
+ <a:documentation>Stack of links to a definition of the term in a bibliographic entry</a:documentation>
2171
+ </ref>
2172
+ <ref name="xref">
2173
+ <a:documentation>Link to a definition of the term in an element of the current document</a:documentation>
2174
+ </ref>
2175
+ <ref name="termref">
2176
+ <a:documentation>Link to a definition of the term in a termbase</a:documentation>
2177
+ </ref>
2178
+ </choice>
2179
+ </group>
2180
+ <ref name="errormsg">
2181
+ <a:documentation>Error message inserted by the Metanorma generator, replacing a related-term
2182
+ reference that could not be resolved. Only ever emitted by Metanorma itself,
2183
+ never authored; its presence marks the document as not ready for publication</a:documentation>
2030
2184
  </ref>
2031
2185
  </choice>
2032
2186
  </element>
@@ -2177,16 +2331,21 @@ used in document amendments</a:documentation>
2177
2331
  <data type="boolean"/>
2178
2332
  </attribute>
2179
2333
  </optional>
2180
- <element name="name">
2181
- <a:documentation>The textual form of the designation</a:documentation>
2182
- <zeroOrMore>
2183
- <choice>
2184
- <ref name="PureTextElement"/>
2185
- <ref name="index"/>
2186
- <ref name="index-xref"/>
2187
- </choice>
2188
- </zeroOrMore>
2189
- </element>
2334
+ <oneOrMore>
2335
+ <element name="name">
2336
+ <a:documentation>The textual form of the designation. Repeated for language variants of the
2337
+ same designation: repetition of name with language attributes replaces the
2338
+ retired variant element (metanorma-standoc#940, metanorma-model-iso#155)</a:documentation>
2339
+ <ref name="LocalizedStringAttributes"/>
2340
+ <zeroOrMore>
2341
+ <choice>
2342
+ <ref name="PureTextElement"/>
2343
+ <ref name="index"/>
2344
+ <ref name="index-xref"/>
2345
+ </choice>
2346
+ </zeroOrMore>
2347
+ </element>
2348
+ </oneOrMore>
2190
2349
  <optional>
2191
2350
  <element name="abbreviation-type">
2192
2351
  <a:documentation>Type of abbreviation that constitutes the designation, according to how it is formed</a:documentation>
@@ -2556,6 +2715,7 @@ to better fit some local requirement, though still with the intent of retaining
2556
2715
  <value>sourcecode</value>
2557
2716
  <value>example</value>
2558
2717
  <value>note</value>
2718
+ <value>clause</value>
2559
2719
  </choice>
2560
2720
  </attribute>
2561
2721
  <text>
@@ -1,6 +1,6 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
2
  <grammar xmlns="http://relaxng.org/ns/structure/1.0">
3
- <include href="isodoc.rng">
3
+ <include href="standoc.rng">
4
4
  <define name="sections">
5
5
  <element name="sections">
6
6
  <zeroOrMore>
@@ -35,9 +35,12 @@ the tag name of the top level containers</a:documentation>
35
35
  <ref name="ReqtObligationType"/>
36
36
  </attribute>
37
37
  </optional>
38
- <attribute name="id">
39
- <data type="ID"/>
40
- </attribute>
38
+ <ref name="RequiredId">
39
+ <a:documentation>Identification of provisions routed through the shared ID patterns,
40
+ like every other identified block: content GUID in `id`, with the
41
+ isodoc context adding the user-supplied `anchor` (e.g. Modspec
42
+ identifiers) and `source` (metanorma-model-iso#149)</a:documentation>
43
+ </ref>
41
44
  <ref name="NumberingAttributes"/>
42
45
  <ref name="BlockAttributesCore">
43
46
  <a:documentation>requirement carries its own semantic `class` (provision class, below), so
@@ -126,6 +129,15 @@ interruption by other sub-containers</a:documentation>
126
129
  <a:documentation>Provisions nested within this provision, which cannot be referenced autonomously and have
127
130
  subclasses specific to the parent provision. Not expressed with provision metadata</a:documentation>
128
131
  </ref>
132
+ <ref name="requirement">
133
+ <a:documentation>Provisions nested within this provision, which are self-standing and do not have
134
+ subclasses specific to the parent provision. Interleaved with the other
135
+ sub-containers: a requirements class alternates descriptions with its member
136
+ provisions, and descriptions resume after interruption
137
+ (metanorma-model-iso#160)</a:documentation>
138
+ </ref>
139
+ <ref name="recommendation"/>
140
+ <ref name="permission"/>
129
141
  </choice>
130
142
  </zeroOrMore>
131
143
  <optional>
@@ -133,15 +145,17 @@ subclasses specific to the parent provision. Not expressed with provision metada
133
145
  <a:documentation>A list of references for the requirement, following the Relaton model</a:documentation>
134
146
  </ref>
135
147
  </optional>
136
- <zeroOrMore>
137
- <choice>
138
- <a:documentation>Provisions nested within this provision, which are self-standing and do not have
139
- subclasses specific to the parent provision</a:documentation>
140
- <ref name="requirement"/>
141
- <ref name="recommendation"/>
142
- <ref name="permission"/>
143
- </choice>
144
- </zeroOrMore>
148
+ </define>
149
+ <define name="ExampleBodyContent" combine="choice">
150
+ <a:documentation>Provisions presented illustratively inside examples. This shape is
151
+ expected only in documents defining schemas and standards (e.g. the
152
+ Modspec specification exhibiting requirement boxes), not in
153
+ standards proper (metanorma-model-iso#160)</a:documentation>
154
+ <choice>
155
+ <ref name="requirement"/>
156
+ <ref name="recommendation"/>
157
+ <ref name="permission"/>
158
+ </choice>
145
159
  </define>
146
160
  <define name="reqtitle">
147
161
  <element name="title">
@@ -214,6 +228,12 @@ subclasses specific to the parent provision</a:documentation>
214
228
  mixture of the two.
215
229
  A machine-readable component can be included as source code with
216
230
  nomination of the language</a:documentation>
231
+ <ref name="OptionalId">
232
+ <a:documentation>Identification of subparts routed through the shared ID patterns
233
+ (metanorma-model-iso#149). Optional, not required: only some generator
234
+ pipelines (Modspec) stamp subparts with content GUIDs; others emit
235
+ description/specification/component without ids</a:documentation>
236
+ </ref>
217
237
  <optional>
218
238
  <attribute name="type">
219
239
  <a:documentation>Type of sub-container.
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module Plateau
3
- VERSION = "1.2.15".freeze
3
+ VERSION = "1.3.0".freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-plateau
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.15
4
+ version: 1.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
@@ -322,7 +322,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
322
322
  - !ruby/object:Gem::Version
323
323
  version: '0'
324
324
  requirements: []
325
- rubygems_version: 4.0.10
325
+ rubygems_version: 4.0.18
326
326
  specification_version: 4
327
327
  summary: Metanorma for MLIT Project PLATEAU (private)
328
328
  test_files: []