metanorma-iec 2.3.5 → 2.3.8

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: ccf4ed6f93f2b6c2d931a21570f9f7649a811edcbba0bd5075e6e3a8143497d9
4
- data.tar.gz: d0803421fffad506a4651df4e4bfc2ce717cb58591e13486f36d258a5d74746b
3
+ metadata.gz: 605384bfdb3b408af9009479f8f160b0350331658c2f408a7d78851eb577d576
4
+ data.tar.gz: fca4578c77a31a6a5baa86b821a35c3b0aa35f2c2967bdef20af3220584a4ba7
5
5
  SHA512:
6
- metadata.gz: 386c793873868c8fb7fc5f19ba6afa5e083661de49d58d6c54a79ac6369047d4fd008a16b2d522dea5a6f7bcbfc5bfdb588b73c8f42d70f457a740cc7375c49f
7
- data.tar.gz: ab4711f3c382153c0aa3cc901653e776f58a440daf4e5bbc6315a648dc8f0b3514c6b67dca63bcbd2f9f6bf08a3e4375b555d0b1785a00b717f4f9b9609409d8
6
+ metadata.gz: '012985f1e92f0a3629f08123049b903edc640233094f55ad449cdda33d3b8f9ed76a1d87589b8ed9e4f6ceddd55367ad337bd2fac71c15cd6178c3147d0c3f03'
7
+ data.tar.gz: 77ab9c5ebf5d7e252b7038471b6646c34541a9d3aaf1c660f554024765558094cb62dedd6226604a9bd9823790755e1fcbe5603d1af390ccd1820beb8dac8e16
data/Gemfile CHANGED
@@ -4,12 +4,6 @@ Encoding.default_internal = Encoding::UTF_8
4
4
  source "https://rubygems.org"
5
5
  git_source(:github) { |repo| "https://github.com/#{repo}" }
6
6
 
7
- group :development, :test do
8
- gem "rspec"
9
- end
10
-
11
- if File.exist? "Gemfile.devel"
12
- eval File.read("Gemfile.devel"), nil, "Gemfile.devel" # rubocop:disable Security/Eval
13
- end
14
-
15
7
  gemspec
8
+
9
+ eval_gemfile("Gemfile.devel") rescue nil
@@ -139,6 +139,14 @@ a.FootnoteRef, span.FootnoteRef {
139
139
  color: red;
140
140
  text-decoration: line-through; }
141
141
 
142
+ ruby {
143
+ ruby-position: over;
144
+ -webkit-ruby-position: before; }
145
+
146
+ ruby ruby {
147
+ ruby-position: under;
148
+ -webkit-ruby-position: after; }
149
+
142
150
  /* code highlighting with line numbers */
