metanorma-jis 0.2.12 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/isodoc/jis/base_convert.rb +20 -0
- data/lib/isodoc/jis/init.rb +5 -0
- data/lib/isodoc/jis/jis.international-standard.xsl +945 -929
- data/lib/isodoc/jis/presentation_xml_convert.rb +3 -2
- data/lib/isodoc/jis/xref.rb +12 -1
- data/lib/metanorma/jis/isodoc.rng +5 -5
- data/lib/metanorma/jis/version.rb +1 -1
- data/lib/relaton/render-jis/general.rb +21 -0
- data/lib/relaton/render-jis/parse.rb +23 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1aab80a7925f249d9da43542593dcb44fbf35c6e444e47b43c2d409f6b5e6337
|
4
|
+
data.tar.gz: 0f25e20b71e7410dca4bdbc7f7484cea9926fd198d480a52a5213e19194af60b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a3e77efa2a97c6faf8f6419d9d73d77b99da0682f668df17113516c75d7b8d33625ec56274a5996d576d8dffdf6816df2699ab9c080fcce06ee9be30e89c5fcc
|
7
|
+
data.tar.gz: cfc8462eb1314e15cd7c163d4f767c61a1b84631c1159851110398e559722e9dbadb743f3920c6255f868656c6573bab0748e0dcb9b2c9bd2cd479355c44ab93
|
@@ -63,6 +63,13 @@ module IsoDoc
|
|
63
63
|
super
|
64
64
|
end
|
65
65
|
|
66
|
+
def table_parse_tail(node, out)
|
67
|
+
node.xpath(ns("./p[@class = 'ListTitle' or @class = 'dl']"))
|
68
|
+
.each { |p| parse(p, out) }
|
69
|
+
node.xpath(ns("./source")).each { |n| parse(n, out) }
|
70
|
+
node.xpath(ns("./note")).each { |n| parse(n, out) }
|
71
|
+
end
|
72
|
+
|
66
73
|
def table_thead_pt(node, name)
|
67
74
|
node.at(ns("./thead")) ||
|
68
75
|
name&.after("<thead> </thead>")&.next ||
|
@@ -87,6 +94,19 @@ module IsoDoc
|
|
87
94
|
full_row(cols, "<p class='TableTitle' style='text-align:center;'> " \
|
88
95
|
"#{name.remove.children.to_xml}</p>")
|
89
96
|
end
|
97
|
+
|
98
|
+
def table_note_cleanup(docxml)
|
99
|
+
tn = ::IsoDoc::Function::Cleanup::TABLENOTE_CSS
|
100
|
+
docxml.xpath("//table[dl or #{tn} or p[@class = 'dl']]").each do |t|
|
101
|
+
tfoot = table_get_or_make_tfoot(t)
|
102
|
+
insert_here = new_fullcolspan_row(t, tfoot)
|
103
|
+
t.xpath("dl | p[@class = 'ListTitle'] | #{tn} | " \
|
104
|
+
"p[@class = 'dl']")
|
105
|
+
.each do |d|
|
106
|
+
d.parent = insert_here
|
107
|
+
end
|
108
|
+
end
|
109
|
+
end
|
90
110
|
end
|
91
111
|
end
|
92
112
|
end
|
data/lib/isodoc/jis/init.rb
CHANGED
@@ -20,6 +20,11 @@ module IsoDoc
|
|
20
20
|
i18nyaml: i18nyaml || @i18nyaml)
|
21
21
|
end
|
22
22
|
|
23
|
+
def bibrenderer(options = {})
|
24
|
+
::Relaton::Render::JIS::General.new(options.merge(language: @lang,
|
25
|
+
i18nhash: @i18n.get))
|
26
|
+
end
|
27
|
+
|
23
28
|
def omit_docid_prefix(prefix)
|
24
29
|
return true if prefix.nil? || prefix.empty?
|
25
30
|
|