metanorma-ribose 2.5.4 → 2.5.5

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: 0e2a208e23afd90c2aa649421d15bd39117706eca766ef491431b52f5ea176d6
4
- data.tar.gz: 9b22ff4c6861fee21e9aac9182f6c064441bd0af71076c4e901b9d6dfcda62f5
3
+ metadata.gz: 7c3761f452a1896870000f02c8af971bbe606801653ba71a7e5bfdc46474e731
4
+ data.tar.gz: 622820aa78a60196670b478f5a2a000c6a2c478ecd2c21ce263b6dd1f87afff8
5
5
  SHA512:
6
- metadata.gz: aa20ac0be3b2af9dfef258d583b4d54ea9ffb783cd73fac4621629dd374589d2378cc9a59f5b94559bbf9eb47223bdbe39ec59132bc8a2ab548304208ab127ca
7
- data.tar.gz: 102e0dbfea1d9b793693cefcb816defe54bca03fd60ff0e0717b9d842f184aaad551c7645b9b5b317b65a4956bb72c4991958f54a6b0a55fbe0d630f4dad9171
6
+ metadata.gz: ca70973ef801ddb22d29d66e6ab0b85125a38986bb4814c6f5cff1e554752126da9889334e9b1c2fc5c0d5cc73a186fd474e4f503d7ad866c133e9be687457c6
7
+ data.tar.gz: b0601319759e71784f409a4bb0bb8f04c08935677d2c6a4ba41ab2db5c2eb38cd71d8a0d3b9234b0f73d78e41501a30d6758c0d7a575b843c5fb2d284cabba61
@@ -4754,10 +4754,14 @@
4754
4754
  <xsl:variable name="fn_styles">
4755
4755
  <xsl:choose>
4756
4756
  <xsl:when test="ancestor::*[local-name() = 'bibitem']">
4757
- <fn_styles xsl:use-attribute-sets="bibitem-note-fn-style"/>
4757
+ <fn_styles xsl:use-attribute-sets="bibitem-note-fn-style">
4758
+
4759
+ </fn_styles>
4758
4760
  </xsl:when>
4759
4761
  <xsl:otherwise>
4760
- <fn_styles xsl:use-attribute-sets="fn-num-style"/>
4762
+ <fn_styles xsl:use-attribute-sets="fn-num-style">
4763
+
4764
+ </fn_styles>
4761
4765
  </xsl:otherwise>
4762
4766
  </xsl:choose>
4763
4767
  </xsl:variable>
@@ -7631,6 +7635,7 @@
7631
7635
  <xsl:if test="string-length(normalize-space()) &lt; 30 and not(contains(normalize-space(), 'http://')) and not(contains(normalize-space(), 'https://')) and not(ancestor::*[local-name() = 'table' or local-name() = 'dl'])">
7632
7636
  <xsl:attribute name="keep-together.within-line">always</xsl:attribute>
7633
7637
  </xsl:if>
7638
+
7634
7639
  <xsl:if test="parent::*[local-name() = 'add']">
7635
7640
  <xsl:call-template name="append_add-style"/>
7636
7641
  </xsl:if>
@@ -7739,44 +7744,44 @@
7739
7744
 
7740
7745
  <xsl:template match="*[local-name() = 'note']" name="note">
7741
7746
 
7742
- <fo:block-container id="{@id}" xsl:use-attribute-sets="note-style" role="SKIP">
7747
+ <fo:block-container id="{@id}" xsl:use-attribute-sets="note-style" role="SKIP">
7743
7748
 
7744
- <xsl:call-template name="setBlockSpanAll"/>
7749
+ <xsl:call-template name="setBlockSpanAll"/>
7745
7750
 
7746
- <xsl:call-template name="refine_note-style"/>
7751
+ <xsl:call-template name="refine_note-style"/>
7747
7752
 
7748
- <fo:block-container margin-left="0mm" margin-right="0mm" role="SKIP">
7753
+ <fo:block-container margin-left="0mm" margin-right="0mm" role="SKIP">
7749
7754
 
7750
- <fo:block>
7755
+ <fo:block>
7751
7756
 
7752
- <xsl:call-template name="refine_note_block_style"/>
7757
+ <xsl:call-template name="refine_note_block_style"/>
7753
7758
 
7754
- <fo:inline xsl:use-attribute-sets="note-name-style" role="SKIP">
7759
+ <fo:inline xsl:use-attribute-sets="note-name-style" role="SKIP">
7755
7760
 
7756
- <xsl:call-template name="refine_note-name-style"/>
7761
+ <xsl:call-template name="refine_note-name-style"/>
7757
7762
 
