metanorma-iso 2.0.8 → 2.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (57) hide show
  1. checksums.yaml +4 -4
  2. data/lib/html2doc/lists.rb +37 -0
  3. data/lib/isodoc/iso/base_convert.rb +1 -1
  4. data/lib/isodoc/iso/html/html_iso_titlepage.html +5 -0
  5. data/lib/isodoc/iso/html/isodoc-dis.css +304 -242
  6. data/lib/isodoc/iso/html/isodoc-dis.scss +379 -260
  7. data/lib/isodoc/iso/html/word_iso_intro-dis.html +7 -0
  8. data/lib/isodoc/iso/html/word_iso_titlepage-dis.html +4 -3
  9. data/lib/isodoc/iso/html/word_iso_titlepage.html +10 -4
  10. data/lib/isodoc/iso/html/wordstyle-dis.css +168 -48
  11. data/lib/isodoc/iso/html/wordstyle-dis.scss +158 -43
  12. data/lib/isodoc/iso/html_convert.rb +2 -2
  13. data/lib/isodoc/iso/i18n-en.yaml +1 -0
  14. data/lib/isodoc/iso/i18n-fr.yaml +1 -0
  15. data/lib/isodoc/iso/i18n-ru.yaml +1 -0
  16. data/lib/isodoc/iso/i18n-zh-Hans.yaml +1 -0
  17. data/lib/isodoc/iso/init.rb +17 -1
  18. data/lib/isodoc/iso/iso.amendment.xsl +1697 -426
  19. data/lib/isodoc/iso/iso.international-standard.xsl +1697 -426
  20. data/lib/isodoc/iso/metadata.rb +13 -19
  21. data/lib/isodoc/iso/presentation_inline.rb +90 -0
  22. data/lib/isodoc/iso/presentation_xml_convert.rb +41 -100
  23. data/lib/isodoc/iso/presentation_xref.rb +126 -0
  24. data/lib/isodoc/iso/sections.rb +2 -2
  25. data/lib/isodoc/iso/word_cleanup.rb +16 -2
  26. data/lib/isodoc/iso/word_convert.rb +29 -12
  27. data/lib/isodoc/iso/word_dis_convert.rb +183 -0
  28. data/lib/isodoc/iso/xref.rb +46 -25
  29. data/lib/metanorma/iso/biblio.rng +37 -8
  30. data/lib/metanorma/iso/boilerplate-fr.xml +1 -1
  31. data/lib/metanorma/iso/boilerplate-ru.xml +1 -3
  32. data/lib/metanorma/iso/boilerplate.xml +1 -3
  33. data/lib/metanorma/iso/cleanup.rb +2 -1
  34. data/lib/metanorma/iso/isodoc.rng +56 -0
  35. data/lib/metanorma/iso/version.rb +1 -1
  36. data/lib/metanorma-iso.rb +1 -0
  37. data/lib/relaton/render/config.yml +4 -0
  38. data/lib/relaton/render/general.rb +13 -0
  39. data/metanorma-iso.gemspec +1 -1
  40. data/spec/isodoc/amd_spec.rb +31 -30
  41. data/spec/isodoc/blocks_spec.rb +286 -179
  42. data/spec/isodoc/i18n_spec.rb +187 -21
  43. data/spec/isodoc/inline_spec.rb +35 -42
  44. data/spec/isodoc/iso_spec.rb +1 -1
  45. data/spec/isodoc/metadata_spec.rb +17 -17
  46. data/spec/isodoc/postproc_spec.rb +28 -3
  47. data/spec/isodoc/ref_spec.rb +66 -69
  48. data/spec/isodoc/section_spec.rb +78 -76
  49. data/spec/isodoc/table_spec.rb +2 -2
  50. data/spec/isodoc/terms_spec.rb +2 -2
  51. data/spec/isodoc/word_dis_spec.rb +760 -0
  52. data/spec/isodoc/xref_spec.rb +51 -51
  53. data/spec/metanorma/base_spec.rb +10 -10
  54. data/spec/spec_helper.rb +11 -1
  55. data/spec/vcr_cassettes/withdrawn_iso.yml +26 -26
  56. metadata +11 -5
  57. data/spec/vcr_cassettes/docrels.yml +0 -385
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 270772cf99831fb493ca68a370d9954b842096aeed522b7e4657aef7743a3557
4
- data.tar.gz: 0fb34c7f8786206cbfff5e12714f89f8bf38cc51abbd108a9410d40d3bb5f2f4
3
+ metadata.gz: 3154af64aad28148d931cad79a5e4ba8633d7fe8db27dd87b1c721d660a46e27
4
+ data.tar.gz: 784bb188b1397fabf8978e5896382b3dd724ab0458f2b758268b8ffb202ab6fc
5
5
  SHA512:
