metanorma-itu 2.4.2 → 2.4.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/isodoc/itu/base_convert.rb +44 -21
- data/lib/isodoc/itu/i18n-ar.yaml +3 -0
- data/lib/isodoc/itu/i18n-de.yaml +3 -0
- data/lib/isodoc/itu/i18n-en.yaml +3 -0
- data/lib/isodoc/itu/i18n-es.yaml +3 -0
- data/lib/isodoc/itu/i18n-fr.yaml +3 -0
- data/lib/isodoc/itu/i18n-ru.yaml +3 -0
- data/lib/isodoc/itu/i18n-zh-Hans.yaml +3 -0
- data/lib/isodoc/itu/init.rb +5 -0
- data/lib/isodoc/itu/itu.implementers-guide.xsl +1407 -698
- data/lib/isodoc/itu/itu.in-force.xsl +1407 -698
- data/lib/isodoc/itu/itu.recommendation-annex.xsl +1407 -698
- data/lib/isodoc/itu/itu.recommendation-supplement.xsl +1407 -698
- data/lib/isodoc/itu/itu.recommendation.xsl +1407 -698
- data/lib/isodoc/itu/itu.resolution.xsl +1407 -698
- data/lib/isodoc/itu/itu.service-publication.xsl +1407 -698
- data/lib/isodoc/itu/itu.technical-paper.xsl +1407 -698
- data/lib/isodoc/itu/itu.technical-report.xsl +1407 -698
- data/lib/isodoc/itu/presentation_ref.rb +92 -0
- data/lib/isodoc/itu/presentation_xml_convert.rb +49 -84
- data/lib/metanorma/itu/biblio.rng +28 -25
- data/lib/metanorma/itu/cleanup.rb +7 -0
- data/lib/metanorma/itu/converter.rb +7 -7
- data/lib/metanorma/itu/version.rb +1 -1
- data/metanorma-itu.gemspec +2 -1
- metadata +19 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 88c9cda54d65dc977de6157a86d64cb8b3b977a347fe637d813abd77b882c541
|
4
|
+
data.tar.gz: 16c113945987104a36166192a7eb94d0974ba4b16b68a3330930656de0366c8a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 69c3ec98cef4498116163748e8df52e9a916f0c8deaff2a304b22e3833762b484834f76498dd5e790e60692552a8cf6954bb3837ec16686848239ba0159d1ba5
|
7
|
+
data.tar.gz: c34d03b056b582e885de905006b18c96a5b22bd23cc998882dc9c99a082873e9ee2d55f91f506683e4d68e5b6b89fa45968b9518cdf0465c6d4b1722a4e64e09
|
@@ -48,9 +48,8 @@ module IsoDoc
|
|
48
48
|
end
|
49
49
|
|
50
50
|
def ol_depth(node)
|
51
|
-
|
52
|
-
node.at(".//ancestor::xmlns:ol[@class = 'steps']")
|
53
|
-
|
51
|
+
node["class"] == "steps" ||
|
52
|
+
node.at(".//ancestor::xmlns:ol[@class = 'steps']") or return super
|
54
53
|
depth = node.ancestors("ul, ol").size + 1
|
55
54
|
type = :arabic
|
56
55
|
type = :alphabet if [2, 7].include? depth
|
@@ -78,17 +77,17 @@ module IsoDoc
|
|
78
77
|
end
|
79
78
|
|
80
79
|
def annex(node, out)
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
end
|
80
|
+
@meta.get[:doctype_original] == "recommendation-annex" or
|
81
|
+
page_break(out)
|
82
|
+
out.div **attr_code(id: node["id"], class: "Section3") do |s|
|
83
|
+
annex_name(node, nil, s) unless node.at(ns("./title"))
|
84
|
+
node.elements.each do |c1|
|
85
|
+
if c1.name == "title" then annex_name(node, c1, s)
|
86
|
+
else
|
87
|
+
parse(c1, s)
|
90
88
|
end
|
91
89
|
end
|
90
|
+
end
|
92
91
|
end
|
93
92
|
|
94
93
|
def info(isoxml, out)
|
@@ -124,8 +123,7 @@ module IsoDoc
|
|
124
123
|
end
|
125
124
|
|
126
125
|
def note_parse(node, out)
|
127
|
-
|
128
|
-
|
126
|
+
node["type"] == "title-footnote" and return
|
129
127
|
super
|
130
128
|
end
|
131
129
|
|
@@ -148,15 +146,40 @@ module IsoDoc
|
|
148
146
|
end
|
149
147
|
end
|
150
148
|
|
151
|
-
|
152
|
-
|
153
|
-
|
149
|
+
def dl_parse(node, out)
|
150
|
+
node.ancestors("table, formula, figure").empty? or return super
|
151
|
+
dl1(node)
|
152
|
+
table_parse(node, out)
|
153
|
+
end
|
154
154
|
|
155
|
-
|
156
|
-
|
157
|
-
|
155
|
+
def dl1(dlist)
|
156
|
+
ret = dl2tbody(dlist)
|
157
|
+
n = dlist.at(ns("./colgroup")) and ret = "#{n.remove.to_xml}#{ret}"
|
158
|
+
n = dlist.at(ns("./name")) and ret = "#{n.remove.to_xml}#{ret}"
|
159
|
+
dlist.name = "table"
|
160
|
+
dlist["class"] = "dl"
|
161
|
+
dlist.children.first.previous = ret
|
158
162
|
end
|
159
|
-
|
163
|
+
|
164
|
+
def dl2tbody(dlist)
|
165
|
+
ret = ""
|
166
|
+
dlist.elements.select { |n| %w{dt dd}.include? n.name }
|
167
|
+
.each_slice(2) do |dt, dd|
|
168
|
+
ret += "<tr><th width='20%'>#{dt.children.to_xml}</th>" \
|
169
|
+
"<td width='80%'>#{dd.children.to_xml}</td></tr>"
|
170
|
+
dt.replace(" ")
|
171
|
+
dd.remove
|
172
|
+
end
|
173
|
+
"<tbody>#{ret}</tbody>"
|
174
|
+
end
|
175
|
+
|
176
|
+
# def scope(isoxml, out, num)
|
177
|
+
# return super unless @meta.get[:doctype_original] == "resolution"
|
178
|
+
#
|
179
|
+
# f = isoxml.at(ns("//clause[@type = 'scope']")) or return num
|
180
|
+
# clause_core(f, out)
|
181
|
+
# num + 1
|
182
|
+
# end
|
160
183
|
end
|
161
184
|
end
|
162
185
|
end
|
data/lib/isodoc/itu/i18n-ar.yaml
CHANGED
@@ -58,6 +58,9 @@ revision_abbreviation: المراجعة
|
|
58
58
|
tsb: TSB
|
59
59
|
br: BR
|
60
60
|
bdt: BDT
|
61
|
+
tsb_short: مكتب تقييس الاتصالات
|
62
|
+
br_short: مكتب الاتصالات الراديوية
|
63
|
+
bdt_short: مكتب تنمية الاتصالات
|
61
64
|
tsb_full: مكتب تقييس الاتصالات
|
62
65
|
br_full: مكتب الاتصالات الراديوية
|
63
66
|
bdt_full: مكتب تنمية الاتصالات
|
data/lib/isodoc/itu/i18n-de.yaml
CHANGED
@@ -59,6 +59,9 @@ revision_abbreviation: Rev.
|
|
59
59
|
tsb: TSB
|
60
60
|
br: BR
|
61
61
|
bdt: BDT
|
62
|
+
tsb_short: Büro für Telekommunikations-Standardisierung
|
63
|
+
br_short: Büro für Funkkommunikation
|
64
|
+
bdt_short: Büro für Entwicklungen in der Telekommunikation
|
62
65
|
tsb_full: Büro für Telekommunikations-<br/>Standardisierung<br/>der ITU
|
63
66
|
br_full: Büro für Funkkommunikation<br/>der ITU
|
64
67
|
bdt_full: Büro für Entwicklungen<br/>in der Telekommunikation<br/>der ITU
|
data/lib/isodoc/itu/i18n-en.yaml
CHANGED
@@ -60,6 +60,9 @@ revision_abbreviation: Rev.
|
|
60
60
|
tsb: TSB
|
61
61
|
br: BR
|
62
62
|
bdt: BDT
|
63
|
+
tsb_short: Telecommunication Standardization Bureau
|
64
|
+
br_short: Radiocommunication Bureau
|
65
|
+
bdt_short: Telecommunication Development Bureau
|
63
66
|
tsb_full: Telecommunication<br/>Standardization Bureau<br/>of ITU
|
64
67
|
br_full: Radiocommunication Bureau<br/>of ITU
|
65
68
|
bdt_full: Telecommunication<br/>Development Bureau<br/>of ITU
|
data/lib/isodoc/itu/i18n-es.yaml
CHANGED
@@ -60,6 +60,9 @@ revision_abbreviation: Rev.
|
|
60
60
|
tsb: TSB
|
61
61
|
br: BR
|
62
62
|
bdt: BDT
|
63
|
+
tsb_short: Oficina de Normalización de las Telecomunicaciones
|
64
|
+
br_short: Oficina de Radiocomunicaciones
|
65
|
+
bdt_short: Oficina de Desarrollo de las Telecomunicaciones
|
63
66
|
tsb_full: <br/>Oficina de Normalización<br/>de las Telecomunicaciones de la UIT
|
64
67
|
br_full: Oficina de Radiocomunicaciones<br/>de la UIT
|
65
68
|
bdt_full: <br/>Oficina de Desarrollo<br/>de las Telecomunicaciones de la UIT
|
data/lib/isodoc/itu/i18n-fr.yaml
CHANGED
@@ -60,6 +60,9 @@ revision_abbreviation: Rev.
|
|
60
60
|
tsb: TSB
|
61
61
|
br: BR
|
62
62
|
bdt: BDT
|
63
|
+
tsb_short: Bureau de la normalisation des télécommunications
|
64
|
+
br_short: Bureau des radiocommunications
|
65
|
+
bdt_short: Bureau de développement des télécommunications
|
63
66
|
tsb_full: Bureau de la normalisation<br/>des télécommunications<br/>de l’UIT
|
64
67
|
br_full: Bureau des radiocommunications<br/>de l’UIT
|
65
68
|
bdt_full: Bureau de développement<br/>des télécommunications<br/>de l’UIT
|
data/lib/isodoc/itu/i18n-ru.yaml
CHANGED
@@ -60,6 +60,9 @@ revision_abbreviation: Ред.
|
|
60
60
|
tsb: БСЭ
|
61
61
|
br: БР
|
62
62
|
bdt: БРЭ
|
63
|
+
tsb_short: Бюро стандартизации электросвязи
|
64
|
+
br_short: Бюро радиосвязи
|
65
|
+
bdt_short: Бюро развития электросвязи
|
63
66
|
tsb_full: Бюро стандартизации электросвязи<br/>МСЭ
|
64
67
|
br_full: Бюро радиосвязи<br/>МСЭ
|
65
68
|
bdt_full: Бюро развития электросвязи<br/>МСЭ
|
data/lib/isodoc/itu/init.rb
CHANGED
@@ -21,6 +21,11 @@ module IsoDoc
|
|
21
21
|
i18nyaml: i18nyaml || @i18nyaml)
|
22
22
|
end
|
23
23
|
|
24
|
+
def bibrenderer(options = {})
|
25
|
+
::Relaton::Render::ITU::General.new(options.merge(language: @lang,
|
26
|
+
i18nhash: @i18n.get))
|
27
|
+
end
|
28
|
+
|
24
29
|
def fileloc(loc)
|
25
30
|
File.join(File.dirname(__FILE__), loc)
|
26
31
|
end
|