metanorma-jis 0.5.4 → 0.5.5
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 +4 -4
- data/lib/isodoc/jis/init.rb +2 -2
- data/lib/isodoc/jis/jis.international-standard.xsl +170 -25
- data/lib/metanorma/jis/isodoc.rng +16 -1
- data/lib/metanorma/jis/isostandard.rng +0 -5
- data/lib/metanorma/jis/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '028e16564c24076acd2266efc285afc31665c045d7c52d421d1cc86d6a6c2cf4'
|
4
|
+
data.tar.gz: bcaa409668820ce993abbf1521bd7d8758ef6c9d8d0bdcf756dcb4d5395dfc8f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d46e0162e974d7aaae36c63d1ce38e0bb849e46cbc18dffd14fe7acc4b85267a48976f5a3154ee7b326d0d3e9d9148582b094981b5dc6a6456698f549c2790d3
|
7
|
+
data.tar.gz: 0a05986075fa296bfa633e7903cad32f0ca58aab56362082c6ef5012a549f0537b4741d5b715e3f401874e4a0dee3efb69e6927ad66000b8c218ac71c943a3c3
|
data/lib/isodoc/jis/init.rb
CHANGED
@@ -29,9 +29,9 @@ module IsoDoc
|
|
29
29
|
end
|
30
30
|
|
31
31
|
def convert_i18n_init1(docxml)
|
32
|
-
|
32
|
+
docxml.at("//xmlns:bibdata") or return
|
33
33
|
lang = docxml.at("//xmlns:bibdata/xmlns:language") ||
|
34
|
-
|
34
|
+
(docxml << "<language/>")
|
35
35
|
%w(en ja).include?(lang&.text) or lang.content = "ja"
|
36
36
|
super
|
37
37
|
end
|
@@ -8006,8 +8006,14 @@
|
|
8006
8006
|
</xsl:choose>
|
8007
8007
|
</xsl:variable>
|
8008
8008
|
|
8009
|
+
<xsl:call-template name="setNamedDestination"/>
|
8010
|
+
|
8009
8011
|
<fo:block-container xsl:use-attribute-sets="table-container-style" role="SKIP">
|
8010
8012
|
|
8013
|
+
<xsl:for-each select="*[local-name() = 'name']">
|
8014
|
+
<xsl:call-template name="setIDforNamedDestination"/>
|
8015
|
+
</xsl:for-each>
|
8016
|
+
|
8011
8017
|
<xsl:call-template name="refine_table-container-style">
|
8012
8018
|
<xsl:with-param name="margin-side" select="$margin-side"/>
|
8013
8019
|
</xsl:call-template>
|
@@ -8212,6 +8218,7 @@
|
|
8212
8218
|
<!-- table/name-->
|
8213
8219
|
<xsl:template match="*[local-name()='table']/*[local-name() = 'name']">
|
8214
8220
|
<xsl:param name="continued"/>
|
8221
|
+
<xsl:param name="cols-count"/>
|
8215
8222
|
<xsl:if test="normalize-space() != ''">
|
8216
8223
|
|
8217
8224
|
<fo:block xsl:use-attribute-sets="table-name-style">
|
@@ -8233,9 +8240,30 @@
|
|
8233
8240
|
|
8234
8241
|
<!-- <xsl:if test="$namespace = 'bsi' or $namespace = 'iec' or $namespace = 'iso'"> -->
|
8235
8242
|
<xsl:if test="$continued = 'true'">
|
8236
|
-
|
8237
|
-
|
8238
|
-
|
8243
|
+
|
8244
|
+
<!-- to prevent the error 'THead element may contain only TR elements' -->
|
8245
|
+
|
8246
|
+
<xsl:choose>
|
8247
|
+
<xsl:when test="string(number($cols-count)) != 'NaN'">
|
8248
|
+
<fo:table width="100%" table-layout="fixed" role="SKIP">
|
8249
|
+
<fo:table-body role="SKIP">
|
8250
|
+
<fo:table-row>
|
8251
|
+
<fo:table-cell role="TH" number-columns-spanned="{$cols-count}">
|
8252
|
+
<fo:block text-align="right" role="SKIP">
|
8253
|
+
<xsl:apply-templates select="../*[local-name() = 'note'][@type = 'units']/node()"/>
|
8254
|
+
</fo:block>
|
8255
|
+
</fo:table-cell>
|
8256
|
+
</fo:table-row>
|
8257
|
+
</fo:table-body>
|
8258
|
+
</fo:table>
|
8259
|
+
</xsl:when>
|
8260
|
+
<xsl:otherwise>
|
8261
|
+
<fo:block text-align="right">
|
8262
|
+
<xsl:apply-templates select="../*[local-name() = 'note'][@type = 'units']/node()"/>
|
8263
|
+
</fo:block>
|
8264
|
+
</xsl:otherwise>
|
8265
|
+
</xsl:choose>
|
8266
|
+
|
8239
8267
|
</xsl:if>
|
8240
8268
|
<!-- </xsl:if> -->
|
8241
8269
|
|
@@ -8628,6 +8656,7 @@
|
|
8628
8656
|
|
8629
8657
|
<xsl:apply-templates select="ancestor::*[local-name()='table']/*[local-name()='name']">
|
8630
8658
|
<xsl:with-param name="continued">true</xsl:with-param>
|
8659
|
+
<xsl:with-param name="cols-count" select="$cols-count"/>
|
8631
8660
|
</xsl:apply-templates>
|
8632
8661
|
|
8633
8662
|
<xsl:if test="not(ancestor::*[local-name()='table']/*[local-name()='name'])"> <!-- to prevent empty fo:table-cell in case of missing table's name -->
|
@@ -9005,8 +9034,8 @@
|
|
9005
9034
|
<xsl:for-each select="xalan:nodeset($styles__)/item">
|
9006
9035
|
<xsl:variable name="key" select="normalize-space(substring-before(., ':'))"/>
|
9007
9036
|
<xsl:variable name="value" select="normalize-space(substring-after(translate(.,$quot,''), ':'))"/>
|
9008
|
-
<xsl:if test="$key = 'color' or
|
9009
|
-
<style name="{$key}"><xsl:value-of select="$value"/></style>
|
9037
|
+
<xsl:if test="$key = 'color' or $key = 'background-color' or $key = 'border' or $key = 'border-top' or $key = 'border-right' or $key = 'border-left' or $key = 'border-bottom' or $key = 'border-style' or $key = 'border-width' or $key = 'border-color' or $key = 'border-top-style' or $key = 'border-top-width' or $key = 'border-top-color' or $key = 'border-right-style' or $key = 'border-right-width' or $key = 'border-right-color' or $key = 'border-left-style' or $key = 'border-left-width' or $key = 'border-left-color' or $key = 'border-bottom-style' or $key = 'border-bottom-width' or $key = 'border-bottom-color'">
|
9038
|
+
<style name="{$key}"><xsl:value-of select="java:replaceAll(java:java.lang.String.new($value), 'currentColor', 'inherit')"/></style>
|
9010
9039
|
</xsl:if>
|
9011
9040
|
</xsl:for-each>
|
9012
9041
|
</xsl:variable>
|
@@ -9073,6 +9102,7 @@
|
|
9073
9102
|
<!-- table/note, table/example, table/tfoot//note, table/tfoot//example -->
|
9074
9103
|
<xsl:template match="*[local-name()='table']/*[local-name()='note' or local-name() = 'example'] | *[local-name()='table']/*[local-name()='tfoot']//*[local-name()='note' or local-name() = 'example']" priority="2">
|
9075
9104
|
|
9105
|
+
<xsl:call-template name="setNamedDestination"/>
|
9076
9106
|
<fo:list-block id="{@id}" xsl:use-attribute-sets="table-note-style" provisional-distance-between-starts="{9 + $text_indent}mm"> <!-- 12 -->
|
9077
9107
|
<fo:list-item>
|
9078
9108
|
<fo:list-item-label start-indent="{$text_indent}mm" end-indent="label-end()">
|
@@ -9700,7 +9730,7 @@
|
|
9700
9730
|
<xsl:variable name="target" select="@target"/>
|
9701
9731
|
<xsl:choose>
|
9702
9732
|
<!-- case for footnotes in Requirement tables (https://github.com/metanorma/metanorma-ogc/issues/791) -->
|
9703
|
-
<xsl:when test="not(ancestor::*[local-name() = 'table'][1]
|
9733
|
+
<xsl:when test="not(ancestor::*[local-name() = 'table'][1]//*[local-name() = 'fmt-footnote-container']/*[local-name() = 'fmt-fn-body'][@id = $target]) and $footnotes/*[local-name() = 'fmt-fn-body'][@id = $target]">
|
9704
9734
|
<xsl:call-template name="fn">
|
9705
9735
|
<xsl:with-param name="footnote_body_from_table">true</xsl:with-param>
|
9706
9736
|
</xsl:call-template>
|
@@ -9796,6 +9826,10 @@
|
|
9796
9826
|
<!-- <dl><xsl:copy-of select="."/></dl> -->
|
9797
9827
|
<fo:block-container xsl:use-attribute-sets="dl-block-style" role="SKIP">
|
9798
9828
|
|
9829
|
+
<xsl:if test="@key = 'true' and ancestor::*[local-name() = 'figure']">
|
9830
|
+
<xsl:attribute name="keep-together.within-column">always</xsl:attribute>
|
9831
|
+
</xsl:if>
|
9832
|
+
|
9799
9833
|
<xsl:call-template name="setBlockSpanAll"/>
|
9800
9834
|
|
9801
9835
|
<xsl:if test="not(ancestor::*[local-name() = 'quote'])">
|
@@ -10096,7 +10130,7 @@
|
|
10096
10130
|
|
10097
10131
|
<!-- caption for figure key and another caption, https://github.com/metanorma/isodoc/issues/607 -->
|
10098
10132
|
<xsl:template match="*[local-name() = 'figure']/*[local-name() = 'p'][@keep-with-next = 'true' and *[local-name() = 'strong']]" priority="3">
|
10099
|
-
<fo:block text-align="left" margin-bottom="12pt" keep-with-next="always">
|
10133
|
+
<fo:block text-align="left" margin-bottom="12pt" keep-with-next="always" keep-with-previous="always">
|
10100
10134
|
<xsl:call-template name="refine_figure_key_style"/>
|
10101
10135
|
<xsl:apply-templates/>
|
10102
10136
|
</fo:block>
|
@@ -10347,6 +10381,7 @@
|
|
10347
10381
|
|
10348
10382
|
<xsl:call-template name="refine_dt-cell-style"/>
|
10349
10383
|
|
10384
|
+
<xsl:call-template name="setNamedDestination"/>
|
10350
10385
|
<fo:block xsl:use-attribute-sets="dt-block-style" role="SKIP">
|
10351
10386
|
|
10352
10387
|
<xsl:choose>
|
@@ -10791,7 +10826,7 @@
|
|
10791
10826
|
<!-- ================= -->
|
10792
10827
|
|
10793
10828
|
<!-- highlight text -->
|
10794
|
-
<xsl:template match="*[local-name()='hi']">
|
10829
|
+
<xsl:template match="*[local-name()='hi'] | *[local-name() = 'span'][@class = 'fmt-hi']" priority="3">
|
10795
10830
|
<fo:inline background-color="yellow">
|
10796
10831
|
<xsl:apply-templates/>
|
10797
10832
|
</fo:inline>
|
@@ -12395,6 +12430,7 @@
|
|
12395
12430
|
<!-- Appendix processing -->
|
12396
12431
|
<!-- ======================== -->
|
12397
12432
|
<xsl:template match="*[local-name()='appendix']">
|
12433
|
+
<xsl:call-template name="setNamedDestination"/>
|
12398
12434
|
<fo:block id="{@id}" xsl:use-attribute-sets="appendix-style">
|
12399
12435
|
<xsl:apply-templates select="*[local-name()='title']"/>
|
12400
12436
|
</fo:block>
|
@@ -12405,13 +12441,14 @@
|
|
12405
12441
|
<xsl:variable name="level">
|
12406
12442
|
<xsl:call-template name="getLevel"/>
|
12407
12443
|
</xsl:variable>
|
12408
|
-
<fo:inline role="H{$level}"><xsl:apply-templates/></fo:inline>
|
12444
|
+
<fo:inline role="H{$level}"><xsl:call-template name="setIDforNamedDestination"/><xsl:apply-templates/></fo:inline>
|
12409
12445
|
</xsl:template>
|
12410
12446
|
<!-- ======================== -->
|
12411
12447
|
<!-- END Appendix processing -->
|
12412
12448
|
<!-- ======================== -->
|
12413
12449
|
|
12414
12450
|
<xsl:template match="*[local-name()='appendix']//*[local-name()='example']" priority="2">
|
12451
|
+
<xsl:call-template name="setNamedDestination"/>
|
12415
12452
|
<fo:block id="{@id}" xsl:use-attribute-sets="appendix-example-style">
|
12416
12453
|
<xsl:apply-templates select="*[local-name()='name']"/>
|
12417
12454
|
</fo:block>
|
@@ -12441,6 +12478,7 @@
|
|
12441
12478
|
<xsl:template match="*[local-name() = 'annotation']/*[local-name() = 'p']">
|
12442
12479
|
<xsl:param name="callout"/>
|
12443
12480
|
<fo:inline id="{@id}">
|
12481
|
+
<xsl:call-template name="setNamedDestination"/>
|
12444
12482
|
<!-- for first p in annotation, put <x> -->
|
12445
12483
|
<xsl:if test="not(preceding-sibling::*[local-name() = 'p'])"><xsl:value-of select="$callout"/></xsl:if>
|
12446
12484
|
<xsl:apply-templates/>
|
@@ -12491,6 +12529,7 @@
|
|
12491
12529
|
|
12492
12530
|
</xsl:if>
|
12493
12531
|
<fo:block-container margin-left="0mm" role="SKIP">
|
12532
|
+
<xsl:call-template name="setNamedDestination"/>
|
12494
12533
|
<fo:block id="{@id}">
|
12495
12534
|
<xsl:apply-templates select="node()[not(local-name() = 'name')]"/> <!-- formula's number will be process in 'stem' template -->
|
12496
12535
|
</fo:block>
|
@@ -12536,8 +12575,13 @@
|
|
12536
12575
|
</fo:block>
|
12537
12576
|
</fo:table-cell>
|
12538
12577
|
<fo:table-cell display-align="center">
|
12578
|
+
|
12539
12579
|
<fo:block xsl:use-attribute-sets="formula-stem-number-style" role="SKIP">
|
12540
12580
|
|
12581
|
+
<xsl:for-each select="../*[local-name() = 'name']">
|
12582
|
+
<xsl:call-template name="setIDforNamedDestination"/>
|
12583
|
+
</xsl:for-each>
|
12584
|
+
|
12541
12585
|
<xsl:call-template name="refine_formula-stem-number-style"/>
|
12542
12586
|
|
12543
12587
|
<xsl:apply-templates select="../*[local-name() = 'name']"/>
|
@@ -12572,6 +12616,7 @@
|
|
12572
12616
|
|
12573
12617
|
<xsl:template match="*[local-name() = 'note']" name="note">
|
12574
12618
|
|
12619
|
+
<xsl:call-template name="setNamedDestination"/>
|
12575
12620
|
<fo:block id="{@id}" xsl:use-attribute-sets="note-style" role="SKIP">
|
12576
12621
|
<xsl:call-template name="setBlockSpanAll"/>
|
12577
12622
|
|
@@ -12627,6 +12672,7 @@
|
|
12627
12672
|
</xsl:template>
|
12628
12673
|
|
12629
12674
|
<xsl:template match="*[local-name() = 'termnote']">
|
12675
|
+
<xsl:call-template name="setNamedDestination"/>
|
12630
12676
|
<fo:block id="{@id}" xsl:use-attribute-sets="termnote-style">
|
12631
12677
|
|
12632
12678
|
<xsl:call-template name="setBlockSpanAll"/>
|
@@ -12733,12 +12779,14 @@
|
|
12733
12779
|
|
12734
12780
|
<xsl:template match="*[local-name() = 'terms']">
|
12735
12781
|
<!-- <xsl:message>'terms' <xsl:number/> processing...</xsl:message> -->
|
12782
|
+
<xsl:call-template name="setNamedDestination"/>
|
12736
12783
|
<fo:block id="{@id}">
|
12737
12784
|
<xsl:apply-templates/>
|
12738
12785
|
</fo:block>
|
12739
12786
|
</xsl:template>
|
12740
12787
|
|
12741
12788
|
<xsl:template match="*[local-name() = 'term']">
|
12789
|
+
<xsl:call-template name="setNamedDestination"/>
|
12742
12790
|
<fo:block id="{@id}" xsl:use-attribute-sets="term-style">
|
12743
12791
|
|
12744
12792
|
<xsl:if test="parent::*[local-name() = 'term'] and not(preceding-sibling::*[local-name() = 'term'])">
|
@@ -12770,6 +12818,7 @@
|
|
12770
12818
|
<xsl:template match="*[local-name() = 'figure']" name="figure">
|
12771
12819
|
<xsl:variable name="isAdded" select="@added"/>
|
12772
12820
|
<xsl:variable name="isDeleted" select="@deleted"/>
|
12821
|
+
<xsl:call-template name="setNamedDestination"/>
|
12773
12822
|
<fo:block-container id="{@id}" xsl:use-attribute-sets="figure-block-style">
|
12774
12823
|
<xsl:call-template name="refine_figure-block-style"/>
|
12775
12824
|
|
@@ -12791,6 +12840,11 @@
|
|
12791
12840
|
</xsl:variable>
|
12792
12841
|
|
12793
12842
|
<fo:block xsl:use-attribute-sets="figure-style" role="SKIP">
|
12843
|
+
|
12844
|
+
<xsl:for-each select="*[local-name() = 'name']"> <!-- set context -->
|
12845
|
+
<xsl:call-template name="setIDforNamedDestination"/>
|
12846
|
+
</xsl:for-each>
|
12847
|
+
|
12794
12848
|
<xsl:apply-templates select="node()[not(local-name() = 'name') and not(local-name() = 'note' and @type = 'units')]"/>
|
12795
12849
|
</fo:block>
|
12796
12850
|
|
@@ -12835,6 +12889,7 @@
|
|
12835
12889
|
</xsl:template>
|
12836
12890
|
|
12837
12891
|
<xsl:template match="*[local-name() = 'figure'][@class = 'pseudocode']">
|
12892
|
+
<xsl:call-template name="setNamedDestination"/>
|
12838
12893
|
<fo:block id="{@id}">
|
12839
12894
|
<xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
|
12840
12895
|
</fo:block>
|
@@ -12848,6 +12903,7 @@
|
|
12848
12903
|
</xsl:template>
|
12849
12904
|
|
12850
12905
|
<!-- SOURCE: ... -->
|
12906
|
+
<!-- figure/source -->
|
12851
12907
|
<xsl:template match="*[local-name() = 'figure']/*[local-name() = 'source']" priority="2">
|
12852
12908
|
|
12853
12909
|
<xsl:call-template name="termsource"/>
|
@@ -14087,6 +14143,7 @@
|
|
14087
14143
|
<xsl:template match="title" mode="bookmark"/>
|
14088
14144
|
<xsl:template match="text()" mode="bookmark"/>
|
14089
14145
|
|
14146
|
+
<!-- figure/name -->
|
14090
14147
|
<xsl:template match="*[local-name() = 'figure']/*[local-name() = 'name'] | *[local-name() = 'image']/*[local-name() = 'name']">
|
14091
14148
|
<xsl:if test="normalize-space() != ''">
|
14092
14149
|
<fo:block xsl:use-attribute-sets="figure-name-style">
|
@@ -14801,6 +14858,7 @@
|
|
14801
14858
|
<!-- permission -->
|
14802
14859
|
<!-- ========== -->
|
14803
14860
|
<xsl:template match="*[local-name() = 'permission']">
|
14861
|
+
<xsl:call-template name="setNamedDestination"/>
|
14804
14862
|
<fo:block id="{@id}" xsl:use-attribute-sets="permission-style">
|
14805
14863
|
<xsl:apply-templates select="*[local-name()='name']"/>
|
14806
14864
|
<xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
|
@@ -14809,10 +14867,12 @@
|
|
14809
14867
|
|
14810
14868
|
<xsl:template match="*[local-name() = 'permission']/*[local-name() = 'name']">
|
14811
14869
|
<xsl:if test="normalize-space() != ''">
|
14812
|
-
<fo:block xsl:use-attribute-sets="permission-name-style">
|
14813
|
-
<xsl:apply-templates/>
|
14814
14870
|
|
14815
|
-
|
14871
|
+
<fo:block xsl:use-attribute-sets="permission-name-style">
|
14872
|
+
<xsl:apply-templates/>
|
14873
|
+
|
14874
|
+
</fo:block>
|
14875
|
+
|
14816
14876
|
</xsl:if>
|
14817
14877
|
</xsl:template>
|
14818
14878
|
|
@@ -14828,6 +14888,7 @@
|
|
14828
14888
|
<!-- requirement -->
|
14829
14889
|
<!-- ========== -->
|
14830
14890
|
<xsl:template match="*[local-name() = 'requirement']">
|
14891
|
+
<xsl:call-template name="setNamedDestination"/>
|
14831
14892
|
<fo:block id="{@id}" xsl:use-attribute-sets="requirement-style">
|
14832
14893
|
<xsl:apply-templates select="*[local-name()='name']"/>
|
14833
14894
|
<xsl:apply-templates select="*[local-name()='label']"/>
|
@@ -14839,11 +14900,13 @@
|
|
14839
14900
|
|
14840
14901
|
<xsl:template match="*[local-name() = 'requirement']/*[local-name() = 'name']">
|
14841
14902
|
<xsl:if test="normalize-space() != ''">
|
14842
|
-
<fo:block xsl:use-attribute-sets="requirement-name-style">
|
14843
14903
|
|
14844
|
-
|
14904
|
+
<fo:block xsl:use-attribute-sets="requirement-name-style">
|
14905
|
+
|
14906
|
+
<xsl:apply-templates/>
|
14907
|
+
|
14908
|
+
</fo:block>
|
14845
14909
|
|
14846
|
-
</fo:block>
|
14847
14910
|
</xsl:if>
|
14848
14911
|
</xsl:template>
|
14849
14912
|
|
@@ -14872,6 +14935,7 @@
|
|
14872
14935
|
<!-- recommendation -->
|
14873
14936
|
<!-- ========== -->
|
14874
14937
|
<xsl:template match="*[local-name() = 'recommendation']">
|
14938
|
+
<xsl:call-template name="setNamedDestination"/>
|
14875
14939
|
<fo:block id="{@id}" xsl:use-attribute-sets="recommendation-style">
|
14876
14940
|
<xsl:apply-templates select="*[local-name()='name']"/>
|
14877
14941
|
<xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
|
@@ -14880,10 +14944,12 @@
|
|
14880
14944
|
|
14881
14945
|
<xsl:template match="*[local-name() = 'recommendation']/*[local-name() = 'name']">
|
14882
14946
|
<xsl:if test="normalize-space() != ''">
|
14883
|
-
<fo:block xsl:use-attribute-sets="recommendation-name-style">
|
14884
|
-
<xsl:apply-templates/>
|
14885
14947
|
|
14886
|
-
|
14948
|
+
<fo:block xsl:use-attribute-sets="recommendation-name-style">
|
14949
|
+
<xsl:apply-templates/>
|
14950
|
+
|
14951
|
+
</fo:block>
|
14952
|
+
|
14887
14953
|
</xsl:if>
|
14888
14954
|
</xsl:template>
|
14889
14955
|
|
@@ -14962,6 +15028,7 @@
|
|
14962
15028
|
<xsl:if test="ancestor::*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
14963
15029
|
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
|
14964
15030
|
</xsl:if>
|
15031
|
+
<xsl:call-template name="setNamedDestination"/>
|
14965
15032
|
<fo:block-container margin-left="0mm" margin-right="0mm" role="SKIP">
|
14966
15033
|
<fo:table id="{@id}" table-layout="fixed" width="100%"> <!-- border="1pt solid black" -->
|
14967
15034
|
<xsl:if test="ancestor::*[local-name() = 'table'][@class = 'recommendation' or @class='requirement' or @class='permission']">
|
@@ -15071,6 +15138,7 @@
|
|
15071
15138
|
<!-- termexample -->
|
15072
15139
|
<!-- ====== -->
|
15073
15140
|
<xsl:template match="*[local-name() = 'termexample']">
|
15141
|
+
<xsl:call-template name="setNamedDestination"/>
|
15074
15142
|
<fo:block id="{@id}" xsl:use-attribute-sets="termexample-style">
|
15075
15143
|
<xsl:call-template name="refine_termexample-style"/>
|
15076
15144
|
<xsl:call-template name="setBlockSpanAll"/>
|
@@ -15125,6 +15193,7 @@
|
|
15125
15193
|
-->
|
15126
15194
|
<xsl:template match="*[local-name() = 'example']" name="example">
|
15127
15195
|
|
15196
|
+
<xsl:call-template name="setNamedDestination"/>
|
15128
15197
|
<fo:block id="{@id}" xsl:use-attribute-sets="example-style" role="SKIP">
|
15129
15198
|
<xsl:call-template name="setBlockSpanAll"/>
|
15130
15199
|
|
@@ -15597,12 +15666,17 @@
|
|
15597
15666
|
</xsl:if>
|
15598
15667
|
|
15599
15668
|
<xsl:if test="parent::*[local-name() = 'term'] and not(preceding-sibling::*[local-name() = 'preferred'])"> <!-- if first preffered in term, then display term's name -->
|
15669
|
+
|
15600
15670
|
<fo:block xsl:use-attribute-sets="term-name-style" role="SKIP">
|
15601
15671
|
|
15602
15672
|
<xsl:if test="not($vertical_layout = 'true')">
|
15603
15673
|
<xsl:attribute name="font-family">Times New Roman</xsl:attribute>
|
15604
15674
|
</xsl:if>
|
15605
15675
|
|
15676
|
+
<xsl:for-each select="ancestor::*[local-name() = 'term'][1]/*[local-name() = 'name']"><!-- change context -->
|
15677
|
+
<xsl:call-template name="setIDforNamedDestination"/>
|
15678
|
+
</xsl:for-each>
|
15679
|
+
|
15606
15680
|
<xsl:apply-templates select="ancestor::*[local-name() = 'term'][1]/*[local-name() = 'name']"/>
|
15607
15681
|
</fo:block>
|
15608
15682
|
</xsl:if>
|
@@ -15731,6 +15805,7 @@
|
|
15731
15805
|
<!-- main sections -->
|
15732
15806
|
<xsl:template match="/*/*[local-name() = 'sections']/*" name="sections_node" priority="2">
|
15733
15807
|
|
15808
|
+
<xsl:call-template name="setNamedDestination"/>
|
15734
15809
|
<fo:block>
|
15735
15810
|
<xsl:call-template name="setId"/>
|
15736
15811
|
|
@@ -15771,6 +15846,7 @@
|
|
15771
15846
|
|
15772
15847
|
<fo:block break-after="page"/>
|
15773
15848
|
|
15849
|
+
<xsl:call-template name="setNamedDestination"/>
|
15774
15850
|
<fo:block>
|
15775
15851
|
<xsl:call-template name="setId"/>
|
15776
15852
|
<xsl:call-template name="addReviewHelper"/>
|
@@ -15799,6 +15875,7 @@
|
|
15799
15875
|
</xsl:template>
|
15800
15876
|
|
15801
15877
|
<xsl:template match="*[local-name() = 'clause'][normalize-space() != '' or *[local-name() = 'figure'] or @id]" name="template_clause"> <!-- if clause isn't empty -->
|
15878
|
+
<xsl:call-template name="setNamedDestination"/>
|
15802
15879
|
<fo:block>
|
15803
15880
|
<xsl:if test="parent::*[local-name() = 'copyright-statement']">
|
15804
15881
|
<xsl:attribute name="role">SKIP</xsl:attribute>
|
@@ -15821,6 +15898,7 @@
|
|
15821
15898
|
</xsl:template> <!-- refine_clause_style -->
|
15822
15899
|
|
15823
15900
|
<xsl:template match="*[local-name() = 'definitions']">
|
15901
|
+
<xsl:call-template name="setNamedDestination"/>
|
15824
15902
|
<fo:block id="{@id}">
|
15825
15903
|
<xsl:apply-templates/>
|
15826
15904
|
</fo:block>
|
@@ -15836,6 +15914,8 @@
|
|
15836
15914
|
<xsl:otherwise>
|
15837
15915
|
|
15838
15916
|
<fo:block break-after="page"/>
|
15917
|
+
<xsl:call-template name="setNamedDestination"/>
|
15918
|
+
|
15839
15919
|
<fo:block id="{@id}">
|
15840
15920
|
|
15841
15921
|
<xsl:call-template name="setBlockSpanAll"/>
|
@@ -15907,6 +15987,7 @@
|
|
15907
15987
|
<!-- following-sibling::node()[1][local-name() = 'bookmark'][@id = $source] and
|
15908
15988
|
following-sibling::node()[2][local-name() = 'fmt-review-end'][@source = $source] -->
|
15909
15989
|
<!-- <fo:block id="{$source}" font-size="1pt" role="SKIP"><xsl:value-of select="$hair_space"/><fo:basic-link internal-destination="{$source}" fox:alt-text="Annot___{$source}" role="Annot"><xsl:value-of select="$hair_space"/></fo:basic-link></fo:block> -->
|
15990
|
+
<xsl:call-template name="setNamedDestination"/>
|
15910
15991
|
<fo:block id="{@id}" font-size="1pt" role="SKIP" keep-with-next="always" line-height="0.1"><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>
|
15911
15992
|
<!-- </xsl:if> -->
|
15912
15993
|
</xsl:if>
|
@@ -16648,6 +16729,7 @@
|
|
16648
16729
|
<!-- Normative references -->
|
16649
16730
|
<xsl:template match="*[local-name() = 'references'][@normative='true']" priority="2">
|
16650
16731
|
|
16732
|
+
<xsl:call-template name="setNamedDestination"/>
|
16651
16733
|
<fo:block id="{@id}">
|
16652
16734
|
<xsl:apply-templates/>
|
16653
16735
|
|
@@ -16678,6 +16760,7 @@
|
|
16678
16760
|
</xsl:if>
|
16679
16761
|
</xsl:if> -->
|
16680
16762
|
|
16763
|
+
<xsl:call-template name="setNamedDestination"/>
|
16681
16764
|
<fo:block id="{@id}"/>
|
16682
16765
|
|
16683
16766
|
<xsl:apply-templates select="*[local-name() = 'title'][@columns = 1]"/>
|
@@ -16702,6 +16785,7 @@
|
|
16702
16785
|
<xsl:template match="*[local-name() = 'references'][@normative='true']/*[local-name() = 'bibitem']" name="bibitem" priority="2">
|
16703
16786
|
<xsl:param name="skip" select="normalize-space(preceding-sibling::*[1][local-name() = 'bibitem'] and 1 = 1)"/> <!-- current bibiitem is non-first -->
|
16704
16787
|
|
16788
|
+
<xsl:call-template name="setNamedDestination"/>
|
16705
16789
|
<fo:block-container margin-left="6mm" role="SKIP">
|
16706
16790
|
<fo:block-container margin-left="0mm" role="SKIP">
|
16707
16791
|
<fo:block id="{@id}" xsl:use-attribute-sets="bibitem-normative-style">
|
@@ -16718,6 +16802,7 @@
|
|
16718
16802
|
<!-- $namespace = 'csd' or $namespace = 'gb' or $namespace = 'iec' or $namespace = 'ieee' or $namespace = 'iso' or $namespace = 'jcgm' or $namespace = 'm3d' or
|
16719
16803
|
$namespace = 'mpfd' or $namespace = 'ogc' or $namespace = 'ogc-white-paper' -->
|
16720
16804
|
<!-- Example: [1] ISO 9:1995, Information and documentation – Transliteration of Cyrillic characters into Latin characters – Slavic and non-Slavic languages -->
|
16805
|
+
<xsl:call-template name="setNamedDestination"/>
|
16721
16806
|
<fo:list-block id="{@id}" xsl:use-attribute-sets="bibitem-non-normative-list-style">
|
16722
16807
|
|
16723
16808
|
<fo:list-item>
|
@@ -16747,6 +16832,7 @@
|
|
16747
16832
|
<xsl:choose>
|
16748
16833
|
<xsl:when test="@hidden = 'true'"><!-- skip --></xsl:when>
|
16749
16834
|
<xsl:otherwise>
|
16835
|
+
<xsl:call-template name="setNamedDestination"/>
|
16750
16836
|
<fo:list-item id="{@id}" xsl:use-attribute-sets="bibitem-non-normative-list-item-style">
|
16751
16837
|
|
16752
16838
|
<fo:list-item-label end-indent="label-end()">
|
@@ -17143,6 +17229,7 @@
|
|
17143
17229
|
<xsl:template match="*[local-name() = 'admonition']">
|
17144
17230
|
|
17145
17231
|
<!-- text in the box -->
|
17232
|
+
<xsl:call-template name="setNamedDestination"/>
|
17146
17233
|
<fo:block-container id="{@id}" xsl:use-attribute-sets="admonition-style">
|
17147
17234
|
|
17148
17235
|
<xsl:call-template name="setBlockSpanAll"/>
|
@@ -17398,7 +17485,7 @@
|
|
17398
17485
|
</xsl:template>
|
17399
17486
|
|
17400
17487
|
<!-- Example with 'class': <span class="stdpublisher">ISO</span> <span class="stddocNumber">10303</span>-<span class="stddocPartNumber">1</span>:<span class="stdyear">1994</span> -->
|
17401
|
-
<xsl:template match="*[local-name() = 'span'][@style or @class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear' or @class = 'horizontal' or @class = 'norotate' or @class = 'halffontsize']" mode="update_xml_step1" priority="2">
|
17488
|
+
<xsl:template match="*[local-name() = 'span'][@style or @class = 'stdpublisher' or @class = 'stddocNumber' or @class = 'stddocPartNumber' or @class = 'stdyear' or @class = 'fmt-hi' or @class = 'horizontal' or @class = 'norotate' or @class = 'halffontsize']" mode="update_xml_step1" priority="2">
|
17402
17489
|
<xsl:copy>
|
17403
17490
|
<xsl:copy-of select="@*"/>
|
17404
17491
|
<xsl:apply-templates mode="update_xml_step1"/>
|
@@ -17430,28 +17517,56 @@
|
|
17430
17517
|
<xsl:template match="*[local-name() = 'stem']" mode="update_xml_step1"/>
|
17431
17518
|
<xsl:template match="*[local-name() = 'stem']" mode="update_xml_pres"/>
|
17432
17519
|
|
17433
|
-
<xsl:template match="*[local-name() = 'fmt-stem']
|
17520
|
+
<xsl:template match="*[local-name() = 'fmt-stem']" mode="update_xml_step1">
|
17434
17521
|
<xsl:element name="stem" namespace="{$namespace_full}">
|
17435
17522
|
<xsl:copy-of select="@*"/>
|
17436
17523
|
<xsl:choose>
|
17437
17524
|
<xsl:when test="*[local-name() = 'semx'] and count(node()) = 1">
|
17438
|
-
<xsl:
|
17525
|
+
<xsl:choose>
|
17526
|
+
<xsl:when test="not(.//*[local-name() = 'passthrough']) and not(.//*[@linebreak])">
|
17527
|
+
<xsl:copy-of select="*[local-name() = 'semx']/node()"/>
|
17528
|
+
</xsl:when>
|
17529
|
+
<xsl:otherwise>
|
17530
|
+
<xsl:apply-templates select="*[local-name() = 'semx']/node()" mode="update_xml_step1"/>
|
17531
|
+
</xsl:otherwise>
|
17532
|
+
</xsl:choose>
|
17439
17533
|
</xsl:when>
|
17440
17534
|
<xsl:otherwise>
|
17441
|
-
<xsl:
|
17535
|
+
<xsl:choose>
|
17536
|
+
<xsl:when test="not(.//*[local-name() = 'passthrough']) and not(.//*[@linebreak])">
|
17537
|
+
<xsl:copy-of select="node()"/>
|
17538
|
+
</xsl:when>
|
17539
|
+
<xsl:otherwise>
|
17540
|
+
<xsl:apply-templates select="node()" mode="update_xml_step1"/>
|
17541
|
+
</xsl:otherwise>
|
17542
|
+
</xsl:choose>
|
17442
17543
|
</xsl:otherwise>
|
17443
17544
|
</xsl:choose>
|
17444
17545
|
</xsl:element>
|
17445
17546
|
</xsl:template>
|
17446
|
-
<xsl:template match="*[local-name() = 'fmt-stem']
|
17547
|
+
<xsl:template match="*[local-name() = 'fmt-stem']" mode="update_xml_pres">
|
17447
17548
|
<xsl:element name="stem" namespace="{$namespace_full}">
|
17448
17549
|
<xsl:copy-of select="@*"/>
|
17449
17550
|
<xsl:choose>
|
17450
17551
|
<xsl:when test="*[local-name() = 'semx'] and count(node()) = 1">
|
17451
|
-
<xsl:
|
17552
|
+
<xsl:choose>
|
17553
|
+
<xsl:when test="not(.//*[local-name() = 'passthrough']) and not(.//*[@linebreak])">
|
17554
|
+
<xsl:copy-of select="*[local-name() = 'semx']/node()"/>
|
17555
|
+
</xsl:when>
|
17556
|
+
<xsl:otherwise>
|
17557
|
+
<xsl:apply-templates select="*[local-name() = 'semx']/node()" mode="update_xml_pres"/>
|
17558
|
+
</xsl:otherwise>
|
17559
|
+
</xsl:choose>
|
17452
17560
|
</xsl:when>
|
17453
17561
|
<xsl:otherwise>
|
17454
|
-
<xsl:
|
17562
|
+
<xsl:choose>
|
17563
|
+
<xsl:when test="not(.//*[local-name() = 'passthrough']) and not(.//*[@linebreak])">
|
17564
|
+
<xsl:copy-of select="node()"/>
|
17565
|
+
</xsl:when>
|
17566
|
+
<xsl:otherwise>
|
17567
|
+
<xsl:apply-templates select="node()" mode="update_xml_pres"/>
|
17568
|
+
</xsl:otherwise>
|
17569
|
+
</xsl:choose>
|
17455
17570
|
</xsl:otherwise>
|
17456
17571
|
</xsl:choose>
|
17457
17572
|
</xsl:element>
|
@@ -17680,16 +17795,24 @@
|
|
17680
17795
|
<xsl:template match="*[local-name() = 'fmt-title']" mode="update_xml_step1">
|
17681
17796
|
<xsl:element name="title" namespace="{$namespace_full}">
|
17682
17797
|
<xsl:copy-of select="@*"/>
|
17798
|
+
<xsl:call-template name="addNamedDestinationAttribute"/>
|
17799
|
+
|
17683
17800
|
<xsl:apply-templates mode="update_xml_step1"/>
|
17684
17801
|
</xsl:element>
|
17685
17802
|
</xsl:template>
|
17686
17803
|
<xsl:template match="*[local-name() = 'fmt-title']" mode="update_xml_pres">
|
17687
17804
|
<xsl:element name="title" namespace="{$namespace_full}">
|
17688
17805
|
<xsl:copy-of select="@*"/>
|
17806
|
+
<xsl:call-template name="addNamedDestinationAttribute"/>
|
17807
|
+
|
17689
17808
|
<xsl:apply-templates mode="update_xml_pres"/>
|
17690
17809
|
</xsl:element>
|
17691
17810
|
</xsl:template>
|
17692
17811
|
|
17812
|
+
<xsl:template name="addNamedDestinationAttribute">
|
17813
|
+
|
17814
|
+
</xsl:template>
|
17815
|
+
|
17693
17816
|
<xsl:template match="*[local-name() = 'fmt-name']"/>
|
17694
17817
|
<xsl:template match="*[local-name() = 'fmt-name']" mode="update_xml_step1">
|
17695
17818
|
<xsl:choose>
|
@@ -17699,6 +17822,8 @@
|
|
17699
17822
|
<xsl:otherwise>
|
17700
17823
|
<xsl:element name="name" namespace="{$namespace_full}">
|
17701
17824
|
<xsl:copy-of select="@*"/>
|
17825
|
+
<xsl:call-template name="addNamedDestinationAttribute"/>
|
17826
|
+
|
17702
17827
|
<xsl:apply-templates mode="update_xml_step1"/>
|
17703
17828
|
</xsl:element>
|
17704
17829
|
</xsl:otherwise>
|
@@ -17712,6 +17837,8 @@
|
|
17712
17837
|
<xsl:otherwise>
|
17713
17838
|
<xsl:element name="name" namespace="{$namespace_full}">
|
17714
17839
|
<xsl:copy-of select="@*"/>
|
17840
|
+
<xsl:call-template name="addNamedDestinationAttribute"/>
|
17841
|
+
|
17715
17842
|
<xsl:apply-templates mode="update_xml_pres"/>
|
17716
17843
|
</xsl:element>
|
17717
17844
|
</xsl:otherwise>
|
@@ -19281,6 +19408,24 @@
|
|
19281
19408
|
</xsl:attribute>
|
19282
19409
|
</xsl:template>
|
19283
19410
|
|
19411
|
+
<xsl:template name="setIDforNamedDestination">
|
19412
|
+
<xsl:if test="@named_dest">
|
19413
|
+
<xsl:attribute name="id"><xsl:value-of select="@named_dest"/></xsl:attribute>
|
19414
|
+
</xsl:if>
|
19415
|
+
</xsl:template>
|
19416
|
+
|
19417
|
+
<xsl:template name="setNamedDestination">
|
19418
|
+
<!-- skip GUID, e.g. _33eac3cb-9663-4291-ae26-1d4b6f4635fc -->
|
19419
|
+
<xsl:if test="@id and normalize-space(java:matches(java:java.lang.String.new(@id), '_[0-9a-z]{8}-[0-9a-z]{4}-[0-9a-z]{4}-[0-9a-z]{4}-[0-9a-z]{12}')) = 'false'">
|
19420
|
+
<fox:destination internal-destination="{@id}"/>
|
19421
|
+
</xsl:if>
|
19422
|
+
<xsl:for-each select=". | *[local-name() = 'title'] | *[local-name() = 'name']">
|
19423
|
+
<xsl:if test="@named_dest">
|
19424
|
+
<fox:destination internal-destination="{@named_dest}"/>
|
19425
|
+
</xsl:if>
|
19426
|
+
</xsl:for-each>
|
19427
|
+
</xsl:template>
|
19428
|
+
|
19284
19429
|
<xsl:template name="add-letter-spacing">
|
19285
19430
|
<xsl:param name="text"/>
|
19286
19431
|
<xsl:param name="letter-spacing" select="'0.15'"/>
|
@@ -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.0.
|
3
|
+
<!-- VERSION v2.0.4 -->
|
4
4
|
|
5
5
|
<!--
|
6
6
|
ALERT: cannot have root comments, because of https://github.com/metanorma/metanorma/issues/437
|
@@ -1328,6 +1328,7 @@ numbers</a:documentation>
|
|
1328
1328
|
<ref name="foreword"/>
|
1329
1329
|
<ref name="introduction"/>
|
1330
1330
|
<ref name="acknowledgements"/>
|
1331
|
+
<ref name="executivesummary"/>
|
1331
1332
|
</choice>
|
1332
1333
|
</oneOrMore>
|
1333
1334
|
</element>
|
@@ -1351,6 +1352,11 @@ numbers</a:documentation>
|
|
1351
1352
|
<ref name="Content-Section"/>
|
1352
1353
|
</element>
|
1353
1354
|
</define>
|
1355
|
+
<define name="executivesummary">
|
1356
|
+
<element name="executivesummary">
|
1357
|
+
<ref name="Content-Section"/>
|
1358
|
+
</element>
|
1359
|
+
</define>
|
1354
1360
|
<define name="indexsect">
|
1355
1361
|
<element name="indexsect">
|
1356
1362
|
<ref name="Content-Section"/>
|
@@ -1576,6 +1582,15 @@ used in document amendments</a:documentation>
|
|
1576
1582
|
<define name="annex">
|
1577
1583
|
<element name="annex">
|
1578
1584
|
<ref name="Annex-Section"/>
|
1585
|
+
<zeroOrMore>
|
1586
|
+
<ref name="annex-appendix"/>
|
1587
|
+
</zeroOrMore>
|
1588
|
+
</element>
|
1589
|
+
</define>
|
1590
|
+
<define name="annex-appendix">
|
1591
|
+
<a:documentation>Appendix, distinct subclause type for annexes (annex to annex, rather than subclause to annex)</a:documentation>
|
1592
|
+
<element name="appendix">
|
1593
|
+
<ref name="Clause-Section"/>
|
1579
1594
|
</element>
|
1580
1595
|
</define>
|
1581
1596
|
<define name="terms">
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-jis
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-04-
|
11
|
+
date: 2025-04-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: japanese_calendar
|