6
- metadata.gz: 68afd7bbc05425d59bcef20308269243ebaad1e711b6bf7a2db76cd17a2b685d74773a0b36994187d7261bb02f7c29780f1776471f815148266d69ff0389e5b8
7
- data.tar.gz: 6881356aa0f6743f86aab7557993b7b3316b3320d48d379458aef11c9f327a7f00cb4048ff8902ef1d180e2a45ee2dadb49c12d5c9e04c043d367febd012e6a2
6
+ metadata.gz: 53719e79cd10a8b3f8cf6df804e9dd6e89c365eadbb8c3a6e6a3cf7881162b4d68dcf49daf27fd324960d36981ee16d49abd03ee1abe507e070c75524d382939
7
+ data.tar.gz: b9cce4a6a713f9d6844359a1ddd25f6771adb754418d4662b415840f6885b86020ff5c929dbdf234f76c19eee61df0572c037607d021d1f5d6ca746450065bfd
@@ -0,0 +1,37 @@
1
+ class Html2Doc
2
+ class IsoDIS < ::Html2Doc
3
+ def list2para(list)
4
+ return if list.xpath("./li").empty?
5
+
6
+ list.xpath("./li").each do |l|
7
+ l.name = "p"
8
+ if m = /level(\d) lfo/.match(l["style"])
9
+ l["class"] = list2para_style(list.name, m[1])
10
+ l.xpath("./p").each do |p|
11
+ p["class"] = list2para_style(list.name, m[1])
12
+ end
13
+ end
14
+ l&.first_element_child&.name == "p" and
15
+ l.first_element_child.replace(l.first_element_child.children)
16
+ end
17
+ list.replace(list.children)
18
+ end
19
+
20
+ def list2para_style(listtype, depth)
21
+ case listtype
22
+ when "ul"
23
+ case depth
24
+ when "1" then "ListContinue1"
25
+ when "2", "3", "4" then "MsoListContinue#{depth}"
26
+ else "MsoListContinue5"
27
+ end
28
+ when "ol"
29
+ case depth
30
+ when "1" then "ListNumber1"
31
+ when "2", "3", "4" then "MsoListNumber#{depth}"
32
+ else "MsoListNumber5"
33
+ end
34
+ end
35
+ end
36
+ end
37
+ end
@@ -129,7 +129,7 @@ module IsoDoc
129
129
 
130
130
  def admonition_name_parse(_node, div, name)
131
131
  name.children.each { |n| parse(n, div) }
132
- div << " &mdash; "
132
+ div << " &#x2014; "
133
133
  end
134
134
 
135
135
  def figure_name_parse(_node, div, name)
@@ -7,6 +7,10 @@
7
7
  <p class="coverpage_docnumber">{{ docnumber_undated }} {{ draftinfo }}</p>
8
8
  {% endif %}
9
9
 
10
+ {% if edition_display %}
11
+ <p class="coverpage_docnumber">{{ edition_display | capitalize }}</p>
12
+ {% endif %}
13
+
10
14
  {% if revdate %}
11
15
  <p class="coverpage_docnumber">{{ labels["date"]}}: {{ revdate }}</p>
12
16
  {% endif %}
@@ -61,6 +65,7 @@
61
65
  <div id="boilerplate-license-destination"/>
62
66
  </div>
63
67
  {% endif %}
68
+ <div class="coverpage-warning" id="coverpage-note-destination"/>
64
69
 
65
70
  {% if ics %}
66
71
  <p><b>ICS:</b> {{ ics }}</p>