metanorma-bipm 1.2.5 → 2.0.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -256,6 +256,11 @@ module IsoDoc
256
256
  end
257
257
  elem.children = l10n("[#{@i18n.source} #{elem.children.to_xml.strip}]")
258
258
  end
259
+
260
+ def bibliography_bibitem_number_skip(bibitem)
261
+ super || @xrefs.klass.standard?(bibitem)
262
+ end
263
+
259
264
  include Init
260
265
  end
261
266
  end
File without changes
@@ -401,9 +401,9 @@
401
401
  <choice>
402
402
  <!-- iso191606 TODO -->
403
403
  <group>
404
- <oneOrMore>
404
+ <zeroOrMore>
405
405
  <ref name="street"/>
406
- </oneOrMore>
406
+ </zeroOrMore>
407
407
  <ref name="city"/>
408
408
  <optional>
409
409
  <ref name="state"/>
@@ -110,6 +110,7 @@
110
110
  <ref name="clause-subsection"/>
111
111
  <ref name="terms"/>
112
112
  <ref name="definitions"/>
113
+ <ref name="floating-title"/>
113
114
  </choice>
114
115
  </zeroOrMore>
115
116
  </group>
@@ -157,6 +158,7 @@
157
158
  <ref name="terms"/>
158
159
  <ref name="definitions"/>
159
160
  <ref name="references"/>
161
+ <ref name="floating-title"/>
160
162
  </choice>
161
163
  </zeroOrMore>
162
164
  </group>
@@ -1,9 +1,9 @@
1
- require "asciidoctor/standoc/converter"
2
- require "asciidoctor/generic/converter"
1
+ require "metanorma/standoc/converter"
2
+ require "metanorma/generic/converter"
3
3
 
4
- module Asciidoctor
4
+ module Metanorma
5
5
  module BIPM
6
- class Converter < Asciidoctor::Generic::Converter
6
+ class Converter < Metanorma::Generic::Converter
7
7
  register_for "bipm"
8
8
 
9
9
  def configuration
@@ -32,6 +32,56 @@
32
32
  <ref name="DocumentType"/>
33
33
  </element>
34
34
  </define>
35
+ <define name="index">
36
+ <element name="index">
37
+ <optional>
38
+ <attribute name="to">
39
+ <data type="IDREF"/>
40
+ </attribute>
41
+ </optional>
42
+ <element name="primary">
43
+ <oneOrMore>
44
+ <choice>
45
+ <ref name="PureTextElement"/>
46
+ <ref name="stem"/>
47
+ </choice>
48
+ </oneOrMore>
49
+ </element>
50
+ <optional>
51
+ <element name="secondary">
52
+ <oneOrMore>
53
+ <choice>
54
+ <ref name="PureTextElement"/>
55
+ <ref name="stem"/>
56
+ </choice>
57
+ </oneOrMore>
58
+ </element>
59
+ </optional>
60
+ <optional>
61
+ <element name="tertiary">
62
+ <oneOrMore>
63
+ <choice>
64
+ <ref name="PureTextElement"/>
65
+ <ref name="stem"/>
66
+ </choice>
67
+ </oneOrMore>
68
+ </element>
69
+ </optional>
70
+ </element>
71
+ </define>
72
+ <define name="bibitem">
73
+ <element name="bibitem">
74
+ <attribute name="id">
75
+ <data type="ID"/>
76
+ </attribute>
77
+ <optional>
78
+ <attribute name="hidden">
79
+ <data type="boolean"/>
80
+ </attribute>
81
+ </optional>
82
+ <ref name="BibliographicItem"/>
83
+ </element>
84
+ </define>
35
85
  <define name="section-title">
36
86
  <element name="title">
37
87
  <zeroOrMore>
@@ -690,6 +740,7 @@
690
740
  <ref name="terms"/>
691
741
  <ref name="term-clause"/>
692
742
  <ref name="definitions"/>
743
+ <ref name="floating-title"/>
693
744
  </choice>
694
745
  </oneOrMore>
695
746
  </element>
@@ -1013,6 +1064,26 @@
1013
1064
  </zeroOrMore>
1014
1065
  </element>
