metanorma-iso 1.3.22 → 1.3.27
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/macos.yml +8 -7
- data/.github/workflows/ubuntu.yml +8 -7
- data/.github/workflows/windows.yml +8 -8
- data/Gemfile +2 -0
- data/lib/asciidoctor/iso/base.rb +22 -0
- data/lib/asciidoctor/iso/biblio.rng +89 -32
- data/lib/asciidoctor/iso/cleanup.rb +20 -3
- data/lib/asciidoctor/iso/front.rb +16 -107
- data/lib/asciidoctor/iso/front_id.rb +196 -0
- data/lib/asciidoctor/iso/isodoc.rng +475 -2
- data/lib/asciidoctor/iso/isostandard-amd.rng +98 -0
- data/lib/asciidoctor/iso/isostandard.rng +12 -1
- data/lib/asciidoctor/iso/macros.rb +21 -0
- data/lib/asciidoctor/iso/reqt.rng +23 -0
- data/lib/asciidoctor/iso/section.rb +18 -32
- data/lib/asciidoctor/iso/term_lookup_cleanup.rb +87 -0
- data/lib/asciidoctor/iso/validate.rb +41 -25
- data/lib/asciidoctor/iso/validate_requirements.rb +1 -1
- data/lib/asciidoctor/iso/validate_section.rb +2 -2
- data/lib/asciidoctor/iso/validate_style.rb +6 -5
- data/lib/asciidoctor/iso/validate_title.rb +1 -1
- data/lib/isodoc/iso/base_convert.rb +77 -107
- data/lib/isodoc/iso/html/header.html +10 -6
- data/lib/isodoc/iso/html/html_iso_titlepage.html +27 -18
- data/lib/isodoc/iso/html/isodoc.scss +53 -28
- data/lib/isodoc/iso/html/scripts.html +23 -21
- data/lib/isodoc/iso/html/style-human.scss +23 -0
- data/lib/isodoc/iso/html/style-iso.scss +18 -0
- data/lib/isodoc/iso/html/word_iso_intro.html +4 -0
- data/lib/isodoc/iso/html/word_iso_titlepage.html +23 -2
- data/lib/isodoc/iso/html/wordstyle.scss +80 -39
- data/lib/isodoc/iso/html_convert.rb +7 -9
- data/lib/isodoc/iso/iso.amendment.xsl +4597 -0
- data/lib/isodoc/iso/iso.international-standard.xsl +4597 -0
- data/lib/isodoc/iso/metadata.rb +71 -23
- data/lib/isodoc/iso/pdf_convert.rb +39 -0
- data/lib/isodoc/iso/sections.rb +66 -0
- data/lib/isodoc/iso/sts_convert.rb +29 -0
- data/lib/isodoc/iso/xref.rb +105 -0
- data/lib/metanorma-iso.rb +2 -0
- data/lib/metanorma/iso/processor.rb +16 -1
- data/lib/metanorma/iso/version.rb +1 -1
- data/metanorma-iso.gemspec +4 -1
- data/spec/asciidoctor-iso/amd_spec.rb +726 -0
- data/spec/asciidoctor-iso/base_spec.rb +38 -21
- data/spec/asciidoctor-iso/blocks_spec.rb +6 -6
- data/spec/asciidoctor-iso/cleanup_spec.rb +195 -174
- data/spec/asciidoctor-iso/inline_spec.rb +2 -1
- data/spec/asciidoctor-iso/macros_spec.rb +289 -0
- data/spec/asciidoctor-iso/refs_spec.rb +8 -5
- data/spec/asciidoctor-iso/section_spec.rb +8 -8
- data/spec/assets/iso.xml +64 -1
- data/spec/isodoc/amd_spec.rb +652 -0
- data/spec/isodoc/blocks_spec.rb +112 -27
- data/spec/isodoc/i18n_spec.rb +12 -20
- data/spec/isodoc/inline_spec.rb +4 -4
- data/spec/isodoc/iso_spec.rb +1 -1
- data/spec/isodoc/metadata_spec.rb +92 -4
- data/spec/isodoc/postproc_spec.rb +21 -120
- data/spec/isodoc/ref_spec.rb +9 -9
- data/spec/isodoc/section_spec.rb +36 -13
- data/spec/isodoc/table_spec.rb +30 -30
- data/spec/isodoc/terms_spec.rb +6 -6
- data/spec/isodoc/xref_spec.rb +43 -37
- data/spec/metanorma/processor_spec.rb +2 -2
- data/spec/spec_helper.rb +11 -0
- metadata +58 -5
- data/asciidoctor-iso.gemspec.old +0 -50
data/spec/isodoc/blocks_spec.rb
CHANGED
@@ -8,12 +8,10 @@ RSpec.describe IsoDoc do
|
|
8
8
|
<formula id="_be9158af-7e93-4ee2-90c5-26d31c181934" unnumbered="true">
|
9
9
|
<stem type="AsciiMath">r = 1 %</stem>
|
10
10
|
<dl id="_e4fe94fe-1cde-49d9-b1ad-743293b7e21d">
|
11
|
-
<dt>
|
12
|
-
|
13
|
-
</dt>
|
14
|
-
<dd>
|
15
|
-
<p id="_1b99995d-ff03-40f5-8f2e-ab9665a69b77">is the repeatability limit.</p>
|
16
|
-
</dd>
|
11
|
+
<dt> <stem type="AsciiMath">r</stem> </dt>
|
12
|
+
<dd> <p id="_1b99995d-ff03-40f5-8f2e-ab9665a69b77">is the repeatability limit.</p> </dd>
|
13
|
+
<dt> <stem type="AsciiMath">s_1</stem> </dt>
|
14
|
+
<dd> <p id="_1b99995d-ff03-40f5-8f2e-ab9665a69b77">is the other repeatability limit.</p> </dd>
|
17
15
|
</dl>
|
18
16
|
<note id="_83083c7a-6c85-43db-a9fa-4d8edd0c9fc0">
|
19
17
|
<p id="_511aaa98-4116-42af-8e5b-c87cdf5bfdc8">[durationUnits] is essentially a duration statement without the "P" prefix. "P" is unnecessary because between "G" and "U" duration is always expressed.</p>
|
@@ -26,29 +24,55 @@ RSpec.describe IsoDoc do
|
|
26
24
|
</iso-standard>
|
27
25
|
INPUT
|
28
26
|
#{HTML_HDR}
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
27
|
+
<br/>
|
28
|
+
<div>
|
29
|
+
<h1 class='ForewordTitle'>Foreword</h1>
|
30
|
+
<div id='_be9158af-7e93-4ee2-90c5-26d31c181934'><div class='formula'>
|
31
|
+
<p>
|
32
|
+
<span class='stem'>(#(r = 1 %)#)</span>
|
33
|
+
</p>
|
34
|
+
</div>
|
35
|
+
<p style='page-break-after:avoid;'>where</p>
|
36
|
+
<dl id='_e4fe94fe-1cde-49d9-b1ad-743293b7e21d' class='formula_dl'>
|
37
|
+
<dt>
|
38
|
+
<span class='stem'>(#(r)#)</span>
|
39
|
+
</dt>
|
40
|
+
<dd>
|
41
|
+
<p id='_1b99995d-ff03-40f5-8f2e-ab9665a69b77'>is the repeatability limit.</p>
|
42
|
+
</dd>
|
43
|
+
<dt>
|
44
|
+
<span class='stem'>(#(s_1)#)</span>
|
45
|
+
</dt>
|
46
|
+
<dd>
|
47
|
+
<p id='_1b99995d-ff03-40f5-8f2e-ab9665a69b77'>is the other repeatability limit.</p>
|
48
|
+
</dd>
|
49
|
+
</dl>
|
50
|
+
<div id='_83083c7a-6c85-43db-a9fa-4d8edd0c9fc0' class='Note'>
|
51
|
+
<p>
|
52
|
+
<span class='note_label'>NOTE</span>
|
53
|
+
  [durationUnits] is essentially a duration statement without
|
54
|
+
the "P" prefix. "P" is unnecessary because between "G" and "U"
|
55
|
+
duration is always expressed.
|
56
|
+
</p>
|
57
|
+
</div>
|
58
|
+
</div>
|
59
|
+
<div id='_be9158af-7e93-4ee2-90c5-26d31c181935'><div class='formula'>
|
60
|
+
<p>
|
61
|
+
<span class='stem'>(#(r = 1 %)#)</span>
|
62
|
+
  (1)
|
63
|
+
</p>
|
64
|
+
</div>
|
65
|
+
</div>
|
66
|
+
</div>
|
67
|
+
<p class='zzSTDTitle1'/>
|
68
|
+
</div>
|
69
|
+
</body>
|
70
|
+
</html>
|
47
71
|
OUTPUT
|
48
72
|
end
|
49
73
|
|
50
74
|
it "processes formulae (Word)" do
|
51
|
-
expect((IsoDoc::Iso::WordConvert.new({}).convert("test", <<~"INPUT", true).sub(%r{^.*<div>\s*<h1 class="ForewordTitle">}m, '<div><h1 class="ForewordTitle">').sub(%r{<p>\ </p>\s*</div>.*$}m, ""))).to be_equivalent_to xmlpp(<<~"OUTPUT")
|
75
|
+
expect(xmlpp(IsoDoc::Iso::WordConvert.new({}).convert("test", <<~"INPUT", true).sub(%r{^.*<div>\s*<h1 class="ForewordTitle">}m, '<div><h1 class="ForewordTitle">').sub(%r{<p>\ </p>\s*</div>.*$}m, ""))).to be_equivalent_to xmlpp(<<~"OUTPUT")
|
52
76
|
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
53
77
|
<preface><foreword>
|
54
78
|
<formula id="_be9158af-7e93-4ee2-90c5-26d31c181934" unnumbered="true">
|
@@ -60,6 +84,8 @@ RSpec.describe IsoDoc do
|
|
60
84
|
<dd>
|
61
85
|
<p id="_1b99995d-ff03-40f5-8f2e-ab9665a69b77">is the repeatability limit.</p>
|
62
86
|
</dd>
|
87
|
+
<dt> <stem type="AsciiMath">s_1</stem> </dt>
|
88
|
+
<dd> <p id="_1b99995d-ff03-40f5-8f2e-ab9665a69b77">is the other repeatability limit.</p> </dd>
|
63
89
|
</dl>
|
64
90
|
<note id="_83083c7a-6c85-43db-a9fa-4d8edd0c9fc0">
|
65
91
|
<p id="_511aaa98-4116-42af-8e5b-c87cdf5bfdc8">[durationUnits] is essentially a duration statement without the "P" prefix. "P" is unnecessary because between "G" and "U" duration is always expressed.</p>
|
@@ -73,7 +99,7 @@ RSpec.describe IsoDoc do
|
|
73
99
|
INPUT
|
74
100
|
<div>
|
75
101
|
<h1 class='ForewordTitle'>Foreword</h1>
|
76
|
-
<div id='_be9158af-7e93-4ee2-90c5-26d31c181934' class='formula'>
|
102
|
+
<div id='_be9158af-7e93-4ee2-90c5-26d31c181934'><div class='formula'>
|
77
103
|
<p>
|
78
104
|
<span class='stem'>(#(r = 1 %)#)</span>
|
79
105
|
</p>
|
@@ -90,6 +116,16 @@ RSpec.describe IsoDoc do
|
|
90
116
|
<p id='_1b99995d-ff03-40f5-8f2e-ab9665a69b77'>is the repeatability limit.</p>
|
91
117
|
</td>
|
92
118
|
</tr>
|
119
|
+
<tr>
|
120
|
+
<td valign='top' align='left'>
|
121
|
+
<p align='left' style='margin-left:0pt;text-align:left;'>
|
122
|
+
<span class='stem'>(#(s_1)#)</span>
|
123
|
+
</p>
|
124
|
+
</td>
|
125
|
+
<td valign='top'>
|
126
|
+
<p id='_1b99995d-ff03-40f5-8f2e-ab9665a69b77'>is the other repeatability limit.</p>
|
127
|
+
</td>
|
128
|
+
</tr>
|
93
129
|
</table>
|
94
130
|
<div id='_83083c7a-6c85-43db-a9fa-4d8edd0c9fc0' class='Note'>
|
95
131
|
<p class='Note'>
|
@@ -100,16 +136,65 @@ RSpec.describe IsoDoc do
|
|
100
136
|
always expressed.
|
101
137
|
</p>
|
102
138
|
</div>
|
103
|
-
|
139
|
+
</div>
|
140
|
+
<div id='_be9158af-7e93-4ee2-90c5-26d31c181935'><div class='formula'>
|
104
141
|
<p>
|
105
142
|
<span class='stem'>(#(r = 1 %)#)</span>
|
106
143
|
<span style='mso-tab-count:1'>  </span>
|
107
144
|
(1)
|
108
145
|
</p>
|
109
146
|
</div>
|
147
|
+
</div>
|
110
148
|
</div>
|
111
149
|
OUTPUT
|
112
150
|
end
|
113
151
|
|
152
|
+
it "processes formulae with single definition list entry" do
|
153
|
+
expect(xmlpp(IsoDoc::Iso::HtmlConvert.new({}).convert("test", <<~"INPUT", true))).to be_equivalent_to xmlpp(<<~"OUTPUT")
|
154
|
+
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
155
|
+
<preface><foreword>
|
156
|
+
<formula id="_be9158af-7e93-4ee2-90c5-26d31c181934" unnumbered="true">
|
157
|
+
<stem type="AsciiMath">r = 1 %</stem>
|
158
|
+
<dl id="_e4fe94fe-1cde-49d9-b1ad-743293b7e21d">
|
159
|
+
<dt>
|
160
|
+
<stem type="AsciiMath">r</stem>
|
161
|
+
</dt>
|
162
|
+
<dd>
|
163
|
+
<p id="_1b99995d-ff03-40f5-8f2e-ab9665a69b77">is the repeatability limit.</p>
|
164
|
+
</dd>
|
165
|
+
</dl>
|
166
|
+
<note id="_83083c7a-6c85-43db-a9fa-4d8edd0c9fc0">
|
167
|
+
<p id="_511aaa98-4116-42af-8e5b-c87cdf5bfdc8">[durationUnits] is essentially a duration statement without the "P" prefix. "P" is unnecessary because between "G" and "U" duration is always expressed.</p>
|
168
|
+
</note>
|
169
|
+
</formula>
|
170
|
+
<formula id="_be9158af-7e93-4ee2-90c5-26d31c181935">
|
171
|
+
<stem type="AsciiMath">r = 1 %</stem>
|
172
|
+
</formula>
|
173
|
+
</foreword></preface>
|
174
|
+
</iso-standard>
|
175
|
+
INPUT
|
176
|
+
#{HTML_HDR}
|
177
|
+
<br/>
|
178
|
+
<div>
|
179
|
+
<h1 class="ForewordTitle">Foreword</h1>
|
180
|
+
<div id="_be9158af-7e93-4ee2-90c5-26d31c181934"><div class="formula"><p><span class="stem">(#(r = 1 %)#)</span></p></div>
|
181
|
+
<span class='zzMoveToFollowing'>
|
182
|
+
where
|
183
|
+
<span class='stem'>(#(r)#)</span>
|
184
|
+
</span>
|
185
|
+
<p id='_1b99995d-ff03-40f5-8f2e-ab9665a69b77'>is the repeatability limit.</p>
|
186
|
+
|
187
|
+
<div id="_83083c7a-6c85-43db-a9fa-4d8edd0c9fc0" class="Note"><p><span class="note_label">NOTE</span>  [durationUnits] is essentially a duration statement without the "P" prefix. "P" is unnecessary because between "G" and "U" duration is always expressed.</p></div>
|
188
|
+
</div>
|
189
|
+
|
190
|
+
<div id="_be9158af-7e93-4ee2-90c5-26d31c181935"><div class="formula"><p><span class="stem">(#(r = 1 %)#)</span>  (1)</p></div></div>
|
191
|
+
</div>
|
192
|
+
<p class="zzSTDTitle1"/>
|
193
|
+
</div>
|
194
|
+
</body>
|
195
|
+
</html>
|
196
|
+
OUTPUT
|
197
|
+
end
|
198
|
+
|
114
199
|
|
115
200
|
end
|
data/spec/isodoc/i18n_spec.rb
CHANGED
@@ -15,16 +15,14 @@ RSpec.describe IsoDoc do
|
|
15
15
|
<introduction id="B" obligation="informative"><title>Introduction</title><clause id="C" inline-header="false" obligation="informative">
|
16
16
|
<title>Introduction Subsection</title>
|
17
17
|
</clause>
|
18
|
-
<patent-notice>
|
19
18
|
<p>This is patent boilerplate</p>
|
20
|
-
</patent-notice>
|
21
19
|
</introduction></preface><sections>
|
22
20
|
<clause id="D" obligation="normative">
|
23
21
|
<title>Scope</title>
|
24
22
|
<p id="E">Text</p>
|
25
23
|
</clause>
|
26
24
|
|
27
|
-
<clause id="H" obligation="normative"><title>Terms,
|
25
|
+
<clause id="H" obligation="normative"><title>Terms, definitions, symbols and abbreviated terms</title><terms id="I" obligation="normative">
|
28
26
|
<title>Normal Terms</title>
|
29
27
|
<term id="J">
|
30
28
|
<preferred>Term2</preferred>
|
@@ -61,11 +59,11 @@ RSpec.describe IsoDoc do
|
|
61
59
|
<appendix id="Q2" inline-header="false" obligation="normative">
|
62
60
|
<title>An Appendix</title>
|
63
61
|
</appendix>
|
64
|
-
</annex><bibliography><references id="R" obligation="informative">
|
62
|
+
</annex><bibliography><references id="R" obligation="informative" normative="true">
|
65
63
|
<title>Normative References</title>
|
66
64
|
</references><clause id="S" obligation="informative">
|
67
65
|
<title>Bibliography</title>
|
68
|
-
<references id="T" obligation="informative">
|
66
|
+
<references id="T" obligation="informative" normative="false">
|
69
67
|
<title>Bibliography Subsection</title>
|
70
68
|
</references>
|
71
69
|
</clause>
|
@@ -161,16 +159,14 @@ RSpec.describe IsoDoc do
|
|
161
159
|
<introduction id="B" obligation="informative"><title>Introduction</title><clause id="C" inline-header="false" obligation="informative">
|
162
160
|
<title>Introduction Subsection</title>
|
163
161
|
</clause>
|
164
|
-
<patent-notice>
|
165
162
|
<p>This is patent boilerplate</p>
|
166
|
-
</patent-notice>
|
167
163
|
</introduction></preface><sections>
|
168
164
|
<clause id="D" obligation="normative">
|
169
165
|
<title>Scope</title>
|
170
166
|
<p id="E">Text</p>
|
171
167
|
</clause>
|
172
168
|
|
173
|
-
<clause id="H" obligation="normative"><title>Terms,
|
169
|
+
<clause id="H" obligation="normative"><title>Terms, definitions, symbols and abbreviated terms</title><terms id="I" obligation="normative">
|
174
170
|
<title>Normal Terms</title>
|
175
171
|
<term id="J">
|
176
172
|
<preferred>Term2</preferred>
|
@@ -207,11 +203,11 @@ RSpec.describe IsoDoc do
|
|
207
203
|
<appendix id="Q2" inline-header="false" obligation="normative">
|
208
204
|
<title>An Appendix</title>
|
209
205
|
</appendix>
|
210
|
-
</annex><bibliography><references id="R" obligation="informative">
|
206
|
+
</annex><bibliography><references id="R" obligation="informative" normative="true">
|
211
207
|
<title>Normative References</title>
|
212
208
|
</references><clause id="S" obligation="informative">
|
213
209
|
<title>Bibliography</title>
|
214
|
-
<references id="T" obligation="informative">
|
210
|
+
<references id="T" obligation="informative" normative="false">
|
215
211
|
<title>Bibliography Subsection</title>
|
216
212
|
</references>
|
217
213
|
</clause>
|
@@ -307,16 +303,14 @@ RSpec.describe IsoDoc do
|
|
307
303
|
<introduction id="B" obligation="informative"><title>Introduction</title><clause id="C" inline-header="false" obligation="informative">
|
308
304
|
<title>Introduction Subsection</title>
|
309
305
|
</clause>
|
310
|
-
<patent-notice>
|
311
306
|
<p>This is patent boilerplate</p>
|
312
|
-
</patent-notice>
|
313
307
|
</introduction></preface><sections>
|
314
308
|
<clause id="D" obligation="normative">
|
315
309
|
<title>Scope</title>
|
316
310
|
<p id="E">Text</p>
|
317
311
|
</clause>
|
318
312
|
|
319
|
-
<clause id="H" obligation="normative"><title>Terms,
|
313
|
+
<clause id="H" obligation="normative"><title>Terms, definitions, symbols and abbreviated terms</title><terms id="I" obligation="normative">
|
320
314
|
<title>Normal Terms</title>
|
321
315
|
<term id="J">
|
322
316
|
<preferred>Term2</preferred>
|
@@ -353,11 +347,11 @@ RSpec.describe IsoDoc do
|
|
353
347
|
<appendix id="Q2" inline-header="false" obligation="normative">
|
354
348
|
<title>An Appendix</title>
|
355
349
|
</appendix>
|
356
|
-
</annex><bibliography><references id="R" obligation="informative">
|
350
|
+
</annex><bibliography><references id="R" obligation="informative" normative="true">
|
357
351
|
<title>Normative References</title>
|
358
352
|
</references><clause id="S" obligation="informative">
|
359
353
|
<title>Bibliography</title>
|
360
|
-
<references id="T" obligation="informative">
|
354
|
+
<references id="T" obligation="informative" normative="false">
|
361
355
|
<title>Bibliography Subsection</title>
|
362
356
|
</references>
|
363
357
|
</clause>
|
@@ -454,16 +448,14 @@ RSpec.describe IsoDoc do
|
|
454
448
|
<introduction id="B" obligation="informative"><title>Introduction</title><clause id="C" inline-header="false" obligation="informative">
|
455
449
|
<title>Introduction Subsection</title>
|
456
450
|
</clause>
|
457
|
-
<patent-notice>
|
458
451
|
<p>This is patent boilerplate</p>
|
459
|
-
</patent-notice>
|
460
452
|
</introduction></preface><sections>
|
461
453
|
<clause id="D" obligation="normative">
|
462
454
|
<title>Scope</title>
|
463
455
|
<p id="E"><eref type="inline" bibitemid="ISO712"><locality type="table"><referenceFrom>1</referenceFrom><referenceTo>1</referenceTo></locality></eref></p>
|
464
456
|
</clause>
|
465
457
|
|
466
|
-
<clause id="H" obligation="normative"><title>Terms,
|
458
|
+
<clause id="H" obligation="normative"><title>Terms, definitions, symbols and abbreviated terms</title><terms id="I" obligation="normative">
|
467
459
|
<title>Normal Terms</title>
|
468
460
|
<term id="J">
|
469
461
|
<preferred>Term2</preferred>
|
@@ -500,7 +492,7 @@ RSpec.describe IsoDoc do
|
|
500
492
|
<appendix id="Q2" inline-header="false" obligation="normative">
|
501
493
|
<title>An Appendix</title>
|
502
494
|
</appendix>
|
503
|
-
</annex><bibliography><references id="R" obligation="informative">
|
495
|
+
</annex><bibliography><references id="R" obligation="informative" normative="true">
|
504
496
|
<title>Normative References</title>
|
505
497
|
<bibitem id="ISO712" type="standard">
|
506
498
|
<title format="text/plain">Cereals and cereal products</title>
|
@@ -514,7 +506,7 @@ RSpec.describe IsoDoc do
|
|
514
506
|
</bibitem>
|
515
507
|
</references><clause id="S" obligation="informative">
|
516
508
|
<title>Bibliography</title>
|
517
|
-
<references id="T" obligation="informative">
|
509
|
+
<references id="T" obligation="informative" normative="false">
|
518
510
|
<title>Bibliography Subsection</title>
|
519
511
|
</references>
|
520
512
|
</clause>
|
data/spec/isodoc/inline_spec.rb
CHANGED
@@ -158,7 +158,7 @@ RSpec.describe IsoDoc do
|
|
158
158
|
<eref type="inline" bibitemid="ISO712" citeas="ISO 712">A</stem>
|
159
159
|
</p>
|
160
160
|
</foreword></preface>
|
161
|
-
<bibliography><references id="_normative_references" obligation="informative"><title>Normative References</title>
|
161
|
+
<bibliography><references id="_normative_references" obligation="informative" normative="true"><title>Normative References</title>
|
162
162
|
<bibitem id="ISO712" type="standard">
|
163
163
|
<title format="text/plain">Cereals and cereal products</title>
|
164
164
|
<docidentifier>ISO 712</docidentifier>
|
@@ -213,7 +213,7 @@ RSpec.describe IsoDoc do
|
|
213
213
|
<eref type="inline" bibitemid="ISO712" citeas="ISO 712">A</eref>
|
214
214
|
</p>
|
215
215
|
</foreword></preface>
|
216
|
-
<bibliography><references id="_normative_references" obligation="informative"><title>Normative References</title>
|
216
|
+
<bibliography><references id="_normative_references" obligation="informative" normative="true"><title>Normative References</title>
|
217
217
|
<bibitem id="ISO712" type="standard">
|
218
218
|
<title format="text/plain">Cereals and cereal products</title>
|
219
219
|
<docidentifier>ISO 712</docidentifier>
|
@@ -243,7 +243,7 @@ RSpec.describe IsoDoc do
|
|
243
243
|
<a href="#ISO712">ISO 712, Clause 1</a>
|
244
244
|
<a href="#ISO712">ISO 712, 1.5</a>
|
245
245
|
<a href="#ISO712">A</a>
|
246
|
-
<a href="#ISO712">ISO 712, </a>
|
246
|
+
<a href="#ISO712">ISO 712, Whole of text</a>
|
247
247
|
<a href="#ISO712">ISO 712, Prelude 7</a>
|
248
248
|
<a href="#ISO712">A</a>
|
249
249
|
</p>
|
@@ -251,7 +251,7 @@ RSpec.describe IsoDoc do
|
|
251
251
|
<p class="zzSTDTitle1"/>
|
252
252
|
<div>
|
253
253
|
<h1>1  Normative references</h1>
|
254
|
-
<p id="ISO712" class="NormRef">ISO 712, <i>
|
254
|
+
<p id="ISO712" class="NormRef">ISO 712, <i>Cereals and cereal products</i></p>
|
255
255
|
</div>
|
256
256
|
</div>
|
257
257
|
</body>
|
data/spec/isodoc/iso_spec.rb
CHANGED
@@ -96,7 +96,7 @@ RSpec.describe IsoDoc::Iso do
|
|
96
96
|
<eref bibitemid="ISO20483"/>
|
97
97
|
</p>
|
98
98
|
</foreword></preface>
|
99
|
-
<bibliography><references id="_normative_references" obligation="informative"><title>Normative References</title>
|
99
|
+
<bibliography><references id="_normative_references" obligation="informative" normative="true"><title>Normative References</title>
|
100
100
|
<bibitem type="international-standard" id="IEV">
|
101
101
|
<title format="text/plain" language="en" script="Latn">Electropedia:
|
102
102
|
The World's Online Electrotechnical Vocabulary</title>
|
@@ -16,7 +16,9 @@ RSpec.describe IsoDoc::Iso::Metadata do
|
|
16
16
|
<title type="title-intro" language="fr" format="text/plain">Céréales et légumineuses</title>
|
17
17
|
<title type="title-main" language="fr" format="text/plain">Spécification et méthodes d'essai</title>
|
18
18
|
<title type="title-part" language="fr" format="text/plain">Riz</title>
|
19
|
-
<docidentifier type="
|
19
|
+
<docidentifier type="ISO">ISO/PreCD3 17301-1</docidentifier>
|
20
|
+
<docidentifier type="iso-with-lang">ISO/PreCD3 17301-1 (E)</docidentifier>
|
21
|
+
<docidentifier type="iso-reference">ISO/PreCD3 17301-1:2000 (E)</docidentifier>
|
20
22
|
<docidentifier type="iso-tc">17301</docidentifier>
|
21
23
|
<docidentifier type="iso-tc">17302</docidentifier>
|
22
24
|
<docnumber>1730</docnumber>
|
@@ -58,6 +60,8 @@ RSpec.describe IsoDoc::Iso::Metadata do
|
|
58
60
|
</organization>
|
59
61
|
</owner>
|
60
62
|
</copyright>
|
63
|
+
<keyword>kw2</keyword>
|
64
|
+
<keyword>kw1</keyword>
|
61
65
|
<ext>
|
62
66
|
<doctype>international-standard</doctype>
|
63
67
|
<editorialgroup>
|
@@ -74,7 +78,51 @@ RSpec.describe IsoDoc::Iso::Metadata do
|
|
74
78
|
</bibdata>
|
75
79
|
</iso-standard>
|
76
80
|
INPUT
|
77
|
-
{:accesseddate=>"2012",
|
81
|
+
{:accesseddate=>"2012",
|
82
|
+
:activateddate=>"2013",
|
83
|
+
:agency=>"ISO",
|
84
|
+
:authors=>[],
|
85
|
+
:authors_affiliations=>{},
|
86
|
+
:createddate=>"2010–2011",
|
87
|
+
:docnumber=>"ISO/PreCD3 17301-1",
|
88
|
+
:docnumber_lang=>"ISO/PreCD3 17301-1 (E)",
|
89
|
+
:docnumber_reference=>"ISO/PreCD3 17301-1:2000 (E)",
|
90
|
+
:docnumeric=>"1730",
|
91
|
+
:docsubtitle=>"Céréales et légumineuses — Spécification et méthodes d'essai — Partie 1: Riz",
|
92
|
+
:docsubtitleintro=>"Céréales et légumineuses",
|
93
|
+
:docsubtitlemain=>"Spécification et méthodes d'essai",
|
94
|
+
:docsubtitlepart=>"Riz",
|
95
|
+
:docsubtitlepartlabel=>"Partie 1",
|
96
|
+
:doctitle=>"Cereals and pulses — Specifications and test methods — Part 1: Rice",
|
97
|
+
:doctitleintro=>"Cereals and pulses",
|
98
|
+
:doctitlemain=>"Specifications and test methods",
|
99
|
+
:doctitlepart=>"Rice",
|
100
|
+
:doctitlepartlabel=>"Part 1",
|
101
|
+
:doctype=>"International Standard",
|
102
|
+
:docyear=>"2016",
|
103
|
+
:draft=>"0.4",
|
104
|
+
:draftinfo=>" (draft 0.4, 2016-05-01)",
|
105
|
+
:edition=>"2",
|
106
|
+
:editorialgroup=>["TC 34", "SC 4", "WG 3"],
|
107
|
+
:ics=>nil,
|
108
|
+
:keywords=>["kw2", "kw1"],
|
109
|
+
:obsoleteddate=>"2014",
|
110
|
+
:obsoletes=>nil,
|
111
|
+
:obsoletes_part=>nil,
|
112
|
+
:publisheddate=>"2011",
|
113
|
+
:publisher=>"International Organization for Standardization",
|
114
|
+
:revdate=>"2016-05-01",
|
115
|
+
:revdate_monthyear=>"May 2016",
|
116
|
+
:sc=>"SC 4",
|
117
|
+
:secretariat=>"GB",
|
118
|
+
:stage=>"30",
|
119
|
+
:stage_int=>30,
|
120
|
+
:stageabbr=>"CD",
|
121
|
+
:statusabbr=>"PreCD3",
|
122
|
+
:tc=>"TC 34",
|
123
|
+
:tc_docnumber=>["17301", "17302"],
|
124
|
+
:unpublished=>true,
|
125
|
+
:wg=>"WG 3"}
|
78
126
|
OUTPUT
|
79
127
|
end
|
80
128
|
|
@@ -96,7 +144,9 @@ OUTPUT
|
|
96
144
|
<title type="title-main" language="fr" format="text/plain">Spécification et méthodes d'essai</title>
|
97
145
|
<title type="title-part" language="fr" format="text/plain">Riz</title>
|
98
146
|
</title>
|
99
|
-
<docidentifier type="
|
147
|
+
<docidentifier type="ISO">ISO/IEC/CD 17301-1-3</docidentifier>
|
148
|
+
<docidentifier type="iso-with-lang">ISO/IEC/CD 17301-1-3 (E)</docidentifier>
|
149
|
+
<docidentifier type="iso-reference">ISO/IEC/CD 17301-1-3 (E)</docidentifier>
|
100
150
|
<docidentifier type="iso-tc">17301</docidentifier>
|
101
151
|
<contributor>
|
102
152
|
<role type="author"/>
|
@@ -153,7 +203,45 @@ OUTPUT
|
|
153
203
|
</bibdata>
|
154
204
|
</iso-standard>
|
155
205
|
INPUT
|
156
|
-
{:agency=>"ISO/IEC",
|
206
|
+
{:agency=>"ISO/IEC",
|
207
|
+
:authors=>[],
|
208
|
+
:authors_affiliations=>{},
|
209
|
+
:docnumber=>"ISO/IEC/CD 17301-1-3",
|
210
|
+
:docnumber_lang=>"ISO/IEC/CD 17301-1-3 (E)",
|
211
|
+
:docnumber_reference=>"ISO/IEC/CD 17301-1-3 (E)",
|
212
|
+
:docnumeric=>nil,
|
213
|
+
:docsubtitle=>"Céréales et légumineuses — Spécification et méthodes d'essai — Partie 1–3: Riz",
|
214
|
+
:docsubtitleintro=>"Céréales et légumineuses",
|
215
|
+
:docsubtitlemain=>"Spécification et méthodes d'essai",
|
216
|
+
:docsubtitlepart=>"Riz",
|
217
|
+
:docsubtitlepartlabel=>"Partie 1–3",
|
218
|
+
:doctitle=>"Cereals and pulses — Specifications and test methods — Part 1–3: Rice",
|
219
|
+
:doctitleintro=>"Cereals and pulses",
|
220
|
+
:doctitlemain=>"Specifications and test methods",
|
221
|
+
:doctitlepart=>"Rice",
|
222
|
+
:doctitlepartlabel=>"Part 1–3",
|
223
|
+
:doctype=>"International Standard",
|
224
|
+
:docyear=>"2016",
|
225
|
+
:draft=>nil,
|
226
|
+
:draftinfo=>"",
|
227
|
+
:edition=>nil,
|
228
|
+
:editorialgroup=>["ABC 34", "DEF 4", "GHI 3"],
|
229
|
+
:ics=>"1.2.3, 1.2.3",
|
230
|
+
:keywords=>[],
|
231
|
+
:obsoletes=>"IEC 8121",
|
232
|
+
:obsoletes_part=>"3.1",
|
233
|
+
:publisher=>"International Organization for Standardization and International Electrotechnical Commission",
|
234
|
+
:revdate=>nil,
|
235
|
+
:revdate_monthyear=>nil,
|
236
|
+
:sc=>"DEF 4",
|
237
|
+
:secretariat=>"XXXX",
|
238
|
+
:stage=>"60",
|
239
|
+
:stage_int=>60,
|
240
|
+
:statusabbr=>"IS",
|
241
|
+
:tc=>"ABC 34",
|
242
|
+
:tc_docnumber=>["17301"],
|
243
|
+
:unpublished=>false,
|
244
|
+
:wg=>"GHI 3"}
|
157
245
|
OUTPUT
|
158
246
|
end
|
159
247
|
|