metanorma-csa 1.8.6 → 1.8.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6a2e03feb739aabfc961bd51cc96d8a53e8674f3eb38bbac70454589af496b1d
4
- data.tar.gz: 2c45447a23dabcdc9d576f639b9cdd33917ff50735a9ece2fe1e05fb3fb21d7d
3
+ metadata.gz: 9094d8995d85f10e6c8eddfce465454dcfe379e7db8efe451be85797e53561d8
4
+ data.tar.gz: 6a26595d2a01ff9d0eb8b06cb398d335c5677dbf199d9c6e783183537cdb4f08
5
5
  SHA512:
6
- metadata.gz: cd7fd0308056d12550c14d34d26d0c8edf28ba858a01c68bb3309cf3f0c4ea3783f209b99c4febf06b2273671bc6cbbf62588829fc5e1d15f611f7567cbfd933
7
- data.tar.gz: f7d7afb0d291654e4d175199741f74477c2ed6ab0a9dc3f56907699562a48e1b0bb2e7b44f231430d098ff109c4f7844fdb51ec6afc3b6201e33bcbf07480b52
6
+ metadata.gz: cb9383ca3d2fe13856b32c444d4c045f068b0a43600bef990da214a4d73d13444e2b5cb9e142831e3c01325a0f28c5c908220d23b2c8ae27b6666396cef3c529
7
+ data.tar.gz: 19f78275afd29167bdc5813fc41fb155e9137e1dbece3ad3be8415f430244296ad2fafd1d3bee3ed41a845dce383968ea0922e4277f114f1b2e1fe2a5cdb9c87
@@ -204,6 +204,18 @@
204
204
  </zeroOrMore>
205
205
  </element>
206
206
  </define>
207
+ <define name="dt">
208
+ <element name="dt">
209
+ <optional>
210
+ <attribute name="id">
211
+ <data type="ID"/>
212
+ </attribute>
213
+ </optional>
214
+ <zeroOrMore>
215
+ <ref name="TextElement"/>
216
+ </zeroOrMore>
217
+ </element>
218
+ </define>
207
219
  <define name="example">
208
220
  <element name="example">
209
221
  <attribute name="id">
@@ -899,7 +911,7 @@
899
911
  </include>
900
912
  <!-- end overrides -->
901
913
  <define name="docsubtype">
902
- <element name="docsubtype">
914
+ <element name="subdoctype">
903
915
  <ref name="DocumentSubtype"/>
904
916
  </element>
905
917
  </define>
@@ -954,6 +966,16 @@
954
966
  </define>
955
967
  <define name="concept">
956
968
  <element name="concept">
969
+ <optional>
970
+ <attribute name="ital">
971
+ <data type="boolean"/>
972
+ </attribute>
973
+ </optional>
974
+ <optional>
975
+ <attribute name="ref">
976
+ <data type="boolean"/>
977
+ </attribute>
978
+ </optional>
957
979
  <optional>
958
980
  <element name="refterm">
959
981
  <zeroOrMore>
@@ -998,6 +1020,9 @@
998
1020
  </attribute>
999
1021
  <attribute name="name"/>
1000
1022
  <attribute name="action"/>
1023
+ <optional>
1024
+ <attribute name="class"/>
1025
+ </optional>
1001
1026
  <zeroOrMore>
1002
1027
  <choice>
1003
1028
  <ref name="TextElement"/>
@@ -1490,26 +1515,26 @@
1490
1515
  <optional>
1491
1516
  <ref name="section-title"/>
1492
1517
  </optional>
1493
- <group>
1518
+ <choice>
1494
1519
  <choice>
1495
1520
  <group>
1496
- <zeroOrMore>
1521
+ <oneOrMore>
1497
1522
  <ref name="BasicBlock"/>
1498
- </zeroOrMore>
1523
+ </oneOrMore>
1499
1524
  <zeroOrMore>
1500
1525
  <ref name="note"/>
1501
1526
  </zeroOrMore>
1502
1527
  </group>
1503
1528
  <ref name="amend"/>
1504
1529
  </choice>
1505
- <zeroOrMore>
1530
+ <oneOrMore>
1506
1531
  <choice>
1507
1532
  <ref name="clause-subsection"/>
1508
1533
  <ref name="terms"/>
1509
1534
  <ref name="definitions"/>
1510
1535
  </choice>
1511
- </zeroOrMore>
1512
- </group>
1536
+ </oneOrMore>
1537
+ </choice>
1513
1538
  </define>
1514
1539
  <define name="Annex-Section">
1515
1540
  <optional>
@@ -2025,6 +2025,7 @@
2025
2025
 
2026
2026
 
2027
2027
 
2028
+
2028
2029
  <!-- fn will be processed inside 'note' processing -->
2029
2030
 
