metanorma-iso 2.1.5 → 2.1.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -84,27 +84,24 @@ module IsoDoc
84
84
  end
85
85
 
86
86
  def authority_hdr_cleanup(docxml)
87
- docxml&.xpath("//div[@class = 'boilerplate-license']")&.each do |d|
88
- d.xpath(".//h1").each do |p|
89
- p.name = "p"
90
- p["class"] = "zzWarningHdr"
87
+ { "boilerplate-license": "zzWarningHdr",
88
+ "boilerplate-copyright": "zzCopyrightHdr" }.each do |k, v|
89
+ docxml.xpath("//div[@class = '#{k}']").each do |d|
90
+ d.xpath(".//h1").each do |p|
91
+ p.name = "p"
92
+ p["class"] = v
93
+ end
94
+ end
91
95
  end
92
- end
93
- docxml&.xpath("//div[@class = 'boilerplate-copyright']")&.each do |d|
94
- d.xpath(".//h1").each do |p|
95
- p.name = "p"
96
- p["class"] = "zzCopyrightHdr"
97
- end
98
- end
99
96
  end
100
97
 
101
98
  def authority_cleanup(docxml)
102
99
  insert = docxml.at("//div[@id = 'boilerplate-license-destination']")
103
- auth = docxml&.at("//div[@class = 'boilerplate-license']")&.remove
100
+ auth = docxml.at("//div[@class = 'boilerplate-license']")&.remove
104
101
  auth&.xpath(".//p[not(@class)]")&.each { |p| p["class"] = "zzWarning" }
105
102
  auth and insert and insert.children = auth
106
103
  insert = docxml.at("//div[@id = 'boilerplate-copyright-destination']")
107
- auth = docxml&.at("//div[@class = 'boilerplate-copyright']")&.remove
104
+ auth = docxml.at("//div[@class = 'boilerplate-copyright']")&.remove
108
105
  auth&.xpath(".//p[not(@class)]")&.each do |p|
109
106
  p["class"] = "zzCopyright"
110
107
  end
@@ -98,7 +98,7 @@ module IsoDoc
98
98
  @meta.get[:doctitlemain] && @meta.get[:doctitlepart] and p << " &#x2014; "
99
99
  if @meta.get[:doctitlepart]
100
100
  b = @meta.get[:doctitlepartlabel] and
101
- p << "<span style='font-weight:normal'>#{b}</span> "
101
+ p << "<span style='font-weight:normal'>#{b}:</span> "
102
102
  p << " #{@meta.get[:doctitlepart]}"
103
103
  end
104
104
  @meta.get[:doctitleamdlabel] || @meta.get[:doctitleamd] ||
@@ -19,7 +19,7 @@ l’adresse ci-après ou au comité membre de l’ISO dans le pays du demandeur.
19
19
  ISO copyright office<br/>
20
20
  CP 401 &#x2022; Ch. de Blandonnet 8<br/>
21
21
  CH-1214 Vernier, Geneva<br/>
22
- Tél.&#xa0;&#xa0;+ 41 22 749 01 11<br/>
22
+ Tél: +41 22 749 01 11<br/>
23
23
  Email: copyright@iso.org<br/>
24
24
  Website: www.iso.org
25
25
  </p>
@@ -14,7 +14,7 @@
14
14
  Бюро ISO по охране авторских прав<br/>
15
15
  CP 401 &#x2022; Ch. de Blandonnet 8<br/>
16
16
  CH-1214 Vernier, Geneva<br/>
17
- Тел.&#xa0;&#xa0;+ 41 22 749 01 11<br/>
17
+ Тел: +41 22 749 01 11<br/>
18
18
  Электронная почта: copyright@iso.org<br/>
19
19
  Сайт: www.iso.org
20
20
  </p>
@@ -20,7 +20,7 @@ at the address below or ISO's member body in the country of the requester.
20
20
  ISO copyright office<br/>
21
21
  CP 401 &#x2022; Ch. de Blandonnet 8<br/>
22
22
  CH-1214 Vernier, Geneva<br/>
23
- Phone:&#xa0;&#xa0;+ 41 22 749 01 11<br/>
23
+ Phone: +41 22 749 01 11<br/>
24
24
  Email: copyright@iso.org<br/>
25
25
  Website: www.iso.org
26
26
  </p>