143
151
  table.rouge-line-table td.rouge-gutter {
144
152
  -moz-user-select: none;
@@ -1,19 +1,15 @@
1
1
  module IsoDoc
2
2
  module Iec
3
3
  class I18n < IsoDoc::Iso::I18n
4
+ def load_file(fname)
5
+ f = File.join(File.dirname(__FILE__), fname)
6
+ File.exist?(f) ? YAML.load_file(f) : {}
7
+ end
8
+
4
9
  def load_yaml1(lang, script)
5
- y = if lang == "en"
6
- YAML.load_file(File.join(File.dirname(__FILE__), "i18n-en.yaml"))
7
- elsif lang == "fr"
8
- YAML.load_file(File.join(File.dirname(__FILE__), "i18n-fr.yaml"))
9
- elsif lang == "zh" && script == "Hans"
10
- YAML.load_file(File.join(File.dirname(__FILE__), "i18n-zh-Hans.yaml"))
11
- else
12
- YAML.load_file(File.join(File.dirname(__FILE__), "i18n-en.yaml"))
13
- end
14
- super.deep_merge(y)
10
+ y = load_file("i18n-#{yaml_lang(lang, script)}.yaml")
11
+ y.empty? ? load_file("i18n-en.yaml").merge(super) : super.deep_merge(y)
15
12
  end
16
13
  end
17
14
  end
18
15
  end
19
-
@@ -11513,6 +11513,7 @@
11513
11513
  $namespace = 'mpfd' or $namespace = 'ogc' or $namespace = 'ogc-white-paper' -->
11514
11514
  <!-- Example: [1] ISO 9:1995, Information and documentation – Transliteration of Cyrillic characters into Latin characters – Slavic and non-Slavic languages -->
11515
11515
  <fo:list-block id="{@id}" xsl:use-attribute-sets="bibitem-non-normative-list-style">
11516
+
11516
11517
  <fo:list-item>
11517
11518
  <fo:list-item-label end-indent="label-end()">
11518
11519
  <fo:block role="SKIP">
@@ -11716,10 +11717,10 @@
11716
11717
 
11717
11718
  <xsl:variable name="toc_level">
11718
11719
  <!-- https://www.metanorma.org/author/ref/document-attributes/ -->
11719
- <xsl:variable name="htmltoclevels" select="normalize-space(//*[local-name() = 'metanorma-extension']/*[local-name() = 'presentation-metadata'][*[local-name() = 'name']/text() = 'HTML TOC Heading Levels']/*[local-name() = 'value'])"/> <!-- :htmltoclevels Number of table of contents levels to render in HTML/PDF output; used to override :toclevels:-->
11720
+ <xsl:variable name="pdftoclevels" select="normalize-space(//*[local-name() = 'metanorma-extension']/*[local-name() = 'presentation-metadata'][*[local-name() = 'name']/text() = 'PDF TOC Heading Levels']/*[local-name() = 'value'])"/> <!-- :toclevels-pdf Number of table of contents levels to render in PDF output; used to override :toclevels:-->
11720
11721
  <xsl:variable name="toclevels" select="normalize-space(//*[local-name() = 'metanorma-extension']/*[local-name() = 'presentation-metadata'][*[local-name() = 'name']/text() = 'TOC Heading Levels']/*[local-name() = 'value'])"/> <!-- Number of table of contents levels to render -->
11721
11722
  <xsl:choose>
11722
- <xsl:when test="$htmltoclevels != ''"><xsl:value-of select="number($htmltoclevels)"/></xsl:when> <!-- if there is value in xml -->
11723
+ <xsl:when test="$pdftoclevels != ''"><xsl:value-of select="number($pdftoclevels)"/></xsl:when> <!-- if there is value in xml -->
11723
11724
  <xsl:when test="$toclevels != ''"><xsl:value-of select="number($toclevels)"/></xsl:when> <!-- if there is value in xml -->
11724
11725
  <xsl:otherwise><!-- default value -->
11725
11726
  3
@@ -715,27 +715,36 @@
715
715
  </define>
716
716
  <define name="ruby">
717
717
  <element name="ruby">
718
- <zeroOrMore>
719
- <choice>
720
- <ref name="PureTextElement"/>
721
- <ref name="rp"/>
722
- <ref name="rt"/>
723
- </choice>
724
- </zeroOrMore>
718
+ <choice>
719
+ <ref name="ruby_pronunciation"/>
720
+ <ref name="ruby_annotation"/>
721
+ </choice>
722
+ <choice>
723
+ <text/>
724
+ <ref name="ruby"/>
725
+ </choice>
725
726
  </element>
726
727
  </define>
727
- <define name="rp">
728
- <element name="rp">
729
- <zeroOrMore>
730
- <ref name="PureTextElement"/>
731
- </zeroOrMore>
728
+ <define name="ruby_pronunciation">
729
+ <element name="pronunciation">
730
+ <attribute name="value"/>
731
+ <optional>
732
+ <attribute name="script"/>
733
+ </optional>
734
+ <optional>
735
+ <attribute name="lang"/>
736
+ </optional>
732
737
  </element>
733
738
  </define>
734
- <define name="rt">
735
- <element name="rt">
736
- <zeroOrMore>
737
- <ref name="PureTextElement"/>
738
- </zeroOrMore>
739
+ <define name="ruby_annotation">
740
+ <element name="annotation">
741
+ <attribute name="value"/>
742
+ <optional>
743
+ <attribute name="script"/>
744
+ </optional>
745
+ <optional>
746
+ <attribute name="lang"/>
747
+ </optional>
739
748
  </element>
740
749
  </define>
741
750
  <define name="br">
@@ -374,6 +374,16 @@
374
374
  <ref name="image"/>
375
375
  </element>
376
376
  </define>
377
+ <define name="depiction">
378
+ <element name="depiction">
379
+ <optional>
380
+ <attribute name="scope"/>
381
+ </optional>
382
+ <zeroOrMore>
383
+ <ref name="image"/>
384
+ </zeroOrMore>
385
+ </element>
386
+ </define>
377
387
  <define name="NameWithVariants">
378
388
  <element name="primary">
379
389
  <ref name="LocalizedString"/>
@@ -760,6 +770,9 @@
760
770
  <optional>
761
771
  <ref name="validity"/>
762
772
  </optional>
773
+ <optional>
774
+ <ref name="depiction"/>
775
+ </optional>
763
776
  </define>
764
777
  <define name="ReducedBibliographicItem">
765
778
  <optional>
@@ -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.2.8 -->
20
+ <!-- VERSION v1.2.9 -->
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">
@@ -1958,6 +1958,16 @@
1958
1958
  <data type="boolean"/>
1959
1959
  </attribute>
1960
1960
  </optional>
1961
+ <optional>
1962
+ <attribute name="type">
1963
+ <choice>
1964
+ <value>letter</value>
1965
+ <value>symbol</value>
1966
+ <value>formula</value>
1967
+ <value>equation</value>
1968
+ </choice>
1969
+ </attribute>
1970
+ </optional>
1961
1971
  <element name="name">
1962
1972
  <oneOrMore>
1963
1973
  <choice>
@@ -1,6 +1,6 @@
1
1
  module Metanorma
2
2
  module Iec
3
- VERSION = "2.3.5".freeze
3
+ VERSION = "2.3.8".freeze
4
4
  end
5
5
  end
6
6
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-iec
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.5
4
+ version: 2.3.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-11-27 00:00:00.000000000 Z
11
+ date: 2023-12-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: metanorma-iso