2030
2031
 
@@ -2033,6 +2034,10 @@
2033
2034
 
2034
2035
 
2035
2036
 
2037
+
2038
+ <!-- for BSI (not PAS) display Notes before footnotes -->
2039
+
2040
+
2036
2041
  <!-- except gb -->
2037
2042
 
2038
2043
  <xsl:apply-templates select="../*[local-name()='note']" mode="process"/>
@@ -2058,6 +2063,10 @@
2058
2063
  <!-- fn processing -->
2059
2064
  <xsl:call-template name="fn_display"/>
2060
2065
 
2066
+
2067
+ <!-- for PAS display Notes after footnotes -->
2068
+
2069
+
2061
2070
  </fo:table-cell>
2062
2071
  </fo:table-row>
2063
2072
  </fo:table-body>
@@ -2115,6 +2124,7 @@
2115
2124
  <xsl:if test="$parent-name = 'tfoot'">
2116
2125
 
2117
2126
 
2127
+
2118
2128
  </xsl:if>
2119
2129
 
2120
2130
 
@@ -2243,8 +2253,13 @@
2243
2253
 
2244
2254
 
2245
2255
 
2256
+
2257
+ <!-- Table's note name (NOTE, for example) -->
2258
+
2246
2259
  <fo:inline padding-right="2mm">
2247
2260
 
2261
+
2262
+
2248
2263
 
2249
2264
 
2250
2265
 
@@ -2252,6 +2267,8 @@
2252
2267
 
2253
2268
  </fo:inline>
2254
2269
 
2270
+
2271
+
2255
2272
  <xsl:apply-templates mode="process"/>
2256
2273
  </fo:block>
2257
2274
 
@@ -2271,6 +2288,8 @@
2271
2288
  <xsl:variable name="reference" select="@reference"/>
2272
2289
  <xsl:if test="not(preceding-sibling::*[@reference = $reference])"> <!-- only unique reference puts in note-->
2273
2290
  <fo:block margin-bottom="12pt">
2291
+
2292
+
2274
2293
 
2275
2294
 
2276
2295
 
@@ -2288,6 +2307,7 @@
2288
2307
  <xsl:value-of select="@reference"/>
2289
2308
 
2290
2309
 
2310
+
2291
2311
  </fo:inline>
2292
2312
  <fo:inline>
2293
2313
 
@@ -2437,6 +2457,7 @@
2437
2457
 
2438
2458
  <xsl:value-of select="@reference"/>
2439
2459
 
2460
+
2440
2461
  </fo:basic-link>
2441
2462
  </fo:inline>
2442
2463
  </xsl:template><xsl:template match="*[local-name()='fn']/*[local-name()='p']">
@@ -3440,6 +3461,7 @@
3440
3461
 
3441
3462
 
3442
3463
 
3464
+
3443
3465
  <fo:block-container margin-left="0mm">
3444
3466
 
3445
3467
 
@@ -4646,9 +4668,10 @@
4646
4668
 
4647
4669
 
4648
4670
  </xsl:if>
4649
-
4671
+
4672
+
4673
+
4650
4674
  <fo:basic-link internal-destination="{@bibitemid}" fox:alt-text="{@citeas}">
4651
-
4652
4675
  <xsl:if test="normalize-space(@citeas) = ''">
4653
4676
  <xsl:attribute name="fox:alt-text"><xsl:value-of select="."/></xsl:attribute>
4654
4677
  </xsl:if>
@@ -4656,6 +4679,7 @@
4656
4679
 
4657
4680
 
4658
4681
 
4682
+
4659
4683
  </xsl:if>
4660
4684
 
4661
4685
  <xsl:apply-templates/>
@@ -5569,4 +5593,100 @@
5569
5593
  <xsl:otherwise><xsl:value-of select="$default"/></xsl:otherwise>
5570
5594
  </xsl:choose>
5571
5595
  </xsl:attribute>
