metanorma-ieee 1.1.2 → 1.1.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (38) hide show
  1. checksums.yaml +4 -4
  2. data/lib/html2doc/ieee_wp/lists.rb +22 -0
  3. data/lib/html2doc/ieee_wp.rb +6 -0
  4. data/lib/isodoc/ieee/base_convert.rb +5 -0
  5. data/lib/isodoc/ieee/html/header_wp.html +348 -0
  6. data/lib/isodoc/ieee/html/ieee_wp.css +3316 -0
  7. data/lib/isodoc/ieee/html/ieee_wp.scss +3174 -0
  8. data/lib/isodoc/ieee/html/word_ieee_colophon_wp.html +129 -0
  9. data/lib/isodoc/ieee/html/word_ieee_intro_wp.html +142 -0
  10. data/lib/isodoc/ieee/html/word_ieee_titlepage_wp.html +333 -0
  11. data/lib/isodoc/ieee/html/wordstyle_wp.css +5795 -0
  12. data/lib/isodoc/ieee/html/wordstyle_wp.scss +5357 -0
  13. data/lib/isodoc/ieee/html/wp_image001.emz +0 -0
  14. data/lib/isodoc/ieee/html/wp_image003.emz +0 -0
  15. data/lib/isodoc/ieee/html/wp_image008.emz +0 -0
  16. data/lib/isodoc/ieee/i18n-en.yaml +1 -0
  17. data/lib/isodoc/ieee/metadata.rb +15 -5
  18. data/lib/isodoc/ieee/presentation_xml_convert.rb +44 -5
  19. data/lib/isodoc/ieee/word_authority.rb +14 -13
  20. data/lib/isodoc/ieee/word_cleanup.rb +43 -20
  21. data/lib/isodoc/ieee/word_cleanup_blocks.rb +23 -17
  22. data/lib/isodoc/ieee/word_convert.rb +26 -5
  23. data/lib/isodoc/ieee/word_wp_cleanup.rb +220 -0
  24. data/lib/isodoc/ieee/word_wp_convert.rb +115 -0
  25. data/lib/isodoc/ieee/xref.rb +24 -2
  26. data/lib/metanorma/ieee/basicdoc.rng +18 -2
  27. data/lib/metanorma/ieee/biblio.rng +1 -1
  28. data/lib/metanorma/ieee/boilerplate_wp.adoc +95 -0
  29. data/lib/metanorma/ieee/cleanup.rb +10 -6
  30. data/lib/metanorma/ieee/cleanup_ref.rb +8 -0
  31. data/lib/metanorma/ieee/converter.rb +5 -2
  32. data/lib/metanorma/ieee/front.rb +13 -12
  33. data/lib/metanorma/ieee/isodoc.rng +18 -1
  34. data/lib/metanorma/ieee/validate.rb +5 -5
  35. data/lib/metanorma/ieee/version.rb +1 -1
  36. data/lib/metanorma-ieee.rb +1 -0
  37. data/lib/relaton/render/config.yml +6 -6
  38. metadata +18 -2
@@ -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.2.4 -->
20
+ <!-- VERSION v1.2.5 -->
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">
@@ -485,6 +485,8 @@
485
485
  <choice>
486
486
  <text/>
487
487
  <ref name="callout"/>
488
+ <ref name="xref"/>
489
+ <ref name="eref"/>
488
490
  </choice>
489
491
  </oneOrMore>
490
492
  <zeroOrMore>
@@ -865,6 +867,7 @@
865
867
  <ref name="PureTextElement"/>
866
868
  <ref name="stem"/>
867
869
  <ref name="index"/>
870
+ <ref name="index-xref"/>
868
871
  <ref name="eref"/>
869
872
  <ref name="erefstack"/>
870
873
  <ref name="xref"/>
@@ -880,6 +883,7 @@
880
883
  <ref name="PureTextElement"/>
881
884
  <ref name="stem"/>
882
885
  <ref name="index"/>
886
+ <ref name="index-xref"/>
883
887
  <ref name="eref"/>
884
888
  <ref name="erefstack"/>
885
889
  <ref name="xref"/>
@@ -894,6 +898,7 @@
894
898
  <choice>
895
899
  <ref name="PureTextElement"/>
896
900
  <ref name="index"/>
901
+ <ref name="index-xref"/>
897
902
  <ref name="eref"/>
898
903
  <ref name="erefstack"/>