@@ -5,6 +5,34 @@ require "json"
5
5
  require "pathname"
6
6
  require "open-uri"
7
7
  require "twitter_cldr"
8
+ require "pubid-iso"
9
+
10
+ # @param stage [String] stage, eg. "WD", "CD", "DIS"
11
+ # @param urn_stage [Float] numeric stage for URN rendering
12
+ # @param iteration [Integer] document iteration, eg. "1", "2", "3"
13
+ # @param joint_document [Identifier] joint document
14
+ # @param supplement [Supplement] supplement
15
+ # @param tctype [String] Technical Committee type, eg. "TC", "JTC"
16
+ # @param sctype [String] TC subsommittee, eg. "SC"
17
+ # @param wgtype [String] TC working group type, eg. "AG", "AHG"
18
+ # @param tcnumber [Integer] Technical Committee number, eg. "1", "2"
19
+ # @param scnumber [Integer] Subsommittee number, eg. "1", "2"
20
+ # @param wgnumber [Integer] Working group number, eg. "1", "2"
21
+ # @param dir [Boolean] Directives document
22
+ # @param dirtype [String] Directives document type, eg. "JTC"
23
+ # @see Supplement
24
+ # @see Identifier
25
+ # @see Pubid::Core::Identifier
26
+ # @see Parser
27
+ #
28
+ =begin
29
+ def initialize(number: nil, stage: nil, iteration: nil, supplement: nil,
30
+ joint_document: nil, urn_stage: nil,
31
+ tctype: nil, sctype: nil, wgtype: nil, tcnumber: nil,
32
+ scnumber: nil, wgnumber:nil,
33
+ dir: nil, dirtype: nil, **opts)
34
+ super(**opts.merge(number: number))
35
+ =end
8
36
 
9
37
  module Metanorma
10
38
  module ISO
@@ -1285,7 +1285,12 @@
1285
1285
  </define>
1286
1286
  <define name="span">
1287
1287
  <element name="span">
1288
- <attribute name="class"/>
1288
+ <optional>
1289
+ <attribute name="class"/>
1290
+ </optional>
1291
+ <optional>
1292
+ <attribute name="style"/>
1293
+ </optional>
1289
1294
  <oneOrMore>
1290
1295
  <ref name="TextElement"/>
1291
1296
  </oneOrMore>
@@ -108,7 +108,7 @@
108
108
  </element>
109
109
  </define>
110
110
  <define name="label">
111
- <element name="label">
111
+ <element name="identifier">
112
112
  <oneOrMore>
113
113
  <ref name="TextElement"/>
114
114
  </oneOrMore>
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module ISO
3
- VERSION = "2.1.5".freeze
3
+ VERSION = "2.1.6".freeze
4
4
  end
5
5
  end
@@ -29,11 +29,12 @@ Gem::Specification.new do |spec|
29
29
  spec.test_files = `git ls-files -- {spec}/*`.split("\n")
30
30
  spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0")
31
31
 
32
- spec.add_dependency "metanorma-standoc", "~> 2.1.0"
32
+ spec.add_dependency "metanorma-standoc", "~> 2.2.0"
33
33
  spec.add_dependency "mnconvert", "~> 1.14"
34
34
  spec.add_dependency "ruby-jing"
35
35
  spec.add_dependency "tokenizer", "~> 0.3.0"
36
36
  spec.add_dependency "twitter_cldr"
37
+ spec.add_dependency "pubid-iso"
37
38
 
38
39
  spec.add_development_dependency "debug"
39
40
  spec.add_development_dependency "equivalent-xml", "~> 0.6"
@@ -844,11 +844,9 @@ RSpec.describe IsoDoc do
844
844
  <br/>
845
845
  CH-1214 Vernier, Geneva, Switzerland
846
846
  <br/>
847
- Tel. + 41 22 749 01 11
847
+ Phone: +41 22 749 01 11
848
848
  <br/>
849
- Fax + 41 22 749 09 47
850
- <br/>
851
- copyright@iso.org
849
+ Email: copyright@iso.org
852
850
  <br/>
853
851
  www.iso.org</p>
854
852
  </clause>
@@ -891,11 +889,9 @@ RSpec.describe IsoDoc do
891
889
  <br/>
892
890
  CH-1214 Vernier, Geneva, Switzerland
893
891
  <br/>
