isodoc 0.8.6 → 0.8.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +1 -0
- data/Gemfile.lock +16 -16
- data/isodoc.gemspec +2 -2
- data/lib/isodoc/function/i18n.rb +1 -1
- data/lib/isodoc/function/references.rb +3 -3
- data/lib/isodoc/function/utils.rb +1 -1
- data/lib/isodoc/html_function/html.rb +1 -1
- data/lib/isodoc/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f01104dabca281577926307a587e9999a2731d2d297550f1bab164e06b3edccf
|
4
|
+
data.tar.gz: 64cdd14aff259cf0146693a10a012e02857534a2f7a45b3051b42f8af972df85
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ef626e3f0b6842329ff5ca7ab9b91508c6578898735b3712b1e7b4e1943d3bf7f0775fa6430b8946f4d192343ce2d436bc7144bfb0150e3c68a5b3eada530b73
|
7
|
+
data.tar.gz: 51a3531c9264f52b4da6fdd1e63f40f0429c04ebf265ce84968be93a642e592bad9f2a6d963a252de91c1b2b2538759311413dea403698f53dbfbad70717008a
|
data/.travis.yml
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,12 +1,12 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
isodoc (0.8.
|
4
|
+
isodoc (0.8.7)
|
5
5
|
asciimath
|
6
6
|
html2doc (~> 0.8.1)
|
7
7
|
htmlentities (~> 4.3.4)
|
8
8
|
liquid
|
9
|
-
metanorma (~> 0.2.
|
9
|
+
metanorma (~> 0.2.7)
|
10
10
|
nokogiri
|
11
11
|
roman-numerals
|
12
12
|
ruby-xslt
|
@@ -60,7 +60,7 @@ GEM
|
|
60
60
|
rb-inotify (~> 0.9, >= 0.9.7)
|
61
61
|
ruby_dep (~> 1.2)
|
62
62
|
lumberjack (1.0.13)
|
63
|
-
metanorma (0.2.
|
63
|
+
metanorma (0.2.7)
|
64
64
|
method_source (0.9.0)
|
65
65
|
mime-types (3.1)
|
66
66
|
mime-types-data (~> 3.2015)
|
@@ -85,20 +85,20 @@ GEM
|
|
85
85
|
rb-inotify (0.9.10)
|
86
86
|
ffi (>= 0.5.0, < 2)
|
87
87
|
roman-numerals (0.3.0)
|
88
|
-
rspec (3.
|
89
|
-
rspec-core (~> 3.
|
90
|
-
rspec-expectations (~> 3.
|
91
|
-
rspec-mocks (~> 3.
|
92
|
-
rspec-core (3.
|
93
|
-
rspec-support (~> 3.
|
94
|
-
rspec-expectations (3.
|
88
|
+
rspec (3.8.0)
|
89
|
+
rspec-core (~> 3.8.0)
|
90
|
+
rspec-expectations (~> 3.8.0)
|
91
|
+
rspec-mocks (~> 3.8.0)
|
92
|
+
rspec-core (3.8.0)
|
93
|
+
rspec-support (~> 3.8.0)
|
94
|
+
rspec-expectations (3.8.1)
|
95
95
|
diff-lcs (>= 1.2.0, < 2.0)
|
96
|
-
rspec-support (~> 3.
|
97
|
-
rspec-mocks (3.
|
96
|
+
rspec-support (~> 3.8.0)
|
97
|
+
rspec-mocks (3.8.0)
|
98
98
|
diff-lcs (>= 1.2.0, < 2.0)
|
99
|
-
rspec-support (~> 3.
|
100
|
-
rspec-support (3.
|
101
|
-
rubocop (0.58.
|
99
|
+
rspec-support (~> 3.8.0)
|
100
|
+
rspec-support (3.8.0)
|
101
|
+
rubocop (0.58.2)
|
102
102
|
jaro_winkler (~> 1.5.1)
|
103
103
|
parallel (~> 1.10)
|
104
104
|
parser (>= 2.5, != 2.5.1.1)
|
@@ -106,7 +106,7 @@ GEM
|
|
106
106
|
rainbow (>= 2.2.2, < 4.0)
|
107
107
|
ruby-progressbar (~> 1.7)
|
108
108
|
unicode-display_width (~> 1.0, >= 1.0.1)
|
109
|
-
ruby-progressbar (1.
|
109
|
+
ruby-progressbar (1.10.0)
|
110
110
|
ruby-xslt (0.9.10)
|
111
111
|
ruby_dep (1.5.0)
|
112
112
|
sass (3.5.7)
|
data/isodoc.gemspec
CHANGED
@@ -26,7 +26,7 @@ Gem::Specification.new do |spec|
|
|
26
26
|
spec.require_paths = ["lib"]
|
27
27
|
spec.files = `git ls-files`.split("\n")
|
28
28
|
spec.test_files = `git ls-files -- {spec}/*`.split("\n")
|
29
|
-
spec.required_ruby_version = Gem::Requirement.new(">= 2.
|
29
|
+
spec.required_ruby_version = Gem::Requirement.new(">= 2.3.0")
|
30
30
|
|
31
31
|
spec.add_dependency "asciimath"
|
32
32
|
spec.add_dependency "htmlentities", "~> 4.3.4"
|
@@ -38,7 +38,7 @@ Gem::Specification.new do |spec|
|
|
38
38
|
spec.add_dependency "liquid"
|
39
39
|
spec.add_dependency "roman-numerals"
|
40
40
|
spec.add_dependency "sass"
|
41
|
-
spec.add_dependency "metanorma", "~> 0.2.
|
41
|
+
spec.add_dependency "metanorma", "~> 0.2.7"
|
42
42
|
|
43
43
|
spec.add_development_dependency "bundler", "~> 1.15"
|
44
44
|
spec.add_development_dependency "byebug", "~> 9.1"
|
data/lib/isodoc/function/i18n.rb
CHANGED
@@ -78,7 +78,7 @@ module IsoDoc::Function
|
|
78
78
|
|
79
79
|
# TODO: move to localization file
|
80
80
|
def eref_localities1(type, from, to, lang = "en")
|
81
|
-
subsection = from&.text&.match
|
81
|
+
subsection = from&.text&.match(/\./)
|
82
82
|
return l10n(eref_localities1_zh(type, from, to)) if lang == "zh"
|
83
83
|
ret = ","
|
84
84
|
loc = @locality[type] || type.sub(/^locality:/, "").capitalize
|
@@ -59,7 +59,7 @@ module IsoDoc::Function
|
|
59
59
|
end
|
60
60
|
|
61
61
|
def ref_entry_code(r, ordinal, t)
|
62
|
-
if /^\d+$/.match
|
62
|
+
if /^\d+$/.match(t)
|
63
63
|
prefix_bracketed_ref(r, t)
|
64
64
|
else
|
65
65
|
prefix_bracketed_ref(r, ordinal)
|
@@ -173,7 +173,7 @@ module IsoDoc::Function
|
|
173
173
|
return ref if on&.text == "--"
|
174
174
|
return ref + ":#{date_range(date)}"
|
175
175
|
end
|
176
|
-
return "[#{ref}]" if /^\d+$/.match
|
176
|
+
return "[#{ref}]" if /^\d+$/.match(ref) && !/^\[.*\]$/.match(ref)
|
177
177
|
ref
|
178
178
|
end
|
179
179
|
|
@@ -188,7 +188,7 @@ module IsoDoc::Function
|
|
188
188
|
|
189
189
|
# def ref_names(ref)
|
190
190
|
# linkend = ref.text
|
191
|
-
# linkend.gsub!(/[\[\]]/, "") unless /^\[\d+\]$/.match
|
191
|
+
# linkend.gsub!(/[\[\]]/, "") unless /^\[\d+\]$/.match linkend
|
192
192
|
# @anchors[ref["id"]] = { xref: linkend }
|
193
193
|
# end
|
194
194
|
end
|
@@ -190,7 +190,7 @@ module IsoDoc::HtmlFunction
|
|
190
190
|
def move_images(docxml)
|
191
191
|
system "rm -r #{@tmpimagedir}; mkdir #{@tmpimagedir}"
|
192
192
|
docxml.xpath("//*[local-name() = 'img']").each do |i|
|
193
|
-
next if /^data:image/.match
|
193
|
+
next if /^data:image/.match i["src"]
|
194
194
|
matched = /\.(?<suffix>\S+)$/.match i["src"]
|
195
195
|
uuid = UUIDTools::UUID.random_create.to_s
|
196
196
|
new_full_filename = File.join(@tmpimagedir, "#{uuid}.#{matched[:suffix]}")
|
data/lib/isodoc/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: isodoc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.8.
|
4
|
+
version: 0.8.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
@@ -156,14 +156,14 @@ dependencies:
|
|
156
156
|
requirements:
|
157
157
|
- - "~>"
|
158
158
|
- !ruby/object:Gem::Version
|
159
|
-
version: 0.2.
|
159
|
+
version: 0.2.7
|
160
160
|
type: :runtime
|
161
161
|
prerelease: false
|
162
162
|
version_requirements: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
164
|
- - "~>"
|
165
165
|
- !ruby/object:Gem::Version
|
166
|
-
version: 0.2.
|
166
|
+
version: 0.2.7
|
167
167
|
- !ruby/object:Gem::Dependency
|
168
168
|
name: bundler
|
169
169
|
requirement: !ruby/object:Gem::Requirement
|
@@ -403,7 +403,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
403
403
|
requirements:
|
404
404
|
- - ">="
|
405
405
|
- !ruby/object:Gem::Version
|
406
|
-
version: 2.
|
406
|
+
version: 2.3.0
|
407
407
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
408
408
|
requirements:
|
409
409
|
- - ">="
|