isodoc 2.0.4 → 2.0.5.2
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 +4 -4
- data/lib/isodoc/convert.rb +36 -18
- data/lib/isodoc/function/inline.rb +24 -13
- data/lib/isodoc/function/references.rb +1 -1
- data/lib/isodoc/i18n.rb +20 -7
- data/lib/isodoc/metadata_contributor.rb +1 -1
- data/lib/isodoc/presentation_function/bibdata.rb +26 -9
- data/lib/isodoc/presentation_function/inline.rb +116 -75
- data/lib/isodoc/presentation_function/math.rb +1 -0
- data/lib/isodoc/presentation_function/xrefs.rb +100 -0
- data/lib/isodoc/version.rb +1 -1
- data/lib/isodoc/word_function/body.rb +11 -1
- data/lib/isodoc/word_function/postprocess.rb +4 -6
- data/lib/isodoc/word_function/postprocess_cover.rb +82 -1
- data/lib/isodoc/xref/xref_anchor.rb +1 -0
- data/lib/isodoc/xref/xref_gen.rb +2 -1
- data/lib/isodoc/xref/xref_sect_gen.rb +14 -8
- data/lib/isodoc/xslfo_convert.rb +19 -19
- data/lib/isodoc-yaml/i18n-ar.yaml +11 -0
- data/lib/isodoc-yaml/i18n-de.yaml +11 -0
- data/lib/isodoc-yaml/i18n-en.yaml +11 -0
- data/lib/isodoc-yaml/i18n-es.yaml +11 -0
- data/lib/isodoc-yaml/i18n-fr.yaml +11 -0
- data/lib/isodoc-yaml/i18n-ru.yaml +11 -0
- data/lib/isodoc-yaml/i18n-zh-Hans.yaml +11 -0
- data/spec/isodoc/blocks_spec.rb +1 -1
- data/spec/isodoc/inline_spec.rb +527 -22
- data/spec/isodoc/metadata_spec.rb +1 -1
- data/spec/isodoc/postproc_spec.rb +466 -2
- data/spec/isodoc/presentation_xml_spec.rb +139 -0
- data/spec/isodoc/ref_spec.rb +7 -7
- data/spec/isodoc/section_spec.rb +1 -2
- data/spec/isodoc/terms_spec.rb +8 -8
- data/spec/isodoc/xref_spec.rb +60 -1188
- data/spec/isodoc/xslfo_convert_spec.rb +12 -7
- metadata +3 -2
data/spec/isodoc/ref_spec.rb
CHANGED
@@ -731,14 +731,14 @@ RSpec.describe IsoDoc do
|
|
731
731
|
<div>
|
732
732
|
<h1 class='ForewordTitle'>Foreword</h1>
|
733
733
|
<p id='_f06fd0d1-a203-4f3d-a515-0bdba0f8d83f'>
|
734
|
-
|
735
|
-
|
736
|
-
|
734
|
+
[110]
|
735
|
+
[1]
|
736
|
+
[2]
|
737
737
|
<a href='#ISO16634'>ISO 16634:-- (all parts)</a>
|
738
|
-
|
739
|
-
|
740
|
-
|
741
|
-
|
738
|
+
ICC/167
|
739
|
+
[10]
|
740
|
+
Citn
|
741
|
+
[5]
|
742
742
|
</p>
|
743
743
|
</div>
|
744
744
|
<p class='zzSTDTitle1'/>
|
data/spec/isodoc/section_spec.rb
CHANGED
@@ -1,7 +1,6 @@
|
|
1
1
|
require "spec_helper"
|
2
2
|
|
3
3
|
RSpec.describe IsoDoc do
|
4
|
-
=begin
|
5
4
|
it "processes prefatory blocks" do
|
6
5
|
input = <<~INPUT
|
7
6
|
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
@@ -1496,7 +1495,7 @@ RSpec.describe IsoDoc do
|
|
1496
1495
|
.new({ suppressheadingnumbers: true })
|
1497
1496
|
.convert("test", input, true))).to be_equivalent_to xmlpp(output)
|
1498
1497
|
end
|
1499
|
-
|
1498
|
+
|
1500
1499
|
it "processes floating titles" do
|
1501
1500
|
input = <<~INPUT
|
1502
1501
|
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
data/spec/isodoc/terms_spec.rb
CHANGED
@@ -137,9 +137,9 @@ RSpec.describe IsoDoc do
|
|
137
137
|
PRESXML
|
138
138
|
|
139
139
|
html = <<~"OUTPUT"
|
140
|
-
|
140
|
+
#{HTML_HDR}
|
141
141
|
<p class="zzSTDTitle1"/>
|
142
|
-
<div id="_terms_and_definitions"><h1>1.  Terms and Definitions</h1><p>For the purposes of this document, the following terms and definitions apply.</p><p class="TermNum" id="paddy1">1.1.</p><p class="Terms" style="text-align:left;"><b>paddy</b>, <in agriculture, dated></p><p>[SOURCE:
|
142
|
+
<div id="_terms_and_definitions"><h1>1.  Terms and Definitions</h1><p>For the purposes of this document, the following terms and definitions apply.</p><p class="TermNum" id="paddy1">1.1.</p><p class="Terms" style="text-align:left;"><b>paddy</b>, <in agriculture, dated></p><p>[SOURCE: ISO 7301:2011, Clause 3.1, modified
|
143
143
|
–
|
144
144
|
The term "cargo rice" is shown as deprecated, and Note 1 to entry is not included here]</p>
|
145
145
|
|
@@ -171,17 +171,17 @@ RSpec.describe IsoDoc do
|
|
171
171
|
</div>
|
172
172
|
<div id="_671a1994-4783-40d0-bc81-987d06ffb74e" class="Note" style="page-break-after: avoid;page-break-inside: avoid;"><p>Note 1 to entry: The starch of waxy rice consists almost entirely of amylopectin. The kernels have a tendency to stick together after cooking.</p></div>
|
173
173
|
<div id="_671a1994-4783-40d0-bc81-987d06ffb74f" class="Note"><p>Note 2 to entry: <ul><li>A</li></ul><p id="_19830f33-e46c-42cc-94ca-a5ef101132d5">The starch of waxy rice consists almost entirely of amylopectin. The kernels have a tendency to stick together after cooking.</p></p></div>
|
174
|
-
<p>[SOURCE:
|
175
|
-
|
174
|
+
<p>[SOURCE: ISO 7301:2011, 3.1
|
175
|
+
ISO 7301:2011, clause 3.1]</p></div>
|
176
176
|
</div>
|
177
177
|
</body>
|
178
178
|
</html>
|
179
179
|
OUTPUT
|
180
180
|
|
181
181
|
word = <<~"WORD"
|
182
|
-
|
182
|
+
#{WORD_HDR}
|
183
183
|
<p class="zzSTDTitle1"/>
|
184
|
-
<div id="_terms_and_definitions"><h1>1.<span style="mso-tab-count:1">  </span>Terms and Definitions</h1><p>For the purposes of this document, the following terms and definitions apply.</p><p class="TermNum" id="paddy1">1.1.</p><p class="Terms" style="text-align:left;"><b>paddy</b>, <in agriculture, dated></p><p>[SOURCE:
|
184
|
+
<div id="_terms_and_definitions"><h1>1.<span style="mso-tab-count:1">  </span>Terms and Definitions</h1><p>For the purposes of this document, the following terms and definitions apply.</p><p class="TermNum" id="paddy1">1.1.</p><p class="Terms" style="text-align:left;"><b>paddy</b>, <in agriculture, dated></p><p>[SOURCE: ISO 7301:2011, Clause 3.1, modified
|
185
185
|
–
|
186
186
|
The term "cargo rice" is shown as deprecated, and Note 1 to entry is not included here]</p>
|
187
187
|
|
@@ -213,8 +213,8 @@ RSpec.describe IsoDoc do
|
|
213
213
|
</div>
|
214
214
|
<div id="_671a1994-4783-40d0-bc81-987d06ffb74e" class="Note" style="page-break-after: avoid;page-break-inside: avoid;"><p class="Note">Note 1 to entry: The starch of waxy rice consists almost entirely of amylopectin. The kernels have a tendency to stick together after cooking.</p></div>
|
215
215
|
<div id="_671a1994-4783-40d0-bc81-987d06ffb74f" class="Note"><p class="Note">Note 2 to entry: <ul><li>A</li></ul><p id="_19830f33-e46c-42cc-94ca-a5ef101132d5">The starch of waxy rice consists almost entirely of amylopectin. The kernels have a tendency to stick together after cooking.</p></p></div>
|
216
|
-
<p>[SOURCE:
|
217
|
-
|
216
|
+
<p>[SOURCE: ISO 7301:2011, 3.1
|
217
|
+
ISO 7301:2011, clause 3.1]</p></div>
|
218
218
|
</div>
|
219
219
|
</body>
|
220
220
|
</html>
|