899
904
  <ref name="xref"/>
@@ -908,6 +913,7 @@
908
913
  <choice>
909
914
  <ref name="PureTextElement"/>
910
915
  <ref name="index"/>
916
+ <ref name="index-xref"/>
911
917
  </choice>
912
918
  </zeroOrMore>
913
919
  </element>
@@ -918,6 +924,7 @@
918
924
  <choice>
919
925
  <ref name="PureTextElement"/>
920
926
  <ref name="index"/>
927
+ <ref name="index-xref"/>
921
928
  </choice>
922
929
  </zeroOrMore>
923
930
  </element>
@@ -928,6 +935,7 @@
928
935
  <choice>
929
936
  <ref name="PureTextElement"/>
930
937
  <ref name="index"/>
938
+ <ref name="index-xref"/>
931
939
  </choice>
932
940
  </zeroOrMore>
933
941
  </element>
@@ -938,6 +946,7 @@
938
946
  <choice>
939
947
  <ref name="PureTextElement"/>
940
948
  <ref name="index"/>
949
+ <ref name="index-xref"/>
941
950
  </choice>
942
951
  </zeroOrMore>
943
952
  </element>
@@ -1047,6 +1056,8 @@
1047
1056
  <ref name="keyword"/>
1048
1057
  <ref name="xref"/>
1049
1058
  <ref name="hyperlink"/>
1059
+ <ref name="index"/>
1060
+ <ref name="index-xref"/>
1050
1061
  </choice>
1051
1062
  </element>
1052
1063
  </define>
@@ -1060,6 +1071,8 @@
1060
1071
  <ref name="keyword"/>
1061
1072
  <ref name="xref"/>
1062
1073
  <ref name="hyperlink"/>
1074
+ <ref name="index"/>
1075
+ <ref name="index-xref"/>
1063
1076
  </choice>
1064
1077
  </element>
1065
1078
  </define>
@@ -1126,6 +1139,8 @@
1126
1139
  <choice>
1127
1140
  <ref name="PureTextElement"/>
1128
1141
  <ref name="stem"/>
1142
+ <ref name="index"/>
1143
+ <ref name="index-xref"/>
1129
1144
  </choice>
1130
1145
  </zeroOrMore>
1131
1146
  </element>
@@ -1136,6 +1151,8 @@
1136
1151
  <choice>
1137
1152
  <ref name="PureTextElement"/>
1138
1153
  <ref name="stem"/>
1154
+ <ref name="index"/>
1155
+ <ref name="index-xref"/>
1139
1156
  </choice>
1140
1157
  </zeroOrMore>
1141
1158
  </element>
@@ -54,7 +54,7 @@ module Metanorma
54
54
  def locality_range_validate(root)
55
55
  root.xpath("//eref | xref").each do |e|
56
56
  e.at(".//localityStack[@connective = 'from'] | .//referenceTo") and