5596
+ </xsl:template><xsl:template name="number-to-words">
5597
+ <xsl:param name="number"/>
5598
+ <xsl:param name="first"/>
5599
+ <xsl:if test="$number != ''">
5600
+ <xsl:variable name="words">
5601
+ <words>
5602
+ <word cardinal="1">One-</word>
5603
+ <word ordinal="1">First </word>
5604
+ <word cardinal="2">Two-</word>
5605
+ <word ordinal="2">Second </word>
5606
+ <word cardinal="3">Three-</word>
5607
+ <word ordinal="3">Third </word>
5608
+ <word cardinal="4">Four-</word>
5609
+ <word ordinal="4">Fourth </word>
5610
+ <word cardinal="5">Five-</word>
5611
+ <word ordinal="5">Fifth </word>
5612
+ <word cardinal="6">Six-</word>
5613
+ <word ordinal="6">Sixth </word>
5614
+ <word cardinal="7">Seven-</word>
5615
+ <word ordinal="7">Seventh </word>
5616
+ <word cardinal="8">Eight-</word>
5617
+ <word ordinal="8">Eighth </word>
5618
+ <word cardinal="9">Nine-</word>
5619
+ <word ordinal="9">Ninth </word>
5620
+ <word ordinal="10">Tenth </word>
5621
+ <word ordinal="11">Eleventh </word>
5622
+ <word ordinal="12">Twelfth </word>
5623
+ <word ordinal="13">Thirteenth </word>
5624
+ <word ordinal="14">Fourteenth </word>
5625
+ <word ordinal="15">Fifteenth </word>
5626
+ <word ordinal="16">Sixteenth </word>
5627
+ <word ordinal="17">Seventeenth </word>
5628
+ <word ordinal="18">Eighteenth </word>
5629
+ <word ordinal="19">Nineteenth </word>
5630
+ <word cardinal="20">Twenty-</word>
5631
+ <word ordinal="20">Twentieth </word>
5632
+ <word cardinal="30">Thirty-</word>
5633
+ <word ordinal="30">Thirtieth </word>
5634
+ <word cardinal="40">Forty-</word>
5635
+ <word ordinal="40">Fortieth </word>
5636
+ <word cardinal="50">Fifty-</word>
5637
+ <word ordinal="50">Fiftieth </word>
5638
+ <word cardinal="60">Sixty-</word>
5639
+ <word ordinal="60">Sixtieth </word>
5640
+ <word cardinal="70">Seventy-</word>
5641
+ <word ordinal="70">Seventieth </word>
5642
+ <word cardinal="80">Eighty-</word>
5643
+ <word ordinal="80">Eightieth </word>
5644
+ <word cardinal="90">Ninety-</word>
5645
+ <word ordinal="90">Ninetieth </word>
5646
+ <word cardinal="100">Hundred-</word>
5647
+ <word ordinal="100">Hundredth </word>
5648
+ </words>
5649
+ </xsl:variable>
5650
+
5651
+ <xsl:variable name="ordinal" select="xalan:nodeset($words)//word[@ordinal = $number]/text()"/>
5652
+
5653
+ <xsl:variable name="value">
5654
+ <xsl:choose>
5655
+ <xsl:when test="$ordinal != ''">
5656
+ <xsl:value-of select="$ordinal"/>
5657
+ </xsl:when>
5658
+ <xsl:otherwise>
5659
+ <xsl:choose>
5660
+ <xsl:when test="$number &lt; 100">
5661
+ <xsl:variable name="decade" select="concat(substring($number,1,1), '0')"/>
5662
+ <xsl:variable name="digit" select="substring($number,2)"/>
5663
+ <xsl:value-of select="xalan:nodeset($words)//word[@cardinal = $decade]/text()"/>
5664
+ <xsl:value-of select="xalan:nodeset($words)//word[@ordinal = $digit]/text()"/>
5665
+ </xsl:when>
5666
+ <xsl:otherwise>
5667
+ <!-- more 100 -->
5668
+ <xsl:variable name="hundred" select="substring($number,1,1)"/>
5669
+ <xsl:variable name="digits" select="number(substring($number,2))"/>
5670
+ <xsl:value-of select="xalan:nodeset($words)//word[@cardinal = $hundred]/text()"/>
5671
+ <xsl:value-of select="xalan:nodeset($words)//word[@cardinal = '100']/text()"/>
5672
+ <xsl:call-template name="number-to-words">
5673
+ <xsl:with-param name="number" select="$digits"/>
5674
+ </xsl:call-template>
5675
+ </xsl:otherwise>
5676
+ </xsl:choose>
5677
+ </xsl:otherwise>
5678
+ </xsl:choose>
5679
+ </xsl:variable>
5680
+ <xsl:choose>
5681
+ <xsl:when test="$first = 'true'">
5682
+ <xsl:variable name="value_lc" select="java:toLowerCase(java:java.lang.String.new($value))"/>
5683
+ <xsl:call-template name="capitalize">
5684
+ <xsl:with-param name="str" select="$value_lc"/>
5685
+ </xsl:call-template>
5686
+ </xsl:when>
5687
+ <xsl:otherwise>
5688
+ <xsl:value-of select="$value"/>
5689
+ </xsl:otherwise>
5690
+ </xsl:choose>
5691
+ </xsl:if>
5572
5692
  </xsl:template></xsl:stylesheet>
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module Csa
3
- VERSION = "1.8.6".freeze
3
+ VERSION = "1.8.7".freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-csa
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.6
4
+ version: 1.8.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-07-05 00:00:00.000000000 Z
11
+ date: 2021-07-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: metanorma-generic