caracal 1.0.12 → 1.0.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c6abd29861f9145e2661e53aa4d7628fbbf5acc8
4
- data.tar.gz: 0fa3c5ece4838b263306efd2f19f2d163c41b017
3
+ metadata.gz: 7423edb9358ab382c88076980d43f0c9055b52c5
4
+ data.tar.gz: d564e16cb4c7ee233a8d90e7a173901fddcf59ab
5
5
  SHA512:
6
- metadata.gz: 6738303388e63ea0488b20395859249af3238cdeda4ee394db37f5c8c943a63528d910d192c4b089f07f6e1e766b7b8aefd3cb859a1e74efd5fa342b8d346735
7
- data.tar.gz: b52abcdae9a71ec3c6fd3c3e432fabfc8005d22f77c0175a0404ef26beafa867f83b8847985fc7ca523cb94a0fb7affc8007257f064ef5152619d3309b6349fd
6
+ metadata.gz: 6944eb1e2157768ffcdeb4f467fa353cf47d083b8f1fcf66f6323d51adffb5e2c6d11da0fd5b106ec170cfec01186ad6421e8e94a28c46dd8661326b24f89e28
7
+ data.tar.gz: 36b335578ce968bfc1efd71c1faf821b92d67901157568b8cfd6c500e0fcfe099472593bca3dc276279f3485441b53ff4322d5da355d7833e440ec18a723b2c7
@@ -8,21 +8,22 @@ require 'caracal/renderers/xml_renderer'
8
8
  module Caracal
9
9
  module Renderers
10
10
  class NumberingRenderer < XmlRenderer
11
-
11
+
12
12
  #-------------------------------------------------------------
13
13
  # Public Methods
14
14
  #-------------------------------------------------------------
15
-
16
- # This method produces the xml required for the `word/numbering.xml`
15
+
16
+ # This method produces the xml required for the `word/numbering.xml`
17
17
  # sub-document.
18
18
  #
19
19
  def to_xml
20
20
  builder = ::Nokogiri::XML::Builder.with(declaration_xml) do |xml|
21
21
  xml.send 'w:numbering', root_options do
22
-
22
+
23
23
  # add abstract definitions
24
24
  document.toplevel_lists.each_with_index do |model, i|
25
25
  xml.send 'w:abstractNum', { 'w:abstractNumId' => i + 1 } do
26
+ xml.send 'w:multiLevelType', { 'w:val' => 'hybridMultilevel' }
26
27
  model.level_map.each do |(level, type)|
27
28
  if s = document.find_list_style(type, level)
28
29
  xml.send 'w:lvl', { 'w:ilvl' => s.style_level } do
@@ -42,7 +43,7 @@ module Caracal
42
43
  end
43
44
  end
44
45
  end
45
-
46
+
46
47
  # bind individual tables to abstract definitions
47
48
  document.toplevel_lists.each_with_index do |model, i|
48
49
  xml.send 'w:num', { 'w:numId' => i + 1 } do
@@ -50,18 +51,18 @@ module Caracal
50
51
  end
51
52
  end
52
53
  end
53
-
54
+
54
55
  end
55
56
  builder.to_xml(save_options)
56
57
  end
57
-
58
-
59
-
58
+
59
+
60
+
60
61
  #-------------------------------------------------------------
61
62
  # Private Methods
62
- #-------------------------------------------------------------
63
+ #-------------------------------------------------------------
63
64
  private
64
-
65
+
65
66
  def root_options
66
67
  {
67
68
  'xmlns:mc' => 'http://schemas.openxmlformats.org/markup-compatibility/2006',
@@ -81,7 +82,7 @@ module Caracal
81
82
  'xmlns:dgm' => 'http://schemas.openxmlformats.org/drawingml/2006/diagram'
82
83
  }
83
84
  end
84
-
85
+
85
86
  end
86
87
  end
87
- end
88
+ end
@@ -1,3 +1,3 @@
1
1
  module Caracal
2
- VERSION = '1.0.12'
2
+ VERSION = '1.0.13'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: caracal
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.12
4
+ version: 1.0.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Trade Infomatics
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2017-06-17 00:00:00.000000000 Z
12
+ date: 2017-08-17 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: nokogiri