metanorma-ieee 1.3.2 → 1.3.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/isodoc/ieee/base_convert.rb +0 -25
- data/lib/isodoc/ieee/ieee.amendment.xsl +251 -55
- data/lib/isodoc/ieee/ieee.standard.xsl +251 -55
- data/lib/isodoc/ieee/presentation_ref.rb +14 -0
- data/lib/isodoc/ieee/presentation_terms.rb +18 -3
- data/lib/isodoc/ieee/presentation_xml_convert.rb +12 -9
- data/lib/isodoc/ieee/word_authority.rb +6 -6
- data/lib/isodoc/ieee/word_cleanup_blocks.rb +0 -1
- data/lib/isodoc/ieee/word_convert.rb +0 -1
- data/lib/isodoc/ieee/word_wp_convert.rb +0 -1
- data/lib/metanorma/ieee/isodoc.rng +1 -1
- data/lib/metanorma/ieee/version.rb +1 -1
- data/metanorma-ieee.gemspec +1 -1
- metadata +4 -4
@@ -10,8 +10,7 @@ module IsoDoc
|
|
10
10
|
c = IsoDoc::XrefGen::Counter.new("@")
|
11
11
|
elem.xpath(ns("./definition")).each do |d|
|
12
12
|
c.increment(d)
|
13
|
-
d.elements.first.
|
14
|
-
"<strong>(#{c.print})</strong> "
|
13
|
+
d.elements.first.add_first_child "<strong>(#{c.print})</strong> "
|
15
14
|
end
|
16
15
|
end
|
17
16
|
|
@@ -214,6 +213,13 @@ module IsoDoc
|
|
214
213
|
end
|
215
214
|
end
|
216
215
|
|
216
|
+
# domain is rendered in designation_field instead
|
217
|
+
def termdomain(elem)
|
218
|
+
d = elem.at(ns(".//domain")) or return
|
219
|
+
d["hidden"] = "true"
|
220
|
+
end
|
221
|
+
|
222
|
+
# TODO wrap domain not in <domain>, but <span class="domain"> or equivalent
|
217
223
|
def designation_field(desgn, name)
|
218
224
|
if desgn.name == "preferred"
|
219
225
|
f = desgn.xpath(ns("./../domain | ./../subject")).map(&:remove)
|
@@ -235,11 +241,20 @@ module IsoDoc
|
|
235
241
|
pref << " (#{tail})"
|
236
242
|
end
|
237
243
|
|
244
|
+
def termnote_delim(_elem)
|
245
|
+
"—"
|
246
|
+
end
|
247
|
+
|
238
248
|
def termnote1(elem)
|
239
|
-
lbl =
|
249
|
+
lbl = termnote_label(elem)
|
240
250
|
prefix_name(elem, block_delim, lower2cap(lbl), "name")
|
241
251
|
end
|
242
252
|
|
253
|
+
def termnote_label(elem)
|
254
|
+
lbl = l10n(@xrefs.anchor(elem["id"], :label)&.strip || "???")
|
255
|
+
l10n "#{lbl}#{termnote_delim(elem)}"
|
256
|
+
end
|
257
|
+
|
243
258
|
def term(docxml); end
|
244
259
|
|
245
260
|
def concept1(node)
|
@@ -18,8 +18,9 @@ module IsoDoc
|
|
18
18
|
ret = resolve_eref_connectives(eref_locality_stacks(refs, target,
|
19
19
|
node))
|
20
20
|
node["droploc"] = droploc
|
21
|
+
p = prefix_clause(target, refs.first.at(ns("./locality")))
|
21
22
|
eref_localities1({ target: target, number: "pl",
|
22
|
-
type:
|
23
|
+
type: p,
|
23
24
|
from: l10n(ret[1..-1].join), node: node,
|
24
25
|
lang: @lang })
|
25
26
|
end
|
@@ -72,13 +73,8 @@ module IsoDoc
|
|
72
73
|
"—"
|
73
74
|
end
|
74
75
|
|
75
|
-
def
|
76
|
-
|
77
|
-
n = @xrefs.get[elem["id"]]
|
78
|
-
lbl = if n.nil? || n[:label].nil? || n[:label].empty? then @i18n.note
|
79
|
-
else l10n("#{@i18n.note} #{n[:label]}")
|
80
|
-
end
|
81
|
-
prefix_name(elem, block_delim, lbl, "name")
|
76
|
+
def note_delim(_elem)
|
77
|
+
"—"
|
82
78
|
end
|
83
79
|
|
84
80
|
def annex1(elem)
|
@@ -95,7 +91,7 @@ module IsoDoc
|
|
95
91
|
t.name = "variant-title"
|
96
92
|
t["type"] = "sub"
|
97
93
|
end
|
98
|
-
elem.
|
94
|
+
elem.add_first_child "<title>#{lbl}</title>"
|
99
95
|
end
|
100
96
|
|
101
97
|
def annex1_default(elem)
|
@@ -216,6 +212,13 @@ module IsoDoc
|
|
216
212
|
dest.children.first.next = source
|
217
213
|
end
|
218
214
|
|
215
|
+
def example1(elem)
|
216
|
+
super
|
217
|
+
n = elem.at(ns("./name")) or return
|
218
|
+
n << l10n(":")
|
219
|
+
n.children.wrap("<em></em>")
|
220
|
+
end
|
221
|
+
|
219
222
|
include Init
|
220
223
|
end
|
221
224
|
end
|
@@ -153,9 +153,9 @@ module IsoDoc
|
|
153
153
|
def feedback_style1(div, idx)
|
154
154
|
div.xpath(".//p").each_with_index do |p, j|
|
155
155
|
p["class"] = idx == 4 ? "IEEEStdsCRTextItal" : "IEEEStdsCRTextReg"
|
156
|
-
j.zero? && idx.zero? and
|
157
|
-
|
158
|
-
|
156
|
+
j.zero? && idx.zero? and p.add_first_child <<~XML
|
157
|
+
<a style="mso-footnote-id:ftn0" href="#_ftnref0" name="_ftn0" title=""/>
|
158
|
+
XML
|
159
159
|
end
|
160
160
|
end
|
161
161
|
|
@@ -203,9 +203,9 @@ module IsoDoc
|
|
203
203
|
end
|
204
204
|
|
205
205
|
def abstract_header(dest)
|
206
|
-
dest.elements.first.
|
207
|
-
|
208
|
-
|
206
|
+
dest.elements.first.add_first_child <<~XML
|
207
|
+
<span class='IEEEStdsAbstractHeader'><span lang='EN-US'>Abstract:</span></span>
|
208
|
+
XML
|
209
209
|
end
|
210
210
|
|
211
211
|
def introduction_cleanup(docxml)
|
@@ -17,7 +17,7 @@
|
|
17
17
|
these elements; we just want one namespace for any child grammars
|
18
18
|
of this.
|
19
19
|
-->
|
20
|
-
<!-- VERSION v1.
|
20
|
+
<!-- VERSION v1.4.0 -->
|
21
21
|
<grammar xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0" xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
|
22
22
|
<include href="reqt.rng"/>
|
23
23
|
<include href="basicdoc.rng">
|
data/metanorma-ieee.gemspec
CHANGED
@@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
|
|
25
25
|
spec.require_paths = ["lib"]
|
26
26
|
spec.required_ruby_version = Gem::Requirement.new(">= 3.1.0")
|
27
27
|
|
28
|
-
spec.add_dependency "metanorma-standoc", "~> 2.
|
28
|
+
spec.add_dependency "metanorma-standoc", "~> 2.10.0"
|
29
29
|
spec.add_dependency "mnconvert", "~> 1.20"
|
30
30
|
spec.add_dependency "pubid"
|
31
31
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-ieee
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.
|
4
|
+
version: 1.3.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-11-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: metanorma-standoc
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 2.
|
19
|
+
version: 2.10.0
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 2.
|
26
|
+
version: 2.10.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: mnconvert
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|