metanorma-ieee 0.0.6 → 0.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.devel +1 -0
- data/lib/isodoc/ieee/html/htmlstyle.css +1028 -0
- data/lib/isodoc/ieee/html/ieee.css +3600 -0
- data/lib/isodoc/ieee/html/ieee.scss +218 -13
- data/lib/isodoc/ieee/html/word_ieee_intro.html +2 -2
- data/lib/isodoc/ieee/html/wordstyle.css +5307 -0
- data/lib/isodoc/ieee/ieee.amendment.xsl +12 -0
- data/lib/isodoc/ieee/ieee.standard.xsl +12 -0
- data/lib/isodoc/ieee/init.rb +5 -4
- data/lib/isodoc/ieee/word_authority.rb +1 -1
- data/lib/isodoc/ieee/word_cleanup.rb +1 -1
- data/lib/isodoc/ieee/word_convert.rb +2 -2
- data/lib/isodoc/ieee/xref.rb +0 -5
- data/lib/metanorma/ieee/biblio.rng +32 -1
- data/lib/metanorma/ieee/cleanup.rb +1 -1
- data/lib/metanorma/ieee/cleanup_ref.rb +3 -3
- data/lib/metanorma/ieee/version.rb +1 -1
- data/lib/metanorma-ieee.rb +1 -0
- data/lib/relaton/render/config.yml +1 -1
- data/{metanorma-itu.gemspec → metanorma-ieee.gemspec} +1 -1
- metadata +9 -5
@@ -9623,6 +9623,18 @@
|
|
9623
9623
|
</xsl:copy>
|
9624
9624
|
</xsl:template>
|
9625
9625
|
|
9626
|
+
<xsl:template match="*[local-name() = 'sub']" mode="contents_item">
|
9627
|
+
<xsl:copy>
|
9628
|
+
<xsl:apply-templates mode="contents_item"/>
|
9629
|
+
</xsl:copy>
|
9630
|
+
</xsl:template>
|
9631
|
+
|
9632
|
+
<xsl:template match="*[local-name() = 'sup']" mode="contents_item">
|
9633
|
+
<xsl:copy>
|
9634
|
+
<xsl:apply-templates mode="contents_item"/>
|
9635
|
+
</xsl:copy>
|
9636
|
+
</xsl:template>
|
9637
|
+
|
9626
9638
|
<xsl:template match="*[local-name() = 'stem']" mode="contents_item">
|
9627
9639
|
<xsl:copy-of select="."/>
|
9628
9640
|
</xsl:template>
|
@@ -9623,6 +9623,18 @@
|
|
9623
9623
|
</xsl:copy>
|
9624
9624
|
</xsl:template>
|
9625
9625
|
|
9626
|
+
<xsl:template match="*[local-name() = 'sub']" mode="contents_item">
|
9627
|
+
<xsl:copy>
|
9628
|
+
<xsl:apply-templates mode="contents_item"/>
|
9629
|
+
</xsl:copy>
|
9630
|
+
</xsl:template>
|
9631
|
+
|
9632
|
+
<xsl:template match="*[local-name() = 'sup']" mode="contents_item">
|
9633
|
+
<xsl:copy>
|
9634
|
+
<xsl:apply-templates mode="contents_item"/>
|
9635
|
+
</xsl:copy>
|
9636
|
+
</xsl:template>
|
9637
|
+
|
9626
9638
|
<xsl:template match="*[local-name() = 'stem']" mode="contents_item">
|
9627
9639
|
<xsl:copy-of select="."/>
|
9628
9640
|
</xsl:template>
|
data/lib/isodoc/ieee/init.rb
CHANGED
@@ -6,8 +6,8 @@ require_relative "i18n"
|
|
6
6
|
module IsoDoc
|
7
7
|
module IEEE
|
8
8
|
module Init
|
9
|
-
def metadata_init(lang, script, i18n)
|
10
|
-
@meta = Metadata.new(lang, script, i18n)
|
9
|
+
def metadata_init(lang, script, locale, i18n)
|
10
|
+
@meta = Metadata.new(lang, script, locale, i18n)
|
11
11
|
end
|
12
12
|
|
13
13
|
def xref_init(lang, script, _klass, i18n, options)
|
@@ -16,8 +16,9 @@ module IsoDoc
|
|
16
16
|
@xrefs = Xref.new(lang, script, html, i18n, options)
|
17
17
|
end
|
18
18
|
|
19
|
-
def i18n_init(lang, script, i18nyaml = nil)
|
20
|
-
@i18n = I18n.new(lang, script,
|
19
|
+
def i18n_init(lang, script, locale, i18nyaml = nil)
|
20
|
+
@i18n = I18n.new(lang, script, locale: locale,
|
21
|
+
i18nyaml: i18nyaml || @i18nyaml)
|
21
22
|
end
|
22
23
|
|
23
24
|
def fileloc(loc)
|
@@ -114,7 +114,7 @@ module IsoDoc
|
|
114
114
|
para = i % 2 == 1 && i != ret.size - 2 ? "<p> </p>" : ""
|
115
115
|
"<div class='WordSection'>#{para}#{d}</div>"
|
116
116
|
end.join(SECTIONBREAK)
|
117
|
-
div.document.at("//div[@class = '
|
117
|
+
div.document.at("//div[@class = 'WordSectionIntro']")
|
118
118
|
.previous_element.previous = SECTIONBREAK + out
|
119
119
|
end
|
120
120
|
|
@@ -57,11 +57,11 @@ module IsoDoc
|
|
57
57
|
end
|
58
58
|
|
59
59
|
def make_body3(body, docxml)
|
60
|
-
body.div **{ class: "
|
60
|
+
body.div **{ class: "WordSectionMiddleTitle" } do |_div3|
|
61
61
|
middle_title_ieee(docxml, body)
|
62
62
|
end
|
63
63
|
section_break(body, continuous: true)
|
64
|
-
body.div **{ class: "
|
64
|
+
body.div **{ class: "WordSectionMain" } do |div3|
|
65
65
|
middle docxml, div3
|
66
66
|
footnotes div3
|
67
67
|
comments div3
|
data/lib/isodoc/ieee/xref.rb
CHANGED
@@ -34,11 +34,6 @@ module IsoDoc
|
|
34
34
|
n = section_names(doc.at(ns("//sections/definitions")), n, 1)
|
35
35
|
clause_names(doc, n)
|
36
36
|
end
|
37
|
-
if @parse_settings.empty?
|
38
|
-
middle_section_asset_names(doc)
|
39
|
-
termnote_anchor_names(doc)
|
40
|
-
termexample_anchor_names(doc)
|
41
|
-
end
|
42
37
|
end
|
43
38
|
|
44
39
|
def middle_sections
|
@@ -73,8 +73,14 @@
|
|
73
73
|
<text/>
|
74
74
|
</element>
|
75
75
|
</define>
|
76
|
-
<define name="
|
76
|
+
<define name="locale">
|
77
77
|
<a:documentation>ISO-639</a:documentation>
|
78
|
+
<element name="locale">
|
79
|
+
<text/>
|
80
|
+
</element>
|
81
|
+
</define>
|
82
|
+
<define name="script">
|
83
|
+
<a:documentation>ISO-3166</a:documentation>
|
78
84
|
<element name="script">
|
79
85
|
<text/>
|
80
86
|
</element>
|
@@ -93,6 +99,9 @@
|
|
93
99
|
<!-- multiple languages and scripts possible: comma delimit them if so -->
|
94
100
|
<attribute name="language"/>
|
95
101
|
</optional>
|
102
|
+
<optional>
|
103
|
+
<attribute name="locale"/>
|
104
|
+
</optional>
|
96
105
|
<optional>
|
97
106
|
<attribute name="script"/>
|
98
107
|
</optional>
|
@@ -136,6 +145,9 @@
|
|
136
145
|
<!-- multiple languages and scripts possible: comma delimit them if so -->
|
137
146
|
<attribute name="language"/>
|
138
147
|
</optional>
|
148
|
+
<optional>
|
149
|
+
<attribute name="locale"/>
|
150
|
+
</optional>
|
139
151
|
<optional>
|
140
152
|
<attribute name="script"/>
|
141
153
|
</optional>
|
@@ -650,6 +662,9 @@
|
|
650
662
|
<zeroOrMore>
|
651
663
|
<ref name="language"/>
|
652
664
|
</zeroOrMore>
|
665
|
+
<zeroOrMore>
|
666
|
+
<ref name="locale"/>
|
667
|
+
</zeroOrMore>
|
653
668
|
<zeroOrMore>
|
654
669
|
<ref name="script"/>
|
655
670
|
</zeroOrMore>
|
@@ -741,6 +756,9 @@
|
|
741
756
|
<zeroOrMore>
|
742
757
|
<ref name="language"/>
|
743
758
|
</zeroOrMore>
|
759
|
+
<zeroOrMore>
|
760
|
+
<ref name="locale"/>
|
761
|
+
</zeroOrMore>
|
744
762
|
<zeroOrMore>
|
745
763
|
<ref name="script"/>
|
746
764
|
</zeroOrMore>
|
@@ -854,6 +872,15 @@
|
|
854
872
|
<optional>
|
855
873
|
<attribute name="type"/>
|
856
874
|
</optional>
|
875
|
+
<optional>
|
876
|
+
<attribute name="language"/>
|
877
|
+
</optional>
|
878
|
+
<optional>
|
879
|
+
<attribute name="locale"/>
|
880
|
+
</optional>
|
881
|
+
<optional>
|
882
|
+
<attribute name="script"/>
|
883
|
+
</optional>
|
857
884
|
<data type="anyURI"/>
|
858
885
|
</define>
|
859
886
|
<define name="DateType">
|
@@ -882,6 +909,7 @@
|
|
882
909
|
<value>vote-started</value>
|
883
910
|
<value>vote-ended</value>
|
884
911
|
<value>announced</value>
|
912
|
+
<value>stable-until</value>
|
885
913
|
</choice>
|
886
914
|
</define>
|
887
915
|
<define name="bdate">
|
@@ -930,6 +958,9 @@
|
|
930
958
|
<optional>
|
931
959
|
<attribute name="language"/>
|
932
960
|
</optional>
|
961
|
+
<optional>
|
962
|
+
<attribute name="locale"/>
|
963
|
+
</optional>
|
933
964
|
<optional>
|
934
965
|
<attribute name="script"/>
|
935
966
|
</optional>
|
@@ -117,7 +117,7 @@ module Metanorma
|
|
117
117
|
x = xmldoc.dup
|
118
118
|
x.root.add_namespace(nil, self.class::XML_NAMESPACE)
|
119
119
|
xml = Nokogiri::XML(x.to_xml)
|
120
|
-
i = isodoc(@lang, @script)
|
120
|
+
i = isodoc(@lang, @script, @locale)
|
121
121
|
i.bibdata_i18n(xml.at("//xmlns:bibdata"))
|
122
122
|
i.info(xml, nil)
|
123
123
|
i
|
@@ -47,9 +47,9 @@ module Metanorma
|
|
47
47
|
else
|
48
48
|
bib1 = bib.dup
|
49
49
|
bib1.add_namespace(nil, self.class::XML_NAMESPACE)
|
50
|
-
i = IsoDoc::IEEE::PresentationXMLConvert
|
51
|
-
|
52
|
-
i.i18n_init(@lang, @script)
|
50
|
+
i = IsoDoc::IEEE::PresentationXMLConvert
|
51
|
+
.new({ lang: @lang, script: @script, locale: @locale })
|
52
|
+
i.i18n_init(@lang, @script, @locale)
|
53
53
|
i.creatornames(bib1)
|
54
54
|
end
|
55
55
|
end
|
data/lib/metanorma-ieee.rb
CHANGED
@@ -5,7 +5,7 @@ nametemplate:
|
|
5
5
|
extenttemplate:
|
6
6
|
misc: "{{ volume }}, {{issue}}, {{ page }}, {{ duration }}"
|
7
7
|
template:
|
8
|
-
# skip
|
8
|
+
# skip authoritative_identifier, it is inserted in front of formattedref within metanorma
|
9
9
|
standard: "{{ title }}."
|
10
10
|
techreport: standard
|
11
11
|
article: "{{creatornames}}, “{{title}},” <em>{{ series }}</em>, {{ extent }}, {{ date }}, {{ labels['viewed'] }}_{{date_accessed}}, {{ uri }} ."
|
@@ -24,7 +24,7 @@ Gem::Specification.new do |spec|
|
|
24
24
|
spec.require_paths = ["lib"]
|
25
25
|
spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0")
|
26
26
|
|
27
|
-
spec.add_dependency "metanorma-standoc", "~> 2.2.
|
27
|
+
spec.add_dependency "metanorma-standoc", "~> 2.2.4"
|
28
28
|
|
29
29
|
spec.add_development_dependency "debug"
|
30
30
|
spec.add_development_dependency "equivalent-xml", "~> 0.6"
|
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: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-09-
|
11
|
+
date: 2022-09-26 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.2.
|
19
|
+
version: 2.2.4
|
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.2.
|
26
|
+
version: 2.2.4
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: debug
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -207,6 +207,7 @@ files:
|
|
207
207
|
- ".rubocop.yml"
|
208
208
|
- CODE_OF_CONDUCT.md
|
209
209
|
- Gemfile
|
210
|
+
- Gemfile.devel
|
210
211
|
- LICENSE
|
211
212
|
- README.adoc
|
212
213
|
- Rakefile
|
@@ -222,11 +223,14 @@ files:
|
|
222
223
|
- lib/isodoc/ieee/html/header_amd.html
|
223
224
|
- lib/isodoc/ieee/html/html_ieee_intro.html
|
224
225
|
- lib/isodoc/ieee/html/html_ieee_titlepage.html
|
226
|
+
- lib/isodoc/ieee/html/htmlstyle.css
|
225
227
|
- lib/isodoc/ieee/html/htmlstyle.scss
|
228
|
+
- lib/isodoc/ieee/html/ieee.css
|
226
229
|
- lib/isodoc/ieee/html/ieee.scss
|
227
230
|
- lib/isodoc/ieee/html/scripts.html
|
228
231
|
- lib/isodoc/ieee/html/word_ieee_intro.html
|
229
232
|
- lib/isodoc/ieee/html/word_ieee_titlepage.html
|
233
|
+
- lib/isodoc/ieee/html/wordstyle.css
|
230
234
|
- lib/isodoc/ieee/html/wordstyle.scss
|
231
235
|
- lib/isodoc/ieee/html_convert.rb
|
232
236
|
- lib/isodoc/ieee/i18n-en.yaml
|
@@ -265,7 +269,7 @@ files:
|
|
265
269
|
- lib/metanorma/ieee/version.rb
|
266
270
|
- lib/relaton/render/config.yml
|
267
271
|
- lib/relaton/render/general.rb
|
268
|
-
- metanorma-
|
272
|
+
- metanorma-ieee.gemspec
|
269
273
|
homepage: https://github.com/metanorma/metanorma-ieee
|
270
274
|
licenses:
|
271
275
|
- BSD-2-Clause
|