1015
1066
  </define>
1067
+ <define name="sub">
1068
+ <element name="sub">
1069
+ <zeroOrMore>
1070
+ <choice>
1071
+ <ref name="PureTextElement"/>
1072
+ <ref name="stem"/>
1073
+ </choice>
1074
+ </zeroOrMore>
1075
+ </element>
1076
+ </define>
1077
+ <define name="sup">
1078
+ <element name="sup">
1079
+ <zeroOrMore>
1080
+ <choice>
1081
+ <ref name="PureTextElement"/>
1082
+ <ref name="stem"/>
1083
+ </choice>
1084
+ </zeroOrMore>
1085
+ </element>
1086
+ </define>
1016
1087
  <define name="pagebreak">
1017
1088
  <element name="pagebreak">
1018
1089
  <optional>
@@ -1680,6 +1751,7 @@
1680
1751
  <ref name="clause-subsection"/>
1681
1752
  <ref name="terms"/>
1682
1753
  <ref name="definitions"/>
1754
+ <ref name="floating-title"/>
1683
1755
  </choice>
1684
1756
  </oneOrMore>
1685
1757
  </choice>
@@ -1722,6 +1794,7 @@
1722
1794
  <ref name="terms"/>
1723
1795
  <ref name="definitions"/>
1724
1796
  <ref name="references"/>
1797
+ <ref name="floating-title"/>
1725
1798
  </choice>
1726
1799
  </zeroOrMore>
1727
1800
  </group>
@@ -2200,7 +2273,18 @@
2200
2273
  <ref name="MultilingualRenderingType"/>
2201
2274
  </attribute>
2202
2275
  </optional>
2203
- <ref name="paragraph"/>
2276
+ <oneOrMore>
2277
+ <choice>
2278
+ <ref name="formula"/>
2279
+ <ref name="ul"/>
2280
+ <ref name="ol"/>
2281
+ <ref name="dl"/>
2282
+ <ref name="quote"/>
2283
+ <ref name="sourcecode"/>
2284
+ <ref name="paragraph"/>
2285
+ <ref name="figure"/>
2286
+ </choice>
2287
+ </oneOrMore>
2204
2288
  </element>
2205
2289
  </define>
2206
2290
  <define name="termsource">
@@ -2534,4 +2618,17 @@
2534
2618
  </oneOrMore>
2535
2619
  </element>
2536
2620
  </define>
2621
+ <define name="floating-title">
2622
+ <element name="floating-title">
2623
+ <attribute name="id">
2624
+ <data type="ID"/>
2625
+ </attribute>
2626
+ <attribute name="depth">
2627
+ <data type="int"/>
2628
+ </attribute>
2629
+ <zeroOrMore>
2630
+ <ref name="TextElement"/>
2631
+ </zeroOrMore>
2632
+ </element>
2633
+ </define>
2537
2634
  </grammar>
File without changes
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module BIPM
3
- VERSION = "1.2.5".freeze
3
+ VERSION = "2.0.2".freeze
4
4
  end
5
5
  end
@@ -1,6 +1,7 @@
1
1
  require "metanorma"
2
2
  require "metanorma-generic"
3
3
  require "metanorma/bipm/processor"
4
+ require "metanorma/bipm/converter"
4
5
 
5
6
  module Metanorma
6
7
  module BIPM
@@ -1,9 +1,9 @@
1
1
  require "metanorma"
2
2
  require "metanorma/bipm"
3
+ require "metanorma/bipm/version"
3
4
  require "isodoc/bipm"
4
5
 
5
6
  require "asciidoctor" unless defined? Asciidoctor::Converter
6
- require "asciidoctor/bipm"
7
7
 
8
8
  if defined? Metanorma
9
9
  require_relative "metanorma/bipm"
@@ -26,8 +26,8 @@ Gem::Specification.new do |spec|
26
26
  spec.require_paths = ["lib"]
27
27
  spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0")
28
28
 
29
- spec.add_dependency "metanorma-generic", "~> 1.11.0"
30
- spec.add_dependency "metanorma-iso", "~> 1.10.0"
29
+ spec.add_dependency "metanorma-generic", "~> 2.0.0"
30
+ spec.add_dependency "metanorma-iso", "~> 2.0.0"
31
31
 