894
- Tel. + 41 22 749 01 11
895
- <br/>
896
- Fax + 41 22 749 09 47
892
+ Phone: +41 22 749 01 11
897
893
  <br/>
898
- copyright@iso.org
894
+ Email: copyright@iso.org
899
895
  <br/>
900
896
  www.iso.org</p>
901
897
  </clause>
@@ -955,13 +951,10 @@ RSpec.describe IsoDoc do
955
951
  CH-1214 Vernier, Geneva, Switzerland
956
952
 
957
953
  <br/>
958
- Tel. + 41 22 749 01 11
959
-
960
- <br/>
961
- Fax + 41 22 749 09 47
954
+ Phone: +41 22 749 01 11
962
955
 
963
956
  <br/>
964
- copyright@iso.org
957
+ Email: copyright@iso.org
965
958
 
966
959
  <br/>
967
960
  www.iso.org#{' '}</p>
@@ -1728,7 +1728,7 @@ RSpec.describe IsoDoc do
1728
1728
  <div class='WordSection3'>
1729
1729
  <p class='zzSTDTitle'>
1730
1730
  Date and time — Representations for information interchange —
1731
- <span style='font-weight:normal'>Part 1</span>
1731
+ <span style='font-weight:normal'>Part 1:</span>
1732
1732
  Basic rules
1733
1733
  </p>
1734
1734
  <div>
@@ -1799,7 +1799,7 @@ RSpec.describe IsoDoc do
1799
1799
  <div class='WordSection3'>
1800
1800
  <p class='zzSTDTitle'>
1801
1801
  Date and time — Representations for information interchange —
1802
- <span style='font-weight:normal'>Part 1</span>
1802
+ <span style='font-weight:normal'>Part 1:</span>
1803
1803
  Basic rules
1804
1804
  <span style='font-weight:normal'> AMENDMENT 1: Technical corrections</span>
1805
1805
  </p>
@@ -1842,11 +1842,9 @@ RSpec.describe IsoDoc do
1842
1842
  <br/>
1843
1843
  CH-1214 Vernier, Geneva, Switzerland
1844
1844
  <br/>
1845
- Tel. + 41 22 749 01 11
1845
+ Phone: +41 22 749 01 11
1846
1846
  <br/>
1847
- Fax + 41 22 749 09 47
1848
- <br/>
1849
- copyright@iso.org
1847
+ Email: copyright@iso.org
1850
1848
  <br/>
1851
1849
  www.iso.org</p>
1852
1850
  </clause>
@@ -1896,9 +1894,8 @@ RSpec.describe IsoDoc do
1896
1894
  </p>
1897
1895
  <p class='zzCopyright'> Ch. de Blandonnet 8 ?~@? CP 401 </p>
1898
1896
  <p class='zzCopyright'> CH-1214 Vernier, Geneva, Switzerland </p>
1899
- <p class='zzCopyright'> Tel. + 41 22 749 01 11 </p>
1900
- <p class='zzCopyright'> Fax + 41 22 749 09 47 </p>
1901
- <p class='zzCopyright'> copyright@iso.org </p>
1897
+ <p class='zzCopyright'> Phone: +41 22 749 01 11 </p>
1898
+ <p class='zzCopyright'> Email: copyright@iso.org </p>
1902
1899
  <p class='zzCopyright'> www.iso.org</p>
1903
1900
  </div>
1904
1901
  </div>
@@ -1935,9 +1932,8 @@ RSpec.describe IsoDoc do
1935
1932
  </p>
1936
1933
  <p class='zzCopyright' style='text-indent:20.15pt;'> Ch. de Blandonnet 8 ?~@? CP 401 </p>
1937
1934
  <p class='zzCopyright' style='text-indent:20.15pt;'> CH-1214 Vernier, Geneva, Switzerland </p>
1938
- <p class='zzCopyright' style='text-indent:20.15pt;'> Tel. + 41 22 749 01 11 </p>
1939
- <p class='zzCopyright' style='text-indent:20.15pt;'> Fax + 41 22 749 09 47 </p>
1940
- <p class='zzCopyright' style='text-indent:20.15pt;'> copyright@iso.org </p>
1935
+ <p class='zzCopyright' style='text-indent:20.15pt;'> Phone: +41 22 749 01 11 </p>
1936
+ <p class='zzCopyright' style='text-indent:20.15pt;'> Email: copyright@iso.org </p>
1941
1937
  <p class='zzCopyright' style='text-indent:20.15pt;'> www.iso.org</p>