7758
- <!-- if 'p' contains all text in 'add' first and last elements in first p are 'add' -->
7759
- <!-- <xsl:if test="*[not(local-name()='name')][1][node()[normalize-space() != ''][1][local-name() = 'add'] and node()[normalize-space() != ''][last()][local-name() = 'add']]"> -->
7760
- <xsl:if test="*[not(local-name()='name')][1][count(node()[normalize-space() != '']) = 1 and *[local-name() = 'add']]">
7761
- <xsl:call-template name="append_add-style"/>
7762
- </xsl:if>
7763
+ <!-- if 'p' contains all text in 'add' first and last elements in first p are 'add' -->
7764
+ <!-- <xsl:if test="*[not(local-name()='name')][1][node()[normalize-space() != ''][1][local-name() = 'add'] and node()[normalize-space() != ''][last()][local-name() = 'add']]"> -->
7765
+ <xsl:if test="*[not(local-name()='name')][1][count(node()[normalize-space() != '']) = 1 and *[local-name() = 'add']]">
7766
+ <xsl:call-template name="append_add-style"/>
7767
+ </xsl:if>
7763
7768
 
7764
- <!-- if note contains only one element and first and last childs are `add` ace-tag, then move start ace-tag before NOTE's name-->
7765
- <xsl:if test="count(*[not(local-name() = 'name')]) = 1 and *[not(local-name() = 'name')]/node()[last()][local-name() = 'add'][starts-with(text(), $ace_tag)]">
7766
- <xsl:apply-templates select="*[not(local-name() = 'name')]/node()[1][local-name() = 'add'][starts-with(text(), $ace_tag)]">
7767
- <xsl:with-param name="skip">false</xsl:with-param>
7768
- </xsl:apply-templates>
7769
- </xsl:if>
7769
+ <!-- if note contains only one element and first and last childs are `add` ace-tag, then move start ace-tag before NOTE's name-->
7770
+ <xsl:if test="count(*[not(local-name() = 'name')]) = 1 and *[not(local-name() = 'name')]/node()[last()][local-name() = 'add'][starts-with(text(), $ace_tag)]">
7771
+ <xsl:apply-templates select="*[not(local-name() = 'name')]/node()[1][local-name() = 'add'][starts-with(text(), $ace_tag)]">
7772
+ <xsl:with-param name="skip">false</xsl:with-param>
7773
+ </xsl:apply-templates>
7774
+ </xsl:if>
7770
7775
 
7771
- <xsl:apply-templates select="*[local-name() = 'name']"/>
7776
+ <xsl:apply-templates select="*[local-name() = 'name']"/>
7772
7777
 
7773
- </fo:inline>
7778
+ </fo:inline>
7774
7779
 
7775
- <xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
7776
- </fo:block>
7780
+ <xsl:apply-templates select="node()[not(local-name() = 'name')]"/>
7781
+ </fo:block>
7777
7782
 
7778
- </fo:block-container>
7779
- </fo:block-container>
7783
+ </fo:block-container>
7784
+ </fo:block-container>
7780
7785
 
7781
7786
  </xsl:template>
7782
7787
 
@@ -10186,6 +10191,7 @@
10186
10191
  </xsl:when>
10187
10192
  <xsl:when test="contains(normalize-space($fo_element), 'block')">
10188
10193
  <fo:block xsl:use-attribute-sets="example-name-style">
10194
+
10189
10195
  <xsl:apply-templates/>
10190
10196
  </fo:block>
10191
10197
  </xsl:when>
@@ -10201,6 +10207,7 @@
10201
10207
 
10202
10208
  <xsl:template match="*[local-name() = 'table']/*[local-name() = 'example']/*[local-name() = 'name']">
10203
10209
  <fo:inline xsl:use-attribute-sets="example-name-style">
10210
+
10204
10211
  <xsl:apply-templates/>
10205
10212
  </fo:inline>
10206
10213
  </xsl:template>
@@ -10572,12 +10579,14 @@
10572
10579
 
10573
10580
  <xsl:if test="parent::*[local-name() = 'term'] and not(preceding-sibling::*[local-name() = 'preferred'])"> <!-- if first preffered in term, then display term's name -->
10574
10581
  <fo:block xsl:use-attribute-sets="term-name-style" role="SKIP">
10582
+
10575
10583
  <xsl:apply-templates select="ancestor::*[local-name() = 'term'][1]/*[local-name() = 'name']"/>
10576
10584
  </fo:block>
10577
10585
  </xsl:if>
10578
10586
 
10579
10587
  <fo:block xsl:use-attribute-sets="preferred-term-style" role="SKIP">
10580
10588
  <xsl:call-template name="setStyle_preferred"/>
10589
+
10581
10590
  <xsl:apply-templates/>
10582
10591
  </fo:block>
10583
10592
  </fo:block>
@@ -13528,9 +13537,10 @@
13528
13537
  <xsl:template name="insertBackgroundPageImage">
13529
13538
  <xsl:param name="number">1</xsl:param>