57
- @log.add("Style", e, "Cross-reference contains range, "\
57
+ @log.add("Style", e, "Cross-reference contains range, " \
58
58
  "should be separate cross-references")
59
59
  end
60
60
  end
@@ -64,7 +64,7 @@ module Metanorma
64
64
  root.xpath("//eref[descendant::locality]").each do |t|
65
65
  if !/[:-](\d+{4})$/.match?(t["citeas"])
66
66
  @log.add("Style", t,
67
- "Undated reference #{t['citeas']} should not contain "\
67
+ "Undated reference #{t['citeas']} should not contain " \
68
68
  "specific elements")
69
69
  end
70
70
  end
@@ -203,7 +203,7 @@ module Metanorma
203
203
  desc = a.at("./description")
204
204
  if desc && !desc.text.strip.empty?
205
205
  amend_validate1(a, desc.text.strip,
206
- a.at("./newcontent//figure | "\
206
+ a.at("./newcontent//figure | " \
207
207
  "./newcontent//formula"))
208
208
  else @log.add("Style", a,
209
209
  "Editorial instruction is missing from change")
@@ -226,9 +226,9 @@ module Metanorma
226
226
 
227
227
  AMD_VALID_MOD = [
228
228
  "'Modify' change description should start with _Change_ or _Replace_",
229
- "'Modify' change description for change involving figure or equation "\
229
+ "'Modify' change description for change involving figure or equation " \
230
230
  "should start with _Replace_",
231
- "'Modify' change description for change not involving figure or "\
231
+ "'Modify' change description for change not involving figure or " \
232
232
  "equation should start with _Change_",
233
233
  ].freeze
234
234
 
@@ -1,5 +1,5 @@
1
1
  module Metanorma
2
2
  module IEEE
3
- VERSION = "1.1.2".freeze
3
+ VERSION = "1.1.3".freeze
4
4
  end
5
5
  end
@@ -2,6 +2,7 @@ require "metanorma/ieee"
2
2
  require "asciidoctor"
3
3
  require "isodoc/ieee"
4
4
  require "html2doc/ieee"
5
+ require "html2doc/ieee_wp"
5
6
  require "metanorma"
6
7
 
7
8
  if defined? Metanorma::Registry
@@ -9,17 +9,17 @@ extenttemplate:
9
9
  misc: "{{ volume }}, {{issue}}, {{ page }}, {{ duration }}"
10
10
  template:
11
11
  # skip authoritative_identifier, it is inserted in front of formattedref within metanorma
12
- standard: "{% if home_standard %}{{ title }}.{% else %}{{ creatornames }}, “{{ title }},” {{ extent }}, {{ labels['version'] }}_{{ edition_raw }}, {{date}}, {{labels['updated'] | capitalize }}_{{date_updated}}, {{status }}, {{ authorizer }}, {{ uri }} .{% endif %}"
13
- article: "{{creatornames}}, “{{title}},” <em>{{ series }}</em>, {{ extent }}, {{ date }}, {{ labels['viewed'] }}_{{date_accessed}}, {{ uri }} ."
14
- book: "{{creatornames}}, <em>{{title}}</em>, {{ edition }}, {{place}}: {{publisher}}, {{date}}, {{ labels['viewed'] }}_{{date_accessed}}, {{ uri }} ."
12
+ standard: "{% if home_standard %}{{ title }}.{% else %}{{ creatornames }}, “{{ title }},” {{ extent }}, {{ labels['version'] }}_{{ edition_raw }}, {{date}}, {{labels['updated'] | capitalize }}_{{date_updated}}, {{status }}, {{ authorizer }}, {% if uri %}{{ uri }}{% else %}{% if doi %}DOI: {{ doi | join: ', ' }}{% endif %}{% endif %} .{% endif %}"
13
+ article: "{{creatornames}}, “{{title}},” <em>{{ series }}</em>, {{ extent }}, {{ date }}, {{ labels['viewed'] }}_{{date_accessed}}, {% if uri %}{{ uri }}{% else %}{% if doi %}DOI: {{ doi | join: ', ' }}{% endif %}{% endif %} ."
14
+ book: "{{creatornames}}, <em>{{title}}</em>, {{ edition }}, {{place}}: {{publisher}}, {{date}}, {{ labels['viewed'] }}_{{date_accessed}}, {% if uri %}{{ uri }}{% else %}{% if doi %}DOI: {{ doi | join: ', ' }}{% endif %}{% endif %} ."
15
15
  techreport: book
16
16
  booklet: book
17
17
  manual: book
18
18
  proceedings: book
19
- inproceedings: "{{ creatornames }}, “{{ title }},” <em>{{host_title}}</em>, {{place}}, {{extent}}, {{date}}, {{ labels['viewed'] }}_{{date_accessed}}, {{ uri }} ."
20
- inbook: "{{ creatornames }}, “{{ title }},” {{ labels['in'] }} {{ host_creatornames}} ({{ host_role}}) : <em>{{host_title}}</em>, {{place}}: {{publisher}}, {{date}}, {{extent}}, {{ labels['viewed'] }}_{{date_accessed}}, {{ uri }} ."
19
+ inproceedings: "{{ creatornames }}, “{{ title }},” <em>{{host_title}}</em>, {{place}}, {{extent}}, {{date}}, {{ labels['viewed'] }}_{{date_accessed}}, {% if uri %}{{ uri }}{% else %}{% if doi %}DOI: {{ doi | join: ', ' }}{% endif %}{% endif %} ."
20
+ inbook: "{{ creatornames }}, “{{ title }},” {{ labels['in'] }} {{ host_creatornames}} ({{ host_role}}) : <em>{{host_title}}</em>, {{place}}: {{publisher}}, {{date}}, {{extent}}, {{ labels['viewed'] }}_{{date_accessed}}, {% if uri %}{{ uri }}{% else %}{% if doi %}DOI: {{ doi | join: ', ' }}{% endif %}{% endif %} ."
21
21
  incollection: inbook
22
- thesis: "{{ creatornames }} , “{{ title }}.” {{ medium | capitalize }}, {{ publisher }}, {{ date }}, {{ labels['viewed'] }}_{{date_accessed}}, {{ uri }} ."
22
+ thesis: "{{ creatornames }} , “{{ title }}.” {{ medium | capitalize }}, {{ publisher }}, {{ date }}, {{ labels['viewed'] }}_{{date_accessed}}, {% if uri %}{{ uri }}{% else %}{% if doi %}DOI: {{ doi | join: ', ' }}{% endif %}{% endif %} ."
23
23
  unpublished: thesis
24
24
  misc: thesis
25
25
  website: thesis
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.1.2
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-09-11 00:00:00.000000000 Z
11
+ date: 2023-10-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: metanorma-standoc
@@ -224,21 +224,34 @@ files:
224
224
  - lib/html2doc/ieee.rb
225
225
  - lib/html2doc/ieee/lists.rb
226
226
  - lib/html2doc/ieee/notes.rb
227
+ - lib/html2doc/ieee_wp.rb
228
+ - lib/html2doc/ieee_wp/lists.rb
227
229
  - lib/isodoc/ieee.rb
228
230
  - lib/isodoc/ieee/base_convert.rb
229
231
  - lib/isodoc/ieee/html/header.html
230
232
  - lib/isodoc/ieee/html/header_amd.html
233
+ - lib/isodoc/ieee/html/header_wp.html
231
234
  - lib/isodoc/ieee/html/html_ieee_intro.html
232
235
  - lib/isodoc/ieee/html/html_ieee_titlepage.html
233
236
  - lib/isodoc/ieee/html/htmlstyle.css
234
237
  - lib/isodoc/ieee/html/htmlstyle.scss
235
238
  - lib/isodoc/ieee/html/ieee.css
236
239
  - lib/isodoc/ieee/html/ieee.scss
240
+ - lib/isodoc/ieee/html/ieee_wp.css
241
+ - lib/isodoc/ieee/html/ieee_wp.scss
237
242
  - lib/isodoc/ieee/html/scripts.html
243
+ - lib/isodoc/ieee/html/word_ieee_colophon_wp.html
238
244
  - lib/isodoc/ieee/html/word_ieee_intro.html
245
+ - lib/isodoc/ieee/html/word_ieee_intro_wp.html
239
246
  - lib/isodoc/ieee/html/word_ieee_titlepage.html
247
+ - lib/isodoc/ieee/html/word_ieee_titlepage_wp.html
240
248
  - lib/isodoc/ieee/html/wordstyle.css
241
249
  - lib/isodoc/ieee/html/wordstyle.scss
250
+ - lib/isodoc/ieee/html/wordstyle_wp.css
251
+ - lib/isodoc/ieee/html/wordstyle_wp.scss
252
+ - lib/isodoc/ieee/html/wp_image001.emz
253
+ - lib/isodoc/ieee/html/wp_image003.emz
254
+ - lib/isodoc/ieee/html/wp_image008.emz
242
255
  - lib/isodoc/ieee/html_convert.rb
243
256
  - lib/isodoc/ieee/i18n-en.yaml
244
257
  - lib/isodoc/ieee/i18n.rb
@@ -257,6 +270,8 @@ files:
257
270
  - lib/isodoc/ieee/word_cleanup.rb
258
271
  - lib/isodoc/ieee/word_cleanup_blocks.rb
259
272
  - lib/isodoc/ieee/word_convert.rb
273
+ - lib/isodoc/ieee/word_wp_cleanup.rb
274
+ - lib/isodoc/ieee/word_wp_convert.rb
260
275
  - lib/isodoc/ieee/xref.rb
261
276
  - lib/metanorma-ieee.rb
262
277
  - lib/metanorma/ieee.rb
@@ -264,6 +279,7 @@ files:
264
279
  - lib/metanorma/ieee/biblio-standoc.rng
265
280
  - lib/metanorma/ieee/biblio.rng
266
281
  - lib/metanorma/ieee/boilerplate.adoc
282
+ - lib/metanorma/ieee/boilerplate_wp.adoc
267
283
  - lib/metanorma/ieee/cleanup.rb
268
284
  - lib/metanorma/ieee/cleanup_ref.rb
269
285
  - lib/metanorma/ieee/converter.rb