1942
1938
  </div>
1943
1939
  </div>
@@ -2045,7 +2041,7 @@ RSpec.describe IsoDoc do
2045
2041
  <a name='ISO712' id='ISO712'/>
2046
2042
  [1]
2047
2043
  <span style='mso-tab-count:1'>  </span>
2048
- ISO/IEC 712-3:2022, ALUFFI, Paolo, ed. (2022).
2044
+ ISO/IEC 712-3:2022, ALUFFI, Paolo, ed. (2022).
2049
2045
  <i>
2050
2046
  Facets of Algebraic Geometry: A Collection in Honor of William Fulton's
2051
2047
  80th Birthday
@@ -1008,9 +1008,6 @@ RSpec.describe Metanorma::ISO do
1008
1008
  <title type='title-intro' format='text/plain' language='en' script='Latn'>Rubber latex</title>
1009
1009
  <title type='title-main' format='text/plain' language='en' script='Latn'>Sampling</title>
1010
1010
  <title type='main' format='text/plain' language='en' script='Latn'>Rubber latex&#8201;&#8212;&#8201;Sampling</title>
1011
- <title type='title-intro' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc</title>
1012
- <title type='title-main' format='text/plain' language='fr' script='Latn'>&#201;chantillonnage</title>
1013
- <title type='main' format='text/plain' language='fr' script='Latn'>Latex de caoutchouc&#8201;&#8212;&#8201;&#201;chantillonnage</title>
1014
1011
  <uri type='src'>https://www.iso.org/standard/23281.html</uri>
1015
1012
  <uri type='obp'>https://www.iso.org/obp/ui/#!iso:std:23281:en</uri>
1016
1013
  <uri type='rss'>https://www.iso.org/contents/data/standard/02/32/23281.detail.rss</uri>
@@ -1028,7 +1025,6 @@ RSpec.describe Metanorma::ISO do
1028
1025
  </contributor>
1029
1026
  <edition>3</edition>
1030
1027
  <language>en</language>
1031
- <language>fr</language>
1032
1028
  <script>Latn</script>
1033
1029
  <abstract format='text/plain' language='en' script='Latn'>
1034
1030
  This International Standard specifies procedures for sampling natural
@@ -1036,16 +1032,6 @@ RSpec.describe Metanorma::ISO do
1036
1032
  artificial latices. It is also suitable for sampling rubber latex
1037
1033
  contained in drums, tank cars or tanks. The procedures may also be
1038
1034
  used for sampling plastics dispersions.
1039
- </abstract>
1040
- <abstract format='text/plain' language='fr' script='Latn'>
1041
- La pr&#233;sente Norme internationale sp&#233;cifie des m&#233;thodes
1042
- d&#8217;&#233;chantillonnage pour des concentr&#233;s de latex de
1043
- caoutchouc naturel et pour &#233;chantillonner des latex de caoutchouc
1044
- synth&#233;tique et des latex artificiels. Elle s&#8217;applique
1045
- &#233;galement &#224; l&#8217;&#233;chantillonnage de latex de
1046
- caoutchouc contenus dans des f&#251;ts, citernes routi&#232;res ou de
1047
- stockage. Le mode op&#233;ratoire peut aussi &#234;tre utilis&#233;
1048
- pour l&#8217;&#233;chantillonnage de dispersions de plastiques.
1049
1035
  </abstract>
1050
1036
  <status>
1051
1037
  <stage>90</stage>
@@ -78,8 +78,7 @@ l&#8217;adresse ci-apr&#232;s ou au comit&#233; membre de l&#8217;ISO dans le pa
78
78
  ISO copyright office<br/>
79
79
  Ch. de Blandonnet 8 &#8226; CP 401<br/>
80
80
  CH-1214 Vernier, Geneva, Switzerland<br/>
81
- Tel.&#160;&#160;+ 41 22 749 01 11<br/>
82
- Fax&#160;&#160;+ 41 22 749 09 47<br/>
81
+ Phone: +41 22 749 01 11<br/>
83
82
  Email: copyright@iso.org<br/>
84
83
  Website: www.iso.org
85
84
  </p>