isodoc 1.8.0 → 1.8.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/isodoc.gemspec +1 -1
- data/lib/isodoc/class_utils.rb +1 -1
- data/lib/isodoc/convert.rb +8 -0
- data/lib/isodoc/function/inline.rb +3 -5
- data/lib/isodoc/html_function/html.rb +1 -0
- data/lib/isodoc/html_function/postprocess.rb +4 -6
- data/lib/isodoc/metadata_date.rb +13 -11
- data/lib/isodoc/presentation_function/bibdata.rb +2 -2
- data/lib/isodoc/presentation_function/terms.rb +74 -30
- data/lib/isodoc/presentation_xml_convert.rb +1 -1
- data/lib/isodoc/version.rb +1 -1
- data/lib/isodoc/word_function/body.rb +24 -14
- data/lib/isodoc/word_function/comments.rb +0 -4
- data/lib/isodoc/xref/xref_gen.rb +18 -22
- data/lib/isodoc/xref/xref_gen_seq.rb +10 -16
- data/lib/isodoc-yaml/i18n-ar.yaml +3 -0
- data/lib/isodoc-yaml/i18n-de.yaml +3 -0
- data/lib/isodoc-yaml/i18n-en.yaml +8 -5
- data/lib/isodoc-yaml/i18n-es.yaml +3 -0
- data/lib/isodoc-yaml/i18n-fr.yaml +3 -0
- data/lib/isodoc-yaml/i18n-ru.yaml +3 -0
- data/lib/isodoc-yaml/i18n-zh-Hans.yaml +3 -0
- data/spec/isodoc/blocks_spec.rb +14 -8
- data/spec/isodoc/i18n_spec.rb +15 -10
- data/spec/isodoc/inline_spec.rb +33 -43
- data/spec/isodoc/lists_spec.rb +344 -222
- data/spec/isodoc/section_spec.rb +12 -12
- data/spec/isodoc/table_spec.rb +71 -73
- data/spec/isodoc/terms_spec.rb +266 -212
- data/spec/isodoc/xref_numbering_spec.rb +347 -0
- data/spec/isodoc/xref_spec.rb +271 -350
- data/spec/spec_helper.rb +1 -1
- metadata +8 -7
data/spec/isodoc/section_spec.rb
CHANGED
@@ -328,7 +328,7 @@ RSpec.describe IsoDoc do
|
|
328
328
|
<title depth='2'>3.1.<tab/>Normal Terms</title>
|
329
329
|
<term id='J'>
|
330
330
|
<name>3.1.1.</name>
|
331
|
-
<preferred>Term2</preferred>
|
331
|
+
<preferred><strong>Term2</strong></preferred>
|
332
332
|
</term>
|
333
333
|
</terms>
|
334
334
|
<definitions id='K'>
|
@@ -473,7 +473,7 @@ RSpec.describe IsoDoc do
|
|
473
473
|
<div id="I">
|
474
474
|
<h2>3.1.  Normal Terms</h2>
|
475
475
|
<p class="TermNum" id="J">3.1.1.</p>
|
476
|
-
<p class="Terms" style="text-align:left;">Term2</p>
|
476
|
+
<p class="Terms" style="text-align:left;"><b>Term2</b></p>
|
477
477
|
</div><div id="K"><h2>3.2.  Definitions</h2>
|
478
478
|
<dl><dt><p>Symbol</p></dt><dd>Definition</dd></dl>
|
479
479
|
</div></div>
|
@@ -628,7 +628,7 @@ RSpec.describe IsoDoc do
|
|
628
628
|
|
629
629
|
<p class="TermNum" id="J">3.1.1.</p>
|
630
630
|
|
631
|
-
<p class="Terms" style="text-align:left;">Term2</p>
|
631
|
+
<p class="Terms" style="text-align:left;"><b>Term2</b></p>
|
632
632
|
|
633
633
|
</div>
|
634
634
|
<div id="K"><h2>3.2.<span style="mso-tab-count:1">  </span>Definitions</h2>
|
@@ -925,7 +925,7 @@ RSpec.describe IsoDoc do
|
|
925
925
|
Variant 1
|
926
926
|
</h2>
|
927
927
|
<p class='TermNum' id='J'>3.1.1.</p>
|
928
|
-
<p class='Terms' style='text-align:left;'>Term2</p>
|
928
|
+
<p class='Terms' style='text-align:left;'><b>Term2</b></p>
|
929
929
|
</div>
|
930
930
|
<div id='K'>
|
931
931
|
<h2>
|
@@ -1187,7 +1187,7 @@ RSpec.describe IsoDoc do
|
|
1187
1187
|
Variant 1
|
1188
1188
|
</h2>
|
1189
1189
|
<p class='TermNum' id='J'>3.1.1.</p>
|
1190
|
-
<p class='Terms' style='text-align:left;'>Term2</p>
|
1190
|
+
<p class='Terms' style='text-align:left;'><b>Term2</b></p>
|
1191
1191
|
</div>
|
1192
1192
|
<div id='K'>
|
1193
1193
|
<h2>
|
@@ -1431,7 +1431,7 @@ RSpec.describe IsoDoc do
|
|
1431
1431
|
<title depth='2'>Normal Terms</title>
|
1432
1432
|
<term id='J'>
|
1433
1433
|
<name>3.1.1.</name>
|
1434
|
-
<preferred>Term2</preferred>
|
1434
|
+
<preferred><strong>Term2</strong></preferred>
|
1435
1435
|
</term>
|
1436
1436
|
</terms>
|
1437
1437
|
<definitions id='K'>
|
@@ -1540,7 +1540,7 @@ RSpec.describe IsoDoc do
|
|
1540
1540
|
<title depth='1'>1.<tab/>Terms, Definitions, Symbols and Abbreviated Terms</title>
|
1541
1541
|
<term id='J'>
|
1542
1542
|
<name>1.1.</name>
|
1543
|
-
<preferred>Term2</preferred>
|
1543
|
+
<preferred><strong>Term2</strong></preferred>
|
1544
1544
|
</term>
|
1545
1545
|
</terms>
|
1546
1546
|
</sections>
|
@@ -1552,7 +1552,7 @@ RSpec.describe IsoDoc do
|
|
1552
1552
|
<p class="zzSTDTitle1"/>
|
1553
1553
|
<div id="H"><h1>1.  Terms, Definitions, Symbols and Abbreviated Terms</h1>
|
1554
1554
|
<p class="TermNum" id="J">1.1.</p>
|
1555
|
-
<p class="Terms" style="text-align:left;">Term2</p>
|
1555
|
+
<p class="Terms" style="text-align:left;"><b>Term2</b></p>
|
1556
1556
|
</div>
|
1557
1557
|
</div>
|
1558
1558
|
</body>
|
@@ -1835,7 +1835,7 @@ RSpec.describe IsoDoc do
|
|
1835
1835
|
<title>A.</title>
|
1836
1836
|
<term id='term-glossary'>
|
1837
1837
|
<name>A.1.</name>
|
1838
|
-
<preferred>Glossary</preferred>
|
1838
|
+
<preferred><strong>Glossary</strong></preferred>
|
1839
1839
|
</term>
|
1840
1840
|
</terms>
|
1841
1841
|
</annex>
|
@@ -1856,7 +1856,7 @@ RSpec.describe IsoDoc do
|
|
1856
1856
|
</title>
|
1857
1857
|
<term id='term-term-1'>
|
1858
1858
|
<name>B.1.1.</name>
|
1859
|
-
<preferred>Term</preferred>
|
1859
|
+
<preferred><strong>Term</strong></preferred>
|
1860
1860
|
</term>
|
1861
1861
|
</terms>
|
1862
1862
|
<terms id='QQ2' obligation='normative'>
|
@@ -1867,7 +1867,7 @@ RSpec.describe IsoDoc do
|
|
1867
1867
|
</title>
|
1868
1868
|
<term id='term-term-2'>
|
1869
1869
|
<name>B.2.1.</name>
|
1870
|
-
<preferred>Term</preferred>
|
1870
|
+
<preferred><strong>Term</strong></preferred>
|
1871
1871
|
</term>
|
1872
1872
|
</terms>
|
1873
1873
|
</annex>
|
@@ -1888,7 +1888,7 @@ RSpec.describe IsoDoc do
|
|
1888
1888
|
</title>
|
1889
1889
|
<term id='term-term-3'>
|
1890
1890
|
<name>C.1.1.</name>
|
1891
|
-
<preferred>Term</preferred>
|
1891
|
+
<preferred><strong>Term</strong></preferred>
|
1892
1892
|
</term>
|
1893
1893
|
</terms>
|
1894
1894
|
<references id='RR2' obligation='normative'>
|
data/spec/isodoc/table_spec.rb
CHANGED
@@ -3,71 +3,71 @@ require "spec_helper"
|
|
3
3
|
RSpec.describe IsoDoc do
|
4
4
|
it "processes IsoXML tables" do
|
5
5
|
input = <<~INPUT
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
6
|
+
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
7
|
+
<preface>
|
8
|
+
<foreword>
|
9
|
+
<table id="tableD-1" alt="tool tip" summary="long desc" width="70%" keep-with-next="true" keep-lines-together="true">
|
10
|
+
<name>Repeatability and reproducibility of <em>husked</em> rice yield<fn reference="1"><p>X</p></fn></name>
|
11
|
+
<colgroup>
|
12
|
+
<col width="30%"/>
|
13
|
+
<col width="20%"/>
|
14
|
+
<col width="20%"/>
|
15
|
+
<col width="20%"/>
|
16
|
+
<col width="10%"/>
|
17
|
+
</colgroup>
|
18
|
+
<thead>
|
19
|
+
<tr>
|
20
|
+
<td rowspan="2" align="left">Description</td>
|
21
|
+
<td colspan="4" align="center">Rice sample</td>
|
22
|
+
</tr>
|
23
|
+
<tr>
|
24
|
+
<td valign="top" align="left">Arborio</td>
|
25
|
+
<td valign="middle" align="center">Drago<fn reference="a">
|
26
|
+
<p id="_0fe65e9a-5531-408e-8295-eeff35f41a55">Parboiled rice.</p>
|
27
|
+
</fn></td>
|
28
|
+
<td valign="bottom" align="center">Balilla<fn reference="a">
|
29
|
+
<p id="_0fe65e9a-5531-408e-8295-eeff35f41a55">Parboiled rice.</p>
|
30
|
+
</fn></td>
|
31
|
+
<td align="center">Thaibonnet</td>
|
32
|
+
</tr>
|
33
|
+
</thead>
|
34
|
+
<tbody>
|
35
|
+
<tr>
|
36
|
+
<th align="left">Number of laboratories retained after eliminating outliers</th>
|
37
|
+
<td align="center">13</td>
|
38
|
+
<td align="center">11</td>
|
39
|
+
<td align="center">13</td>
|
40
|
+
<td align="center">13</td>
|
41
|
+
</tr>
|
42
|
+
<tr>
|
43
|
+
<td align="left">Mean value, g/100 g</td>
|
44
|
+
<td align="center">81,2</td>
|
45
|
+
<td align="center">82,0</td>
|
46
|
+
<td align="center">81,8</td>
|
47
|
+
<td align="center">77,7</td>
|
48
|
+
</tr>
|
49
|
+
</tbody>
|
50
|
+
<tfoot>
|
51
|
+
<tr>
|
52
|
+
<td align="left">Reproducibility limit, <stem type="AsciiMath">R</stem> (= 2,83 <stem type="AsciiMath">s_R</stem>)</td>
|
53
|
+
<td align="center">2,89</td>
|
54
|
+
<td align="center">0,57</td>
|
55
|
+
<td align="center">2,26</td>
|
56
|
+
<td align="center">6,06</td>
|
57
|
+
</tr>
|
58
|
+
</tfoot>
|
59
|
+
<dl>
|
60
|
+
<dt>Drago</dt>
|
61
|
+
<dd>A type of rice</dd>
|
62
|
+
</dl>
|
63
|
+
<note><p>This is a table about rice</p></note>
|
64
|
+
</table>
|
65
|
+
<table id="tableD-2" unnumbered="true">
|
66
|
+
<tbody><tr><td>A</td></tr></tbody>
|
67
|
+
</table>
|
68
|
+
</foreword>
|
69
|
+
</preface>
|
70
|
+
</iso-standard>
|
71
71
|
INPUT
|
72
72
|
|
73
73
|
presxml = <<~OUTPUT
|
@@ -344,14 +344,12 @@ RSpec.describe IsoDoc do
|
|
344
344
|
<td align='center' style='border-top:solid windowtext 1.5pt;mso-border-top-alt:solid windowtext 1.5pt;border-bottom:solid windowtext 1.5pt;mso-border-bottom-alt:solid windowtext 1.5pt;'>6,06</td>
|
345
345
|
</tr>
|
346
346
|
</tfoot>
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
</tr>
|
354
|
-
</table>
|
347
|
+
<dl>
|
348
|
+
<dt>
|
349
|
+
<p align='left' style='margin-left:0pt;text-align:left;'>Drago</p>
|
350
|
+
</dt>
|
351
|
+
<dd>A type of rice</dd>
|
352
|
+
</dl>
|
355
353
|
<div class='Note'>
|
356
354
|
<p class='Note'>
|
357
355
|
<span class='note_label'>NOTE</span>
|