13530
13539
  <xsl:param name="name">coverpage-image</xsl:param>
13540
+ <xsl:param name="suffix"/>
13531
13541
  <xsl:variable name="num" select="number($number)"/>
13532
13542
  <!-- background image -->
13533
- <fo:block-container absolute-position="fixed" left="0mm" top="0mm" font-size="0" id="__internal_layout__coverpage_{$name}_{$number}_{generate-id()}">
13543
+ <fo:block-container absolute-position="fixed" left="0mm" top="0mm" font-size="0" id="__internal_layout__coverpage{$suffix}_{$name}_{$number}_{generate-id()}">
13534
13544
  <fo:block>
13535
13545
  <xsl:for-each select="/*[contains(local-name(), '-standard')]/*[local-name() = 'metanorma-extension']/*[local-name() = 'presentation-metadata'][*[local-name() = 'name'] = $name][1]/*[local-name() = 'value']/*[local-name() = 'image'][$num]">
13536
13546
  <xsl:choose>
@@ -13596,16 +13606,29 @@
13596
13606
 
13597
13607
  <!-- END: insert cover page image -->
13598
13608
 
13609
+ <xsl:variable name="regex_ja_spec">[\uFF08\uFF09]</xsl:variable>
13599
13610
  <xsl:template name="insertVerticalChar">
13600
13611
  <xsl:param name="str"/>
13612
+ <xsl:param name="writing-mode">lr-tb</xsl:param>
13613
+ <xsl:param name="reference-orientation">90</xsl:param>
13601
13614
  <xsl:if test="string-length($str) &gt; 0">
13602
- <fo:inline-container writing-mode="lr-tb" text-align="center" alignment-baseline="central" reference-orientation="90" width="1em" margin="0" padding="0" text-indent="0mm" last-line-end-indent="0mm" start-indent="0mm" end-indent="0mm">
13615
+ <fo:inline-container text-align="center" alignment-baseline="central" width="1em" margin="0" padding="0" text-indent="0mm" last-line-end-indent="0mm" start-indent="0mm" end-indent="0mm">
13616
+ <xsl:if test="normalize-space($writing-mode) != ''">
13617
+ <xsl:attribute name="writing-mode"><xsl:value-of select="$writing-mode"/></xsl:attribute>
13618
+ <xsl:attribute name="reference-orientation">90</xsl:attribute>
13619
+ </xsl:if>
13620
+ <xsl:variable name="char" select="substring($str,1,1)"/>
13621
+ <xsl:if test="normalize-space(java:matches(java:java.lang.String.new($char), concat('(', $regex_ja_spec, '{1,})'))) = 'true'">
13622
+ <xsl:attribute name="reference-orientation">0</xsl:attribute>
13623
+ </xsl:if>
13603
13624
  <fo:block-container width="1em">
13604
- <fo:block line-height="1em"><xsl:value-of select="substring($str,1,1)"/></fo:block>
13625
+ <fo:block line-height="1em"><xsl:value-of select="$char"/></fo:block>
13605
13626
  </fo:block-container>
13606
13627
  </fo:inline-container>
13607
13628
  <xsl:call-template name="insertVerticalChar">
13608
13629
  <xsl:with-param name="str" select="substring($str, 2)"/>
13630
+ <xsl:with-param name="writing-mode" select="$writing-mode"/>
13631
+ <xsl:with-param name="reference-orientation" select="$reference-orientation"/>
13609
13632
  </xsl:call-template>
13610
13633
  </xsl:if>
13611
13634
  </xsl:template>
@@ -32,7 +32,7 @@ module IsoDoc
32
32
  @anchors[clause["id"]] =
33
33
  { label: num, level: level, xref: num }
34
34
  # subclauses are not prefixed with "Clause"
35
- i = Counter.new(0, prefix: "#{num}.")
35
+ i = Counter.new(0, prefix: num)
36
36
  clause.xpath(ns("./clause | ./terms | ./term | ./definitions | " \
37
37
  "./references")).each do |c|
38
38
  section_names1(c, i.increment(c).print, level + 1)
@@ -45,7 +45,7 @@ module IsoDoc
45
45
  clause.at(ns("./clause")) and
46
46
  @anchors[clause["id"]] = { label: "0", level: 1, type: "clause",
47
47
  xref: clause.at(ns("./title"))&.text }
48
- i = Counter.new(0, prefix: "0.")
48
+ i = Counter.new(0, prefix: "0")
49
49
  clause.xpath(ns("./clause")).each do |c|
50
50
  section_names1(c, i.increment(c).print, 2)
51
51
  end
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module Ribose
3
- VERSION = "2.5.4".freeze
3
+ VERSION = "2.5.5".freeze
4
4
  end
5
5
  end
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
4
+ version: 2.5.5
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-10-14 00:00:00.000000000 Z
11
+ date: 2024-10-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: metanorma-generic