isodoc 1.5.0 → 1.5.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/rake.yml +11 -41
- data/.rubocop.yml +6 -2
- data/isodoc.gemspec +3 -2
- data/lib/isodoc/convert.rb +4 -0
- data/lib/isodoc/css.rb +6 -1
- data/lib/isodoc/function/blocks.rb +4 -0
- data/lib/isodoc/function/inline.rb +1 -1
- data/lib/isodoc/function/references.rb +1 -1
- data/lib/isodoc/function/to_word_html.rb +1 -0
- data/lib/isodoc/html_function/postprocess.rb +8 -5
- data/lib/isodoc/presentation_function/block.rb +16 -4
- data/lib/isodoc/presentation_function/inline.rb +14 -22
- data/lib/isodoc/presentation_function/section.rb +1 -1
- data/lib/isodoc/version.rb +1 -1
- data/lib/isodoc/word_function/inline.rb +6 -0
- data/lib/isodoc/word_function/postprocess.rb +16 -6
- data/lib/isodoc/xref.rb +1 -1
- data/lib/isodoc/xref/xref_gen.rb +16 -15
- data/lib/isodoc/xslfo_convert.rb +2 -0
- data/spec/assets/html_override.css +1 -0
- data/spec/assets/word_override.css +1 -0
- data/spec/isodoc/blocks_spec.rb +144 -1
- data/spec/isodoc/inline_spec.rb +4 -1
- data/spec/isodoc/postproc_spec.rb +6 -2
- data/spec/isodoc/presentation_xml_spec.rb +6 -2
- data/spec/isodoc/xref_spec.rb +16 -10
- metadata +25 -11
- data/.rubocop.ribose.yml +0 -65
- data/.rubocop.tb.yml +0 -650
data/lib/isodoc/xref.rb
CHANGED
@@ -49,7 +49,7 @@ module IsoDoc
|
|
49
49
|
note_anchor_names(docxml.xpath(ns(SECTIONS_XPATH)))
|
50
50
|
example_anchor_names(docxml.xpath(ns(SECTIONS_XPATH)))
|
51
51
|
list_anchor_names(docxml.xpath(ns(SECTIONS_XPATH)))
|
52
|
-
bookmark_anchor_names(docxml
|
52
|
+
bookmark_anchor_names(docxml)
|
53
53
|
end
|
54
54
|
|
55
55
|
def ns(xpath)
|
data/lib/isodoc/xref/xref_gen.rb
CHANGED
@@ -94,16 +94,17 @@ module IsoDoc::XrefGen
|
|
94
94
|
"not(self::xmlns:terms) and not(self::xmlns:definitions)]//"\
|
95
95
|
"xmlns:example | ./xmlns:example".freeze
|
96
96
|
|
97
|
-
CHILD_SECTIONS = "./clause | ./appendix | ./terms | ./definitions |
|
97
|
+
CHILD_SECTIONS = "./clause | ./appendix | ./terms | ./definitions | "\
|
98
|
+
"./references"
|
98
99
|
|
99
100
|
def example_anchor_names(sections)
|
100
101
|
sections.each do |s|
|
101
102
|
notes = s.xpath(CHILD_EXAMPLES_XPATH)
|
102
103
|
c = Counter.new
|
103
104
|
notes.each do |n|
|
104
|
-
next if @anchors[n["id"]]
|
105
|
-
|
106
|
-
|
105
|
+
next if @anchors[n["id"]] || n["id"].nil? || n["id"].empty?
|
106
|
+
idx = notes.size == 1 && !n["number"] ? "" :
|
107
|
+
" #{c.increment(n).print}"
|
107
108
|
@anchors[n["id"]] = anchor_struct(idx, n, @labels["example_xref"],
|
108
109
|
"example", n["unnumbered"])
|
109
110
|
end
|
@@ -119,7 +120,8 @@ module IsoDoc::XrefGen
|
|
119
120
|
notes.each do |n|
|
120
121
|
next if n["id"].nil? || n["id"].empty?
|
121
122
|
idx = notes.size == 1 && !n["number"] ? "" : " #{c.increment(n).print}"
|
122
|
-
@anchors[n["id"]] = anchor_struct(idx, n, @labels["list"], "list",
|
123
|
+
@anchors[n["id"]] = anchor_struct(idx, n, @labels["list"], "list",
|
124
|
+
false)
|
123
125
|
list_item_anchor_names(n, @anchors[n["id"]], 1, "", notes.size != 1)
|
124
126
|
end
|
125
127
|
list_anchor_names(s.xpath(ns(CHILD_SECTIONS)))
|
@@ -141,17 +143,16 @@ module IsoDoc::XrefGen
|
|
141
143
|
end
|
142
144
|
end
|
143
145
|
|
144
|
-
def bookmark_anchor_names(
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
next
|
150
|
-
|
151
|
-
type: "bookmark", label: nil, value: nil,
|
152
|
-
xref: @anchors[s["id"]][:xref] }
|
146
|
+
def bookmark_anchor_names(docxml)
|
147
|
+
docxml.xpath(ns(".//bookmark")).each do |n|
|
148
|
+
next if n["id"].nil? || n["id"].empty?
|
149
|
+
parent = nil
|
150
|
+
n.ancestors.each do |a|
|
151
|
+
next unless a["id"] && parent = @anchors.dig(a["id"], :xref)
|
152
|
+
break
|
153
153
|
end
|
154
|
-
|
154
|
+
@anchors[n["id"]] = { type: "bookmark", label: nil, value: nil,
|
155
|
+
xref: parent || "???" }
|
155
156
|
end
|
156
157
|
end
|
157
158
|
end
|
data/lib/isodoc/xslfo_convert.rb
CHANGED
@@ -0,0 +1 @@
|
|
1
|
+
/* html-override */
|
@@ -0,0 +1 @@
|
|
1
|
+
/* word-override */
|
data/spec/isodoc/blocks_spec.rb
CHANGED
@@ -768,6 +768,93 @@ B</pre>
|
|
768
768
|
expect(xmlpp(strip_guid(IsoDoc::WordConvert.new({}).convert("test", presxml, true).gsub(/['"][^'".]+\.(gif|xml)['"]/, "'_.\\1'").gsub(/mso-bookmark:_Ref\d+/, "mso-bookmark:_Ref")))).to be_equivalent_to xmlpp(word)
|
769
769
|
end
|
770
770
|
|
771
|
+
it "processes SVG" do
|
772
|
+
input = <<~INPUT
|
773
|
+
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
774
|
+
<preface><foreword>
|
775
|
+
<figure id="figureA-1">
|
776
|
+
<image src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxMDAgMTAwIj4KICA8Y2lyY2xlIGZpbGw9IiMwMDkiIHI9IjQ1IiBjeD0iNTAiIGN5PSI1MCIvPgogIDxwYXRoIGQ9Ik0zMywyNkg3OEEzNywzNywwLDAsMSwzMyw4M1Y1N0g1OVY0M0gzM1oiIGZpbGw9IiNGRkYiLz4KPC9zdmc+Cg==" id="_d3731866-1a07-435a-a6c2-1acd41023a4e" mimetype="image/svg+xml" height="auto" width="auto"/>
|
777
|
+
</figure>
|
778
|
+
</foreword></preface>
|
779
|
+
</iso-standard>
|
780
|
+
INPUT
|
781
|
+
|
782
|
+
presxml = <<~OUTPUT
|
783
|
+
<iso-standard xmlns='http://riboseinc.com/isoxml' type='presentation'>
|
784
|
+
<preface>
|
785
|
+
<foreword>
|
786
|
+
<figure id='figureA-1'>
|
787
|
+
<name>Figure 1</name>
|
788
|
+
<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'>
|
789
|
+
<circle fill='#009' r='45' cx='50' cy='50'/>
|
790
|
+
<path d='M33,26H78A37,37,0,0,1,33,83V57H59V43H33Z' fill='#FFF'/>
|
791
|
+
</svg>
|
792
|
+
</figure>
|
793
|
+
</foreword>
|
794
|
+
</preface>
|
795
|
+
</iso-standard>
|
796
|
+
OUTPUT
|
797
|
+
|
798
|
+
html = <<~HTML
|
799
|
+
#{HTML_HDR}
|
800
|
+
<br/>
|
801
|
+
<div>
|
802
|
+
<h1 class='ForewordTitle'>Foreword</h1>
|
803
|
+
<div id='figureA-1' class='figure'>
|
804
|
+
<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'>
|
805
|
+
<circle fill='#009' r='45' cx='50' cy='50'/>
|
806
|
+
<path d='M33,26H78A37,37,0,0,1,33,83V57H59V43H33Z' fill='#FFF'/>
|
807
|
+
</svg>
|
808
|
+
<p class='FigureTitle' style='text-align:center;'>Figure 1</p>
|
809
|
+
</div>
|
810
|
+
</div>
|
811
|
+
<p class='zzSTDTitle1'/>
|
812
|
+
</div>
|
813
|
+
</body>
|
814
|
+
</html>
|
815
|
+
HTML
|
816
|
+
|
817
|
+
doc = <<~DOC
|
818
|
+
<html xmlns:epub='http://www.idpf.org/2007/ops' lang='en'>
|
819
|
+
<head>
|
820
|
+
<style>
|
821
|
+
</style>
|
822
|
+
</head>
|
823
|
+
<body lang='EN-US' link='blue' vlink='#954F72'>
|
824
|
+
<div class='WordSection1'>
|
825
|
+
<p> </p>
|
826
|
+
</div>
|
827
|
+
<p>
|
828
|
+
<br clear='all' class='section'/>
|
829
|
+
</p>
|
830
|
+
<div class='WordSection2'>
|
831
|
+
<p>
|
832
|
+
<br clear='all' style='mso-special-character:line-break;page-break-before:always'/>
|
833
|
+
</p>
|
834
|
+
<div>
|
835
|
+
<h1 class='ForewordTitle'>Foreword</h1>
|
836
|
+
<div id='figureA-1' class='figure'>
|
837
|
+
<img src='_.emf'/>
|
838
|
+
<p class='FigureTitle' style='text-align:center;'>Figure 1</p>
|
839
|
+
</div>
|
840
|
+
</div>
|
841
|
+
<p> </p>
|
842
|
+
</div>
|
843
|
+
<p>
|
844
|
+
<br clear='all' class='section'/>
|
845
|
+
</p>
|
846
|
+
<div class='WordSection3'>
|
847
|
+
<p class='zzSTDTitle1'/>
|
848
|
+
</div>
|
849
|
+
</body>
|
850
|
+
</html>
|
851
|
+
DOC
|
852
|
+
|
853
|
+
expect(xmlpp(IsoDoc::PresentationXMLConvert.new({}).convert("test", input, true).gsub(/\</, "<"))).to be_equivalent_to xmlpp(presxml)
|
854
|
+
expect(xmlpp(strip_guid(IsoDoc::HtmlConvert.new({}).convert("test", presxml, true)))).to be_equivalent_to xmlpp(html)
|
855
|
+
expect(xmlpp(strip_guid(IsoDoc::WordConvert.new({}).convert("test", presxml, true).gsub(/['"][^'".]+(?<!odf1)(?<!odf)\.emf['"]/, "'_.emf'").gsub(/['"][^'".]+\.(gif|xml)['"]/, "'_.\\1'")))).to be_equivalent_to xmlpp(doc)
|
856
|
+
end
|
857
|
+
|
771
858
|
it "converts SVG (Word)" do
|
772
859
|
FileUtils.rm_rf "spec/assets/odf1.emf"
|
773
860
|
expect(xmlpp(strip_guid(IsoDoc::WordConvert.new({}).convert("test", <<~"INPUT", true).gsub(/['"][^'".]+(?<!odf1)(?<!odf)\.emf['"]/, "'_.emf'").gsub(/['"][^'".]+\.(gif|xml)['"]/, "'_.\\1'").gsub(/mso-bookmark:_Ref\d+/, "mso-bookmark:_Ref")))).to be_equivalent_to xmlpp(<<~"OUTPUT")
|
@@ -2687,7 +2774,7 @@ expect(( File.read("test.html").gsub(%r{^.*<h1 class="ForewordTitle">Foreword</h
|
|
2687
2774
|
expect(File.exist?("test.html.err")).to be true
|
2688
2775
|
end
|
2689
2776
|
|
2690
|
-
it "
|
2777
|
+
it "ignores passthrough with incompatible format" do
|
2691
2778
|
expect(xmlpp(IsoDoc::HtmlConvert.new({}).convert("test", <<~"INPUT", true))).to be_equivalent_to xmlpp(<<~"OUTPUT")
|
2692
2779
|
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
2693
2780
|
<preface><foreword>
|
@@ -2707,6 +2794,62 @@ expect(( File.read("test.html").gsub(%r{^.*<h1 class="ForewordTitle">Foreword</h
|
|
2707
2794
|
OUTPUT
|
2708
2795
|
end
|
2709
2796
|
|
2797
|
+
it "processes svgmap" do
|
2798
|
+
expect(xmlpp(IsoDoc::PresentationXMLConvert.new({}).convert("test", <<~INPUT, true)).sub(%r{<localized-strings>.*</localized-strings>}m, "")).to be_equivalent_to xmlpp(<<~OUTPUT)
|
2799
|
+
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
2800
|
+
<sections>
|
2801
|
+
<svgmap id='_'>
|
2802
|
+
<target href='http://www.example.com'>
|
2803
|
+
<xref target='ref1'>Computer</xref>
|
2804
|
+
</target>
|
2805
|
+
</svgmap>
|
2806
|
+
<figure id='_'>
|
2807
|
+
<image src='action_schemaexpg1.svg' id='_' mimetype='image/svg+xml' height='auto' width='auto'/>
|
2808
|
+
</figure>
|
2809
|
+
<svgmap id='_'>
|
2810
|
+
<figure id='_'>
|
2811
|
+
<image src='action_schemaexpg2.svg' id='_' mimetype='image/svg+xml' height='auto' width='auto' alt='Workmap'/>
|
2812
|
+
</figure>
|
2813
|
+
<target href='mn://support_resource_schema'>
|
2814
|
+
<eref bibitemid='express_action_schema' citeas=''>
|
2815
|
+
<localityStack>
|
2816
|
+
<locality type='anchor'>
|
2817
|
+
<referenceFrom>action_schema.basic</referenceFrom>
|
2818
|
+
</locality>
|
2819
|
+
</localityStack>
|
2820
|
+
Coffee
|
2821
|
+
</eref>
|
2822
|
+
</target>
|
2823
|
+
</svgmap>
|
2824
|
+
</sections>
|
2825
|
+
<bibliography>
|
2826
|
+
<references hidden='true' normative='false'>
|
2827
|
+
<bibitem id='express_action_schema' type='internal'>
|
2828
|
+
<docidentifier type='repository'>express/action_schema</docidentifier>
|
2829
|
+
</bibitem>
|
2830
|
+
</references>
|
2831
|
+
</bibliography>
|
2832
|
+
</iso-standard>
|
2833
|
+
INPUT
|
2834
|
+
<iso-standard xmlns='http://riboseinc.com/isoxml' type='presentation'>
|
2835
|
+
<sections>
|
2836
|
+
<figure id='_'>
|
2837
|
+
<image src='action_schemaexpg1.svg' id='_' mimetype='image/svg+xml' height='auto' width='auto'/>
|
2838
|
+
</figure>
|
2839
|
+
<figure id='_'>
|
2840
|
+
<image src='action_schemaexpg2.svg' id='_' mimetype='image/svg+xml' height='auto' width='auto' alt='Workmap'/>
|
2841
|
+
</figure>
|
2842
|
+
</sections>
|
2843
|
+
<bibliography>
|
2844
|
+
<references hidden='true' normative='false'>
|
2845
|
+
<bibitem id='express_action_schema' type='internal'>
|
2846
|
+
<docidentifier type='repository'>express/action_schema</docidentifier>
|
2847
|
+
</bibitem>
|
2848
|
+
</references>
|
2849
|
+
</bibliography>
|
2850
|
+
</iso-standard>
|
2851
|
+
OUTPUT
|
2710
2852
|
|
2853
|
+
end
|
2711
2854
|
|
2712
2855
|
end
|
data/spec/isodoc/inline_spec.rb
CHANGED
@@ -124,7 +124,10 @@ OUTPUT
|
|
124
124
|
<preface><foreword>
|
125
125
|
<p><index primary="A" secondary="B" tertiary="C"/></p>
|
126
126
|
</foreword></preface>
|
127
|
-
<sections
|
127
|
+
<sections/>
|
128
|
+
<indexsect>
|
129
|
+
<title>Index</title>
|
130
|
+
</indexsect>
|
128
131
|
</iso-standard>
|
129
132
|
INPUT
|
130
133
|
<iso-standard xmlns='http://riboseinc.com/isoxml' type='presentation'>
|
@@ -83,6 +83,7 @@ expect(File.exist?("test.doc")).to be true
|
|
83
83
|
expect(html).not_to match(/another empty stylesheet/)
|
84
84
|
expect(html).to match(%r{cdnjs\.cloudflare\.com/ajax/libs/mathjax/})
|
85
85
|
expect(html).to match(/delimiters: \[\['\(#\(', '\)#\)'\]\]/)
|
86
|
+
expect(html).not_to match(/html-override/)
|
86
87
|
end
|
87
88
|
|
88
89
|
it "generates Word output docs with null configuration" do
|
@@ -101,6 +102,7 @@ expect(File.exist?("test.doc")).to be true
|
|
101
102
|
word = File.read("test.doc")
|
102
103
|
expect(word).to match(/one empty stylesheet/)
|
103
104
|
expect(word).to match(/div\.table_container/)
|
105
|
+
expect(word).not_to match(/word-override/)
|
104
106
|
end
|
105
107
|
|
106
108
|
it "generates HTML output docs with null configuration from file" do
|
@@ -139,7 +141,7 @@ expect(File.exist?("test.doc")).to be true
|
|
139
141
|
it "generates HTML output docs with complete configuration" do
|
140
142
|
FileUtils.rm_f "test.doc"
|
141
143
|
FileUtils.rm_f "test.html"
|
142
|
-
IsoDoc::HtmlConvert.new({bodyfont: "Zapf", monospacefont: "Consolas", headerfont: "Comic Sans", normalfontsize: "30pt", monospacefontsize: "29pt", smallerfontsize: "28pt", footnotefontsize: "27pt", htmlstylesheet: "spec/assets/html.scss", htmlcoverpage: "spec/assets/htmlcover.html", htmlintropage: "spec/assets/htmlintro.html", scripts: "spec/assets/scripts.html", i18nyaml: "spec/assets/i18n.yaml", ulstyle: "l1", olstyle: "l2"}).convert("test", <<~"INPUT", false)
|
144
|
+
IsoDoc::HtmlConvert.new({bodyfont: "Zapf", monospacefont: "Consolas", headerfont: "Comic Sans", normalfontsize: "30pt", monospacefontsize: "29pt", smallerfontsize: "28pt", footnotefontsize: "27pt", htmlstylesheet: "spec/assets/html.scss", htmlstylesheet_override: "spec/assets/html_override.css", htmlcoverpage: "spec/assets/htmlcover.html", htmlintropage: "spec/assets/htmlintro.html", scripts: "spec/assets/scripts.html", i18nyaml: "spec/assets/i18n.yaml", ulstyle: "l1", olstyle: "l2"}).convert("test", <<~"INPUT", false)
|
143
145
|
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
144
146
|
<preface><foreword>
|
145
147
|
<note>
|
@@ -162,6 +164,7 @@ expect(File.exist?("test.doc")).to be true
|
|
162
164
|
expect(html).to match(/This is > a script/)
|
163
165
|
expect(html).not_to match(/CDATA/)
|
164
166
|
expect(html).to match(%r{Antaŭparolo</h1>})
|
167
|
+
expect(html).to match(%r{html-override})
|
165
168
|
end
|
166
169
|
|
167
170
|
it "generates HTML output docs with default fonts" do
|
@@ -195,7 +198,7 @@ expect(File.exist?("test.doc")).to be true
|
|
195
198
|
it "generates Word output docs with complete configuration" do
|
196
199
|
FileUtils.rm_f "test.doc"
|
197
200
|
FileUtils.rm_f "test.html"
|
198
|
-
IsoDoc::WordConvert.new({bodyfont: "Zapf", monospacefont: "Consolas", headerfont: "Comic Sans", normalfontsize: "30pt", monospacefontsize: "29pt", smallerfontsize: "28pt", footnotefontsize: "27pt", wordstylesheet: "spec/assets/html.scss", standardstylesheet: "spec/assets/std.css", header: "spec/assets/header.html", wordcoverpage: "spec/assets/wordcover.html", wordintropage: "spec/assets/wordintro.html", i18nyaml: "spec/assets/i18n.yaml", ulstyle: "l1", olstyle: "l2"}).convert("test", <<~"INPUT", false)
|
201
|
+
IsoDoc::WordConvert.new({bodyfont: "Zapf", monospacefont: "Consolas", headerfont: "Comic Sans", normalfontsize: "30pt", monospacefontsize: "29pt", smallerfontsize: "28pt", footnotefontsize: "27pt", wordstylesheet: "spec/assets/html.scss", wordstylesheet_override: "spec/assets/word_override.css", standardstylesheet: "spec/assets/std.css", header: "spec/assets/header.html", wordcoverpage: "spec/assets/wordcover.html", wordintropage: "spec/assets/wordintro.html", i18nyaml: "spec/assets/i18n.yaml", ulstyle: "l1", olstyle: "l2"}).convert("test", <<~"INPUT", false)
|
199
202
|
<iso-standard xmlns="http://riboseinc.com/isoxml">
|
200
203
|
<preface><foreword>
|
201
204
|
<note>
|
@@ -219,6 +222,7 @@ expect(File.exist?("test.doc")).to be true
|
|
219
222
|
expect(word).to match(/an empty word cover page/)
|
220
223
|
expect(word).to match(/an empty word intro page/)
|
221
224
|
expect(word).to match(%r{Antaŭparolo</h1>})
|
225
|
+
expect(word).to match(%r{word-override})
|
222
226
|
end
|
223
227
|
|
224
228
|
it "generates Word output docs with default fonts" do
|
@@ -25,7 +25,10 @@ it "localises numbers in MathML" do
|
|
25
25
|
<title language="en">test</title>
|
26
26
|
</bibdata>
|
27
27
|
<preface>
|
28
|
-
<p
|
28
|
+
<p>
|
29
|
+
<stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mn>64212149677264515</mn></math></stem>
|
30
|
+
<stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mn>642121496772645.15</mn></math></stem>
|
31
|
+
<stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mn>30000</mn></math></stem>
|
29
32
|
<stem type="MathML"><math xmlns="http://www.w3.org/1998/Math/MathML"><mi>P</mi><mfenced open="(" close=")"><mrow><mi>X</mi><mo>≥</mo><msub><mrow><mi>X</mi></mrow><mrow><mo>max</mo></mrow></msub></mrow></mfenced><mo>=</mo><munderover><mrow><mo>∑</mo></mrow><mrow><mrow><mi>j</mi><mo>=</mo><msub><mrow><mi>X</mi></mrow><mrow><mo>max</mo></mrow></msub></mrow></mrow><mrow><mn>1000</mn></mrow></munderover><mfenced open="(" close=")"><mtable><mtr><mtd><mn>1000</mn></mtd></mtr><mtr><mtd><mi>j</mi></mtd></mtr></mtable></mfenced><msup><mrow><mi>p</mi></mrow><mrow><mi>j</mi></mrow></msup><msup><mrow><mfenced open="(" close=")"><mrow><mn>1</mn><mo>−</mo><mi>p</mi></mrow></mfenced></mrow><mrow><mrow><mn>1.003</mn><mo>−</mo><mi>j</mi></mrow></mrow></msup></math></stem></p>
|
30
33
|
</preface>
|
31
34
|
</iso-standard>
|
@@ -37,7 +40,8 @@ it "localises numbers in MathML" do
|
|
37
40
|
|
38
41
|
<preface>
|
39
42
|
<p>
|
40
|
-
|
43
|
+
64,212,149,677,264,515
|
44
|
+
642,121,496,772,645.15 30,000
|
41
45
|
<stem type='MathML'>
|
42
46
|
<math xmlns='http://www.w3.org/1998/Math/MathML'>
|
43
47
|
<mi>P</mi>
|
data/spec/isodoc/xref_spec.rb
CHANGED
@@ -2583,9 +2583,10 @@ OUTPUT
|
|
2583
2583
|
<terms id="terms"/>
|
2584
2584
|
<clause id="widgets"><title>Widgets</title>
|
2585
2585
|
<clause id="widgets1">
|
2586
|
-
<
|
2586
|
+
<note id="note0"/>
|
2587
|
+
<note id="note1l" type="alphabet">
|
2587
2588
|
<bookmark id="note1"/>
|
2588
|
-
</
|
2589
|
+
</note>
|
2589
2590
|
<p id="note2l" type="roman_upper">
|
2590
2591
|
<bookmark id="note2"/>
|
2591
2592
|
</p>
|
@@ -2599,9 +2600,9 @@ OUTPUT
|
|
2599
2600
|
</p>
|
2600
2601
|
</clause>
|
2601
2602
|
<clause id="annex1b">
|
2602
|
-
<
|
2603
|
+
<figure id="Anote1l" type="roman" start="4">
|
2603
2604
|
<bookmark id="Anote1"/>
|
2604
|
-
</
|
2605
|
+
</figure>
|
2605
2606
|
<p id="Anote2l">
|
2606
2607
|
<bookmark id="Anote2"/>
|
2607
2608
|
</p>
|
@@ -2616,10 +2617,10 @@ OUTPUT
|
|
2616
2617
|
<xref target='N1'>Introduction</xref>
|
2617
2618
|
<xref target='N2'>Preparatory</xref>
|
2618
2619
|
<xref target='N'>Clause 1</xref>
|
2619
|
-
<xref target='note1'>
|
2620
|
+
<xref target='note1'>Note 2</xref>
|
2620
2621
|
<xref target='note2'>Clause 3.1</xref>
|
2621
2622
|
<xref target='AN'>Annex A.1</xref>
|
2622
|
-
<xref target='Anote1'>
|
2623
|
+
<xref target='Anote1'>Figure A.1</xref>
|
2623
2624
|
<xref target='Anote2'>Annex A.2</xref>
|
2624
2625
|
</p>
|
2625
2626
|
</foreword>
|
@@ -2657,9 +2658,13 @@ OUTPUT
|
|
2657
2658
|
</title>
|
2658
2659
|
<clause id='widgets1'>
|
2659
2660
|
<title>3.1.</title>
|
2660
|
-
<
|
2661
|
+
<note id='note0'>
|
2662
|
+
<name>NOTE 1</name>
|
2663
|
+
</note>
|
2664
|
+
<note id='note1l' type='alphabet'>
|
2665
|
+
<name>NOTE 2</name>
|
2661
2666
|
<bookmark id='note1'/>
|
2662
|
-
</
|
2667
|
+
</note>
|
2663
2668
|
<p id='note2l' type='roman_upper'>
|
2664
2669
|
<bookmark id='note2'/>
|
2665
2670
|
</p>
|
@@ -2680,9 +2685,10 @@ OUTPUT
|
|
2680
2685
|
</clause>
|
2681
2686
|
<clause id='annex1b'>
|
2682
2687
|
<title>A.2.</title>
|
2683
|
-
<
|
2688
|
+
<figure id='Anote1l' type='roman' start='4'>
|
2689
|
+
<name>Figure A.1</name>
|
2684
2690
|
<bookmark id='Anote1'/>
|
2685
|
-
</
|
2691
|
+
</figure>
|
2686
2692
|
<p id='Anote2l'>
|
2687
2693
|
<bookmark id='Anote2'/>
|
2688
2694
|
</p>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: isodoc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-03-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: asciimath
|
@@ -114,14 +114,14 @@ dependencies:
|
|
114
114
|
requirements:
|
115
115
|
- - ">="
|
116
116
|
- !ruby/object:Gem::Version
|
117
|
-
version:
|
117
|
+
version: 6.6.0
|
118
118
|
type: :runtime
|
119
119
|
prerelease: false
|
120
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
121
|
requirements:
|
122
122
|
- - ">="
|
123
123
|
- !ruby/object:Gem::Version
|
124
|
-
version:
|
124
|
+
version: 6.6.0
|
125
125
|
- !ruby/object:Gem::Dependency
|
126
126
|
name: roman-numerals
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|
@@ -266,16 +266,16 @@ dependencies:
|
|
266
266
|
name: rubocop
|
267
267
|
requirement: !ruby/object:Gem::Requirement
|
268
268
|
requirements:
|
269
|
-
- -
|
269
|
+
- - "~>"
|
270
270
|
- !ruby/object:Gem::Version
|
271
|
-
version:
|
271
|
+
version: 1.5.2
|
272
272
|
type: :development
|
273
273
|
prerelease: false
|
274
274
|
version_requirements: !ruby/object:Gem::Requirement
|
275
275
|
requirements:
|
276
|
-
- -
|
276
|
+
- - "~>"
|
277
277
|
- !ruby/object:Gem::Version
|
278
|
-
version:
|
278
|
+
version: 1.5.2
|
279
279
|
- !ruby/object:Gem::Dependency
|
280
280
|
name: simplecov
|
281
281
|
requirement: !ruby/object:Gem::Requirement
|
@@ -304,6 +304,20 @@ dependencies:
|
|
304
304
|
- - "~>"
|
305
305
|
- !ruby/object:Gem::Version
|
306
306
|
version: '0.9'
|
307
|
+
- !ruby/object:Gem::Dependency
|
308
|
+
name: rexml
|
309
|
+
requirement: !ruby/object:Gem::Requirement
|
310
|
+
requirements:
|
311
|
+
- - ">="
|
312
|
+
- !ruby/object:Gem::Version
|
313
|
+
version: '0'
|
314
|
+
type: :development
|
315
|
+
prerelease: false
|
316
|
+
version_requirements: !ruby/object:Gem::Requirement
|
317
|
+
requirements:
|
318
|
+
- - ">="
|
319
|
+
- !ruby/object:Gem::Version
|
320
|
+
version: '0'
|
307
321
|
description: |
|
308
322
|
isodoc converts documents in the IsoDoc document model into
|
309
323
|
Microsoft Word and HTML.
|
@@ -318,8 +332,6 @@ files:
|
|
318
332
|
- ".github/workflows/rake.yml"
|
319
333
|
- ".hound.yml"
|
320
334
|
- ".oss-guides.rubocop.yml"
|
321
|
-
- ".rubocop.ribose.yml"
|
322
|
-
- ".rubocop.tb.yml"
|
323
335
|
- ".rubocop.yml"
|
324
336
|
- CODE_OF_CONDUCT.md
|
325
337
|
- Gemfile
|
@@ -406,6 +418,7 @@ files:
|
|
406
418
|
- lib/isodoc/xslfo_convert.rb
|
407
419
|
- spec/assets/header.html
|
408
420
|
- spec/assets/html.scss
|
421
|
+
- spec/assets/html_override.css
|
409
422
|
- spec/assets/htmlcover.html
|
410
423
|
- spec/assets/htmlintro.html
|
411
424
|
- spec/assets/i18n.yaml
|
@@ -418,6 +431,7 @@ files:
|
|
418
431
|
- spec/assets/scripts.html
|
419
432
|
- spec/assets/std.css
|
420
433
|
- spec/assets/word.css
|
434
|
+
- spec/assets/word_override.css
|
421
435
|
- spec/assets/wordcover.html
|
422
436
|
- spec/assets/wordintro.html
|
423
437
|
- spec/isodoc/blocks_spec.rb
|
@@ -454,7 +468,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
454
468
|
- !ruby/object:Gem::Version
|
455
469
|
version: '0'
|
456
470
|
requirements: []
|
457
|
-
rubygems_version: 3.
|
471
|
+
rubygems_version: 3.1.4
|
458
472
|
signing_key:
|
459
473
|
specification_version: 4
|
460
474
|
summary: Convert documents in IsoDoc into Word and HTML in AsciiDoc.
|