32
32
  spec.add_development_dependency "debug"
33
33
  spec.add_development_dependency "equivalent-xml", "~> 0.6"
data/metanorma.yml CHANGED
@@ -14,14 +14,14 @@ logo_path: lib/isodoc/bipm/html/logo.png
14
14
  i18nyaml:
15
15
  en: lib/isodoc/bipm/i18n-en.yaml
16
16
  fr: lib/isodoc/bipm/i18n-fr.yaml
17
- validate_rng_file: lib/asciidoctor/bipm/bipm.rng
17
+ validate_rng_file: lib/metanorma/bipm/bipm.rng
18
18
  htmlcoverpage: lib/isodoc/bipm/html/html_bipm_titlepage.html
19
19
  htmlintropage: lib/isodoc/bipm/html/html_bipm_intro.html
20
20
  htmlstylesheet: lib/isodoc/bipm/html/htmlstyle.scss
21
21
  scripts: lib/isodoc/bipm/html/scripts.html
22
22
  boilerplate:
23
- en: lib/asciidoctor/bipm/boilerplate-en.xml
24
- fr: lib/asciidoctor/bipm/boilerplate-fr.xml
23
+ en: lib/metanorma/bipm/boilerplate-en.xml
24
+ fr: lib/metanorma/bipm/boilerplate-fr.xml
25
25
  published_stages:
26
26
  - in-force
27
27
  - retired
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: metanorma-bipm
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.5
4
+ version: 2.0.2
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-12-27 00:00:00.000000000 Z
11
+ date: 2022-01-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: metanorma-generic
@@ -16,28 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 1.11.0
19
+ version: 2.0.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 1.11.0
26
+ version: 2.0.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: metanorma-iso
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 1.10.0
33
+ version: 2.0.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 1.10.0
40
+ version: 2.0.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: debug
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -200,16 +200,6 @@ files:
200
200
  - bin/console
201
201
  - bin/rspec
202
202
  - bin/setup
203
- - lib/asciidoctor/bipm.rb
204
- - lib/asciidoctor/bipm/basicdoc.rng
205
- - lib/asciidoctor/bipm/biblio.rng
206
- - lib/asciidoctor/bipm/bipm.rng
207
- - lib/asciidoctor/bipm/boilerplate-en.xml
208
- - lib/asciidoctor/bipm/boilerplate-fr.xml
209
- - lib/asciidoctor/bipm/boilerplate-jcgm-en.xml
210
- - lib/asciidoctor/bipm/converter.rb
211
- - lib/asciidoctor/bipm/isodoc.rng
212
- - lib/asciidoctor/bipm/reqt.rng
213
203
  - lib/isodoc/bipm.rb
214
204
  - lib/isodoc/bipm/base_convert.rb
215
205
  - lib/isodoc/bipm/bipm.brochure.xsl
@@ -248,7 +238,16 @@ files:
248
238
  - lib/isodoc/bipm/xref.rb
249
239
  - lib/metanorma-bipm.rb
250
240
  - lib/metanorma/bipm.rb
241
+ - lib/metanorma/bipm/basicdoc.rng
242
+ - lib/metanorma/bipm/biblio.rng
243
+ - lib/metanorma/bipm/bipm.rng
244
+ - lib/metanorma/bipm/boilerplate-en.xml
245
+ - lib/metanorma/bipm/boilerplate-fr.xml
246
+ - lib/metanorma/bipm/boilerplate-jcgm-en.xml
247
+ - lib/metanorma/bipm/converter.rb
248
+ - lib/metanorma/bipm/isodoc.rng
251
249
  - lib/metanorma/bipm/processor.rb
250
+ - lib/metanorma/bipm/reqt.rng
252
251
  - lib/metanorma/bipm/version.rb
253
252
  - metanorma-bipm.gemspec
254
253
  - metanorma.yml
@@ -1,8 +0,0 @@
1
- require "metanorma/bipm/version"
2
- require_relative "bipm/converter"
3
-
4
- module Asciidoctor
5
- module BIPM
6
-
7
- end
8
- end