metanorma-ribose 2.5.5 → 2.5.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/isodoc/ribose/ribose.standard.xsl +194 -23
- data/lib/metanorma/ribose/biblio.rng +13 -1
- data/lib/metanorma/ribose/isodoc.rng +6 -6
- data/lib/metanorma/ribose/version.rb +1 -1
- data/metanorma-ribose.gemspec +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '05086b1e6dc3621f076c54173f85ceb4c6c48100bbf2b90526d96bfac99a6e75'
|
4
|
+
data.tar.gz: 214bf84f77dcc4d3138e6f608cc345f6c29471d675fa34e52c5378514194a3a1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a33ab5a0f6242bc8d523b90d7cf5a10dd5cfa71d514fface30926a98d1dc8992af9f053f0d225e9d94235ce1278a4c2d3c21702a1485e45a7b64ad46725bb00f
|
7
|
+
data.tar.gz: e8d5d0b52010f7fd0fde5fb21bf68494be774e9cb7d9fcd86301441c19b5667e9d73385fef16b9e40d1d8c46552c49d857978fff33292b3edef4bc1d4873a719
|
@@ -1098,6 +1098,7 @@
|
|
1098
1098
|
<fo:block-container margin-left="0mm">
|
1099
1099
|
<fo:block>
|
1100
1100
|
<xsl:call-template name="setId"/>
|
1101
|
+
<xsl:call-template name="addReviewHelper"/>
|
1101
1102
|
<xsl:apply-templates/>
|
1102
1103
|
</fo:block>
|
1103
1104
|
</fo:block-container>
|
@@ -4900,6 +4901,11 @@
|
|
4900
4901
|
|
4901
4902
|
<xsl:value-of select="@reference"/>
|
4902
4903
|
|
4904
|
+
<!-- commented https://github.com/metanorma/isodoc/issues/614 -->
|
4905
|
+
<!-- <xsl:if test="$namespace = 'itu'">
|
4906
|
+
<xsl:text>)</xsl:text>
|
4907
|
+
</xsl:if> -->
|
4908
|
+
|
4903
4909
|
</fo:inline>
|
4904
4910
|
<fo:inline xsl:use-attribute-sets="table-fn-body-style">
|
4905
4911
|
<xsl:copy-of select="./node()"/>
|
@@ -4909,7 +4915,7 @@
|
|
4909
4915
|
|
4910
4916
|
</xsl:if>
|
4911
4917
|
</xsl:for-each>
|
4912
|
-
</xsl:template>
|
4918
|
+
</xsl:template> <!-- table_fn_display -->
|
4913
4919
|
|
4914
4920
|
<xsl:template name="create_fn">
|
4915
4921
|
<fn reference="{@reference}" id="{@reference}_{ancestor::*[@id][1]/@id}">
|
@@ -4937,8 +4943,10 @@
|
|
4937
4943
|
<!-- EMD table's footnotes rendering -->
|
4938
4944
|
<!-- ============================ -->
|
4939
4945
|
|
4946
|
+
<!-- ============================ -->
|
4940
4947
|
<!-- figure's footnotes rendering -->
|
4941
|
-
|
4948
|
+
<!-- ============================ -->
|
4949
|
+
<xsl:template name="fn_display_figure"> <!-- figure_fn_display -->
|
4942
4950
|
|
4943
4951
|
<!-- current figure id -->
|
4944
4952
|
<xsl:variable name="figure_id_">
|
@@ -5051,9 +5059,28 @@
|
|
5051
5059
|
|
5052
5060
|
</fo:block>
|
5053
5061
|
</xsl:if>
|
5054
|
-
|
5055
5062
|
</xsl:template> <!-- fn_display_figure -->
|
5056
5063
|
|
5064
|
+
<!-- added for https://github.com/metanorma/isodoc/issues/607 -->
|
5065
|
+
<!-- figure's footnote label -->
|
5066
|
+
<xsl:template match="*[local-name() = 'figure']/*[local-name() = 'dl'][@key = 'true']/*[local-name() = 'dt']/ *[local-name() = 'p'][count(node()[normalize-space() != '']) = 1]/*[local-name() = 'sup']" priority="3">
|
5067
|
+
<xsl:variable name="key_iso">
|
5068
|
+
|
5069
|
+
</xsl:variable>
|
5070
|
+
<xsl:if test="normalize-space($key_iso) = 'true'">
|
5071
|
+
<xsl:attribute name="font-size">10pt</xsl:attribute>
|
5072
|
+
|
5073
|
+
</xsl:if>
|
5074
|
+
<fo:inline xsl:use-attribute-sets="figure-fn-number-style"> <!-- id="{@id}" -->
|
5075
|
+
<!-- <xsl:value-of select="@reference"/> -->
|
5076
|
+
<xsl:apply-templates/>
|
5077
|
+
</fo:inline>
|
5078
|
+
</xsl:template>
|
5079
|
+
|
5080
|
+
<!-- ============================ -->
|
5081
|
+
<!-- END: figure's footnotes rendering -->
|
5082
|
+
<!-- ============================ -->
|
5083
|
+
|
5057
5084
|
<!-- fn reference in the text rendering (for instance, 'some text 1) some text' ) -->
|
5058
5085
|
<xsl:template match="*[local-name()='fn']">
|
5059
5086
|
<fo:inline xsl:use-attribute-sets="fn-reference-style">
|
@@ -5069,6 +5096,10 @@
|
|
5069
5096
|
|
5070
5097
|
<xsl:value-of select="@reference"/>
|
5071
5098
|
|
5099
|
+
<!-- commented, https://github.com/metanorma/isodoc/issues/614 -->
|
5100
|
+
<!-- <xsl:if test="$namespace = 'jis'">
|
5101
|
+
<fo:inline font-weight="normal">)</fo:inline>
|
5102
|
+
</xsl:if> -->
|
5072
5103
|
</fo:basic-link>
|
5073
5104
|
</fo:inline>
|
5074
5105
|
</xsl:template>
|
@@ -5195,17 +5226,22 @@
|
|
5195
5226
|
</fo:block>
|
5196
5227
|
</xsl:when> <!-- END: a few components -->
|
5197
5228
|
<xsl:when test="$parent = 'figure' and (not(../@class) or ../@class !='pseudocode')"> <!-- definition list in a figure -->
|
5198
|
-
|
5229
|
+
<!-- Presentation XML contains 'Key' caption, https://github.com/metanorma/isodoc/issues/607 -->
|
5230
|
+
<xsl:if test="not(preceding-sibling::*[1][local-name() = 'p' and @keep-with-next])"> <!-- for old Presentation XML -->
|
5199
5231
|
|
5200
|
-
|
5232
|
+
<fo:block font-weight="bold" text-align="left" margin-bottom="12pt" keep-with-next="always">
|
5201
5233
|
|
5202
|
-
|
5203
|
-
|
5204
|
-
|
5205
|
-
|
5206
|
-
|
5207
|
-
|
5208
|
-
|
5234
|
+
<xsl:call-template name="refine_figure_key_style"/>
|
5235
|
+
|
5236
|
+
<xsl:variable name="title-key">
|
5237
|
+
<xsl:call-template name="getLocalizedString">
|
5238
|
+
<xsl:with-param name="key">key</xsl:with-param>
|
5239
|
+
</xsl:call-template>
|
5240
|
+
</xsl:variable>
|
5241
|
+
<xsl:value-of select="$title-key"/>
|
5242
|
+
</fo:block>
|
5243
|
+
|
5244
|
+
</xsl:if>
|
5209
5245
|
</xsl:when> <!-- END: definition list in a figure -->
|
5210
5246
|
</xsl:choose>
|
5211
5247
|
|
@@ -5391,6 +5427,14 @@
|
|
5391
5427
|
|
5392
5428
|
</xsl:template> <!-- END: dl -->
|
5393
5429
|
|
5430
|
+
<!-- caption for figure key and another caption, https://github.com/metanorma/isodoc/issues/607 -->
|
5431
|
+
<xsl:template match="*[local-name() = 'figure']/*[local-name() = 'p'][@keep-with-next = 'true' and *[local-name() = 'strong']]" priority="3">
|
5432
|
+
<fo:block text-align="left" margin-bottom="12pt" keep-with-next="always">
|
5433
|
+
<xsl:call-template name="refine_figure_key_style"/>
|
5434
|
+
<xsl:apply-templates/>
|
5435
|
+
</fo:block>
|
5436
|
+
</xsl:template>
|
5437
|
+
|
5394
5438
|
<xsl:template name="refine_dl_formula_where_style">
|
5395
5439
|
|
5396
5440
|
</xsl:template> <!-- refine_dl_formula_where_style -->
|
@@ -7434,6 +7478,39 @@
|
|
7434
7478
|
</xsl:copy>
|
7435
7479
|
</xsl:template>
|
7436
7480
|
|
7481
|
+
<xsl:template match="@*|node()" mode="mathml_linebreak">
|
7482
|
+
<xsl:copy>
|
7483
|
+
<xsl:apply-templates select="@*|node()" mode="mathml_linebreak"/>
|
7484
|
+
</xsl:copy>
|
7485
|
+
</xsl:template>
|
7486
|
+
|
7487
|
+
<!-- split math into two math -->
|
7488
|
+
<xsl:template match="mathml:mo[@linebreak] | mathml:mspace[@linebreak]" mode="mathml_linebreak">
|
7489
|
+
<xsl:variable name="math_elements_tree_">
|
7490
|
+
<xsl:for-each select="ancestor::*[ancestor-or-self::mathml:math]">
|
7491
|
+
<element pos="{position()}">
|
7492
|
+
<xsl:copy-of select="@*[local-name() != 'id']"/>
|
7493
|
+
<xsl:value-of select="name()"/>
|
7494
|
+
</element>
|
7495
|
+
</xsl:for-each>
|
7496
|
+
</xsl:variable>
|
7497
|
+
|
7498
|
+
<xsl:variable name="math_elements_tree" select="xalan:nodeset($math_elements_tree_)"/>
|
7499
|
+
|
7500
|
+
<xsl:call-template name="insertClosingElements">
|
7501
|
+
<xsl:with-param name="tree" select="$math_elements_tree"/>
|
7502
|
+
</xsl:call-template>
|
7503
|
+
|
7504
|
+
<xsl:element name="br" namespace="{$namespace_full}"/>
|
7505
|
+
|
7506
|
+
<xsl:call-template name="insertOpeningElements">
|
7507
|
+
<xsl:with-param name="tree" select="$math_elements_tree"/>
|
7508
|
+
<xsl:with-param name="xmlns">http://www.w3.org/1998/Math/MathML</xsl:with-param>
|
7509
|
+
<xsl:with-param name="add_continue">false</xsl:with-param>
|
7510
|
+
</xsl:call-template>
|
7511
|
+
|
7512
|
+
</xsl:template>
|
7513
|
+
|
7437
7514
|
<!-- Examples:
|
7438
7515
|
<stem type="AsciiMath">x = 1</stem>
|
7439
7516
|
<stem type="AsciiMath"><asciimath>x = 1</asciimath></stem>
|
@@ -7685,9 +7762,11 @@
|
|
7685
7762
|
</xsl:template>
|
7686
7763
|
|
7687
7764
|
<xsl:template match="*[local-name() = 'formula']/*[local-name() = 'name']"> <!-- show in 'stem' template -->
|
7765
|
+
<!-- https://github.com/metanorma/isodoc/issues/607
|
7688
7766
|
<xsl:if test="normalize-space() != ''">
|
7689
|
-
<xsl:text>(</xsl:text><xsl:apply-templates/><xsl:text>)</xsl:text>
|
7690
|
-
</xsl:if>
|
7767
|
+
<xsl:text>(</xsl:text><xsl:apply-templates /><xsl:text>)</xsl:text>
|
7768
|
+
</xsl:if> -->
|
7769
|
+
<xsl:apply-templates/>
|
7691
7770
|
</xsl:template>
|
7692
7771
|
|
7693
7772
|
<!-- stem inside formula with name (with formula's number) -->
|
@@ -7843,8 +7922,17 @@
|
|
7843
7922
|
</xsl:when>
|
7844
7923
|
<xsl:otherwise>
|
7845
7924
|
|
7925
|
+
<!-- https://github.com/metanorma/isodoc/issues/607 -->
|
7926
|
+
<!-- <xsl:if test="$namespace = 'ieee'">
|
7927
|
+
<xsl:text>—</xsl:text> em dash —
|
7928
|
+
</xsl:if> -->
|
7929
|
+
<!-- <xsl:if test="$namespace = 'iho' or $namespace = 'gb' or $namespace = 'm3d' or $namespace = 'unece-rec' or $namespace = 'unece' or $namespace = 'rsd'">
|
7846
7930
|
<xsl:text>:</xsl:text>
|
7931
|
+
</xsl:if> -->
|
7847
7932
|
|
7933
|
+
<!-- <xsl:if test="$namespace = 'itu' or $namespace = 'nist-cswp' or $namespace = 'nist-sp'">
|
7934
|
+
<xsl:text> – </xsl:text> en dash –
|
7935
|
+
</xsl:if> -->
|
7848
7936
|
</xsl:otherwise>
|
7849
7937
|
</xsl:choose>
|
7850
7938
|
</xsl:variable>
|
@@ -7863,8 +7951,16 @@
|
|
7863
7951
|
</xsl:when>
|
7864
7952
|
<xsl:otherwise>
|
7865
7953
|
|
7954
|
+
<!-- https://github.com/metanorma/isodoc/issues/607 -->
|
7955
|
+
<!-- <xsl:if test="$namespace = 'ieee'">
|
7956
|
+
<xsl:text>—</xsl:text> em dash —
|
7957
|
+
</xsl:if> -->
|
7958
|
+
<!-- <xsl:if test="$namespace = 'gb' or $namespace = 'iso' or $namespace = 'iec' or $namespace = 'ogc' or $namespace = 'ogc-white-paper' or $namespace = 'rsd' or $namespace = 'jcgm'">
|
7866
7959
|
<xsl:text>:</xsl:text>
|
7867
|
-
|
7960
|
+
</xsl:if> -->
|
7961
|
+
<!-- <xsl:if test="$namespace = 'itu' or $namespace = 'nist-cswp' or $namespace = 'nist-sp' or $namespace = 'unece-rec' or $namespace = 'unece'">
|
7962
|
+
<xsl:text> – </xsl:text> en dash –
|
7963
|
+
</xsl:if> -->
|
7868
7964
|
</xsl:otherwise>
|
7869
7965
|
</xsl:choose>
|
7870
7966
|
</xsl:variable>
|
@@ -10036,7 +10132,7 @@
|
|
10036
10132
|
<xsl:if test="normalize-space() != ''">
|
10037
10133
|
<fo:inline xsl:use-attribute-sets="termexample-name-style">
|
10038
10134
|
<xsl:call-template name="refine_termexample-name-style"/>
|
10039
|
-
<xsl:apply-templates/>:
|
10135
|
+
<xsl:apply-templates/>: <!-- commented $namespace = 'ieee', https://github.com/metanorma/isodoc/issues/614-->
|
10040
10136
|
</fo:inline>
|
10041
10137
|
</xsl:if>
|
10042
10138
|
</xsl:template>
|
@@ -10198,7 +10294,7 @@
|
|
10198
10294
|
<xsl:otherwise>
|
10199
10295
|
<fo:inline xsl:use-attribute-sets="example-name-style">
|
10200
10296
|
<xsl:call-template name="refine_example-name-style"/>
|
10201
|
-
<xsl:apply-templates/>:
|
10297
|
+
<xsl:apply-templates/>: <!-- $namespace = 'ieee', see https://github.com/metanorma/isodoc/issues/614 -->
|
10202
10298
|
</fo:inline>
|
10203
10299
|
</xsl:otherwise>
|
10204
10300
|
</xsl:choose>
|
@@ -10385,15 +10481,17 @@
|
|
10385
10481
|
|
10386
10482
|
<fo:block-container margin-left="0mm" margin-right="0mm" role="SKIP">
|
10387
10483
|
<fo:block role="BlockQuote">
|
10388
|
-
<xsl:apply-templates select="./node()[not(local-name() = 'author') and
|
10484
|
+
<xsl:apply-templates select="./node()[not(local-name() = 'author') and not(local-name() = 'source') and not(local-name() = 'attribution')]"/> <!-- process all nested nodes, except author and source -->
|
10389
10485
|
</fo:block>
|
10390
10486
|
</fo:block-container>
|
10391
10487
|
</fo:block-container>
|
10392
|
-
<xsl:if test="*[local-name() = 'author'] or *[local-name() = 'source']">
|
10488
|
+
<xsl:if test="*[local-name() = 'author'] or *[local-name() = 'source'] or *[local-name() = 'attribution']">
|
10393
10489
|
<fo:block xsl:use-attribute-sets="quote-source-style">
|
10394
10490
|
<!-- — ISO, ISO 7301:2011, Clause 1 -->
|
10395
10491
|
<xsl:apply-templates select="*[local-name() = 'author']"/>
|
10396
10492
|
<xsl:apply-templates select="*[local-name() = 'source']"/>
|
10493
|
+
<!-- added for https://github.com/metanorma/isodoc/issues/607 -->
|
10494
|
+
<xsl:apply-templates select="*[local-name() = 'attribution']/*[local-name() = 'p']/node()"/>
|
10397
10495
|
</fo:block>
|
10398
10496
|
</xsl:if>
|
10399
10497
|
|
@@ -10415,9 +10513,13 @@
|
|
10415
10513
|
</xsl:template>
|
10416
10514
|
|
10417
10515
|
<xsl:template match="*[local-name() = 'author']">
|
10418
|
-
<xsl:
|
10516
|
+
<xsl:if test="local-name(..) = 'quote'"> <!-- for old Presentation XML, https://github.com/metanorma/isodoc/issues/607 -->
|
10517
|
+
<xsl:text>— </xsl:text>
|
10518
|
+
</xsl:if>
|
10419
10519
|
<xsl:apply-templates/>
|
10420
10520
|
</xsl:template>
|
10521
|
+
|
10522
|
+
<xsl:template match="*[local-name() = 'quote']//*[local-name() = 'referenceFrom']"/>
|
10421
10523
|
<!-- ====== -->
|
10422
10524
|
<!-- ====== -->
|
10423
10525
|
|
@@ -10593,8 +10695,12 @@
|
|
10593
10695
|
</xsl:template>
|
10594
10696
|
|
10595
10697
|
<xsl:template match="*[local-name() = 'domain']">
|
10698
|
+
<!-- https://github.com/metanorma/isodoc/issues/607
|
10596
10699
|
<fo:inline xsl:use-attribute-sets="domain-style"><<xsl:apply-templates/>></fo:inline>
|
10597
|
-
<xsl:text> </xsl:text>
|
10700
|
+
<xsl:text> </xsl:text> -->
|
10701
|
+
<xsl:if test="not(@hidden = 'true')">
|
10702
|
+
<xsl:apply-templates/>
|
10703
|
+
</xsl:if>
|
10598
10704
|
</xsl:template>
|
10599
10705
|
|
10600
10706
|
<xsl:template match="*[local-name() = 'admitted']">
|
@@ -10642,6 +10748,29 @@
|
|
10642
10748
|
<!-- END definition -->
|
10643
10749
|
<!-- ========== -->
|
10644
10750
|
|
10751
|
+
<xsl:variable name="reviews_">
|
10752
|
+
<xsl:for-each select="//*[local-name() = 'review'][@from]">
|
10753
|
+
<xsl:copy>
|
10754
|
+
<xsl:copy-of select="@from"/>
|
10755
|
+
<xsl:copy-of select="@id"/>
|
10756
|
+
</xsl:copy>
|
10757
|
+
</xsl:for-each>
|
10758
|
+
</xsl:variable>
|
10759
|
+
<xsl:variable name="reviews" select="xalan:nodeset($reviews_)"/>
|
10760
|
+
|
10761
|
+
<xsl:template name="addReviewHelper">
|
10762
|
+
<!-- if there is review with from="...", then add small helper block for Annot tag adding, see 'review' template -->
|
10763
|
+
<xsl:variable name="curr_id" select="@id"/>
|
10764
|
+
<xsl:variable name="review_id" select="normalize-space($reviews//*[local-name() = 'review'][@from = $curr_id]/@id)"/>
|
10765
|
+
<xsl:if test="$review_id != ''"> <!-- i.e. if review found -->
|
10766
|
+
<fo:block keep-with-next="always" line-height="0.1" id="{$review_id}" font-size="1pt" role="SKIP"><xsl:value-of select="$hair_space"/><fo:basic-link internal-destination="{$review_id}" fox:alt-text="Annot___{$review_id}" role="Annot"><xsl:value-of select="$hair_space"/></fo:basic-link></fo:block>
|
10767
|
+
</xsl:if>
|
10768
|
+
<!-- <fo:block>
|
10769
|
+
<curr_id><xsl:value-of select="$curr_id"/></curr_id>
|
10770
|
+
<xsl:copy-of select="$reviews"/>
|
10771
|
+
</fo:block> -->
|
10772
|
+
</xsl:template>
|
10773
|
+
|
10645
10774
|
<!-- main sections -->
|
10646
10775
|
<xsl:template match="/*/*[local-name() = 'sections']/*" name="sections_node" priority="2">
|
10647
10776
|
|
@@ -10650,6 +10779,8 @@
|
|
10650
10779
|
|
10651
10780
|
<xsl:call-template name="sections_element_style"/>
|
10652
10781
|
|
10782
|
+
<xsl:call-template name="addReviewHelper"/>
|
10783
|
+
|
10653
10784
|
<xsl:apply-templates/>
|
10654
10785
|
</fo:block>
|
10655
10786
|
|
@@ -10690,6 +10821,7 @@
|
|
10690
10821
|
|
10691
10822
|
<fo:block>
|
10692
10823
|
<xsl:call-template name="setId"/>
|
10824
|
+
<xsl:call-template name="addReviewHelper"/>
|
10693
10825
|
<xsl:apply-templates/>
|
10694
10826
|
</fo:block>
|
10695
10827
|
</xsl:template>
|
@@ -10726,6 +10858,8 @@
|
|
10726
10858
|
|
10727
10859
|
<xsl:call-template name="refine_clause_style"/>
|
10728
10860
|
|
10861
|
+
<xsl:call-template name="addReviewHelper"/>
|
10862
|
+
|
10729
10863
|
<xsl:apply-templates/>
|
10730
10864
|
</fo:block>
|
10731
10865
|
</xsl:template>
|
@@ -10778,6 +10912,23 @@
|
|
10778
10912
|
|
10779
10913
|
<xsl:variable name="id_from" select="normalize-space(current()/@from)"/>
|
10780
10914
|
|
10915
|
+
<xsl:if test="1 = 1">
|
10916
|
+
<xsl:choose>
|
10917
|
+
<!-- if there isn't the attribute '@from', then -->
|
10918
|
+
<xsl:when test="$id_from = ''">
|
10919
|
+
<fo:block id="{@id}" font-size="1pt" role="SKIP"><xsl:value-of select="$hair_space"/><fo:basic-link internal-destination="{@id}" fox:alt-text="Annot___{@id}" role="Annot"><xsl:value-of select="$hair_space"/></fo:basic-link></fo:block>
|
10920
|
+
</xsl:when>
|
10921
|
+
<!-- if there isn't element with id 'from', then create 'bookmark' here -->
|
10922
|
+
<xsl:when test="ancestor::*[contains(local-name(), '-standard')] and not(ancestor::*[contains(local-name(), '-standard')]//*[@id = $id_from])">
|
10923
|
+
<fo:block id="{@from}" font-size="1pt" role="SKIP"><xsl:value-of select="$hair_space"/><fo:basic-link internal-destination="{@from}" fox:alt-text="Annot___{@id}" role="Annot"><xsl:value-of select="$hair_space"/></fo:basic-link></fo:block>
|
10924
|
+
</xsl:when>
|
10925
|
+
<xsl:when test="not(/*[@id = $id_from]) and not(/*//*[@id = $id_from]) and not(preceding-sibling::*[@id = $id_from])">
|
10926
|
+
<fo:block id="{@from}" font-size="1pt" role="SKIP"><xsl:value-of select="$hair_space"/><fo:basic-link internal-destination="{@from}" fox:alt-text="Annot___{@id}" role="Annot"><xsl:value-of select="$hair_space"/></fo:basic-link></fo:block>
|
10927
|
+
</xsl:when>
|
10928
|
+
</xsl:choose>
|
10929
|
+
</xsl:if>
|
10930
|
+
|
10931
|
+
<xsl:if test="1 = 2">
|
10781
10932
|
<xsl:choose>
|
10782
10933
|
<!-- if there isn't the attribute '@from', then -->
|
10783
10934
|
<xsl:when test="$id_from = ''">
|
@@ -10791,6 +10942,7 @@
|
|
10791
10942
|
<fo:block id="{@from}" font-size="1pt"><xsl:value-of select="$hair_space"/></fo:block>
|
10792
10943
|
</xsl:when>
|
10793
10944
|
</xsl:choose>
|
10945
|
+
</xsl:if>
|
10794
10946
|
|
10795
10947
|
</xsl:template>
|
10796
10948
|
|
@@ -12148,7 +12300,7 @@
|
|
12148
12300
|
<!-- remove preprocess-xslt -->
|
12149
12301
|
<xsl:template match="*[local-name() = 'preprocess-xslt']" mode="update_xml_step1"/>
|
12150
12302
|
|
12151
|
-
<xsl:template match="*[local-name() = 'stem'] | *[local-name() = 'image'] | *[local-name() = 'sourcecode'] | *[local-name() = 'bibdata'] | *[local-name() = 'localized-strings']" mode="update_xml_step1">
|
12303
|
+
<xsl:template match="*[local-name() = 'stem'][not(.//*[local-name() = 'passthrough']) and not(.//*[@linebreak])] | *[local-name() = 'image'][not(.//*[local-name() = 'passthrough'])] | *[local-name() = 'sourcecode'][not(.//*[local-name() = 'passthrough'])] | *[local-name() = 'bibdata'][not(.//*[local-name() = 'passthrough'])] | *[local-name() = 'localized-strings']" mode="update_xml_step1">
|
12152
12304
|
<xsl:copy-of select="."/>
|
12153
12305
|
</xsl:template>
|
12154
12306
|
|
@@ -12214,6 +12366,22 @@
|
|
12214
12366
|
</xsl:choose>
|
12215
12367
|
</xsl:template>
|
12216
12368
|
|
12369
|
+
<xsl:variable name="regex_passthrough">.*\bpdf\b.*</xsl:variable>
|
12370
|
+
<xsl:template match="*[local-name() = 'passthrough']" mode="update_xml_step1">
|
12371
|
+
<!-- <xsl:if test="contains(@formats, ' pdf ')"> -->
|
12372
|
+
<xsl:if test="normalize-space(java:matches(java:java.lang.String.new(@formats), $regex_passthrough)) = 'true'">
|
12373
|
+
<xsl:apply-templates mode="update_xml_step1"/>
|
12374
|
+
</xsl:if>
|
12375
|
+
</xsl:template>
|
12376
|
+
|
12377
|
+
<!-- split math by element with @linebreak into maths -->
|
12378
|
+
<xsl:template match="mathml:math[.//mathml:mo[@linebreak] or .//mathml:mspace[@linebreak]]" mode="update_xml_step1">
|
12379
|
+
<xsl:variable name="maths">
|
12380
|
+
<xsl:apply-templates select="." mode="mathml_linebreak"/>
|
12381
|
+
</xsl:variable>
|
12382
|
+
<xsl:copy-of select="$maths"/>
|
12383
|
+
</xsl:template>
|
12384
|
+
|
12217
12385
|
<!-- =========================================================================== -->
|
12218
12386
|
<!-- END STEP1: Re-order elements in 'preface', 'sections' based on @displayorder -->
|
12219
12387
|
<!-- =========================================================================== -->
|
@@ -12317,6 +12485,8 @@
|
|
12317
12485
|
|
12318
12486
|
<xsl:template name="insertOpeningElements">
|
12319
12487
|
<xsl:param name="tree"/>
|
12488
|
+
<xsl:param name="xmlns"/>
|
12489
|
+
<xsl:param name="add_continue">true</xsl:param>
|
12320
12490
|
<xsl:for-each select="$tree//element">
|
12321
12491
|
<xsl:text disable-output-escaping="yes"><</xsl:text>
|
12322
12492
|
<xsl:value-of select="."/>
|
@@ -12327,7 +12497,8 @@
|
|
12327
12497
|
<xsl:value-of select="."/>
|
12328
12498
|
<xsl:text>"</xsl:text>
|
12329
12499
|
</xsl:for-each>
|
12330
|
-
<xsl:if test="position() = 1"> continue="true"</xsl:if>
|
12500
|
+
<xsl:if test="position() = 1 and $add_continue = 'true'"> continue="true"</xsl:if>
|
12501
|
+
<xsl:if test="position() = 1 and $xmlns != ''"> xmlns="<xsl:value-of select="$xmlns"/>"</xsl:if>
|
12331
12502
|
<xsl:text disable-output-escaping="yes">></xsl:text>
|
12332
12503
|
<xsl:if test="$debug = 'true'">
|
12333
12504
|
<xsl:message><<xsl:value-of select="."/>></xsl:message>
|
@@ -1783,9 +1783,21 @@ that the `number` given for the series applies to the second iteration of number
|
|
1783
1783
|
May be used to differentiate rendering of notes in bibliographies</a:documentation>
|
1784
1784
|
</attribute>
|
1785
1785
|
</optional>
|
1786
|
-
<ref name="
|
1786
|
+
<ref name="LocalizedStringAttributes">
|
1787
1787
|
<a:documentation>The content of the note</a:documentation>
|
1788
1788
|
</ref>
|
1789
|
+
<choice>
|
1790
|
+
<oneOrMore>
|
1791
|
+
<ref name="BasicBlockNoId">
|
1792
|
+
<a:documentation>Multiple blocks of content</a:documentation>
|
1793
|
+
</ref>
|
1794
|
+
</oneOrMore>
|
1795
|
+
<oneOrMore>
|
1796
|
+
<ref name="TextElement">
|
1797
|
+
<a:documentation>Single block of content</a:documentation>
|
1798
|
+
</ref>
|
1799
|
+
</oneOrMore>
|
1800
|
+
</choice>
|
1789
1801
|
</element>
|
1790
1802
|
</define>
|
1791
1803
|
<define name="bibabstract">
|
@@ -17,7 +17,7 @@
|
|
17
17
|
these elements; we just want one namespace for any child grammars
|
18
18
|
of this.
|
19
19
|
-->
|
20
|
-
<!-- VERSION v1.
|
20
|
+
<!-- VERSION v1.4.0 -->
|
21
21
|
<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">
|
22
22
|
<include href="reqt.rng"/>
|
23
23
|
<include href="basicdoc.rng">
|
@@ -326,7 +326,7 @@ normative or informative references, some split references into sections organiz
|
|
326
326
|
<a:documentation>Content of note</a:documentation>
|
327
327
|
<oneOrMore>
|
328
328
|
<choice>
|
329
|
-
<ref name="paragraph"/>
|
329
|
+
<ref name="paragraph-with-footnote"/>
|
330
330
|
<ref name="ul"/>
|
331
331
|
<ref name="ol"/>
|
332
332
|
<ref name="dl"/>
|
@@ -412,7 +412,7 @@ normative or informative references, some split references into sections organiz
|
|
412
412
|
<element name="note">
|
413
413
|
<ref name="OptionalId"/>
|
414
414
|
<oneOrMore>
|
415
|
-
<ref name="paragraph"/>
|
415
|
+
<ref name="paragraph-with-footnote"/>
|
416
416
|
</oneOrMore>
|
417
417
|
</element>
|
418
418
|
</define>
|
@@ -1977,7 +1977,7 @@ used in document amendments</a:documentation>
|
|
1977
1977
|
<oneOrMore>
|
1978
1978
|
<choice>
|
1979
1979
|
<a:documentation>Content of the verbal representation of the term</a:documentation>
|
1980
|
-
<ref name="paragraph"/>
|
1980
|
+
<ref name="paragraph-with-footnote"/>
|
1981
1981
|
<ref name="dl"/>
|
1982
1982
|
<ref name="ol"/>
|
1983
1983
|
<ref name="ul"/>
|
@@ -2015,7 +2015,7 @@ used in document amendments</a:documentation>
|
|
2015
2015
|
<oneOrMore>
|
2016
2016
|
<choice>
|
2017
2017
|
<a:documentation>Content of the term note</a:documentation>
|
2018
|
-
<ref name="paragraph"/>
|
2018
|
+
<ref name="paragraph-with-footnote"/>
|
2019
2019
|
<ref name="ul"/>
|
2020
2020
|
<ref name="ol"/>
|
2021
2021
|
<ref name="dl"/>
|
@@ -2037,7 +2037,7 @@ used in document amendments</a:documentation>
|
|
2037
2037
|
<ref name="dl"/>
|
2038
2038
|
<ref name="quote"/>
|
2039
2039
|
<ref name="sourcecode"/>
|
2040
|
-
<ref name="paragraph"/>
|
2040
|
+
<ref name="paragraph-with-footnote"/>
|
2041
2041
|
<ref name="figure"/>
|
2042
2042
|
</choice>
|
2043
2043
|
</oneOrMore>
|
data/metanorma-ribose.gemspec
CHANGED
@@ -29,7 +29,7 @@ Gem::Specification.new do |spec|
|
|
29
29
|
spec.require_paths = ["lib"]
|
30
30
|
spec.required_ruby_version = Gem::Requirement.new(">= 3.1.0")
|
31
31
|
|
32
|
-
spec.add_dependency "metanorma-generic", "~> 2.7.
|
32
|
+
spec.add_dependency "metanorma-generic", "~> 2.7.2"
|
33
33
|
|
34
34
|
spec.add_development_dependency "debug"
|
35
35
|
spec.add_development_dependency "equivalent-xml", "~> 0.6"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-ribose
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.5.
|
4
|
+
version: 2.5.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-11-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: metanorma-generic
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 2.7.
|
19
|
+
version: 2.7.2
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 2.7.
|
26
|
+
version: 2.7.2
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: debug
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|