cloudcannon-jekyll 2.3.2 → 2.3.3

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
  SHA256:
3
- metadata.gz: efdfbdebe6d3466481e84abaf6b7b4864a1099eb7d0912c3ead7ac315ec4019a
4
- data.tar.gz: fc4928e35e8668c0e9486299e998ed86ee1d5ed22b5933eb19da6bd5f4bb57ae
3
+ metadata.gz: c62beece4089cf5687f4c84d38495a602f62800a19bd5e195eb0272f79724965
4
+ data.tar.gz: 34024730134cd587c13ba63e259454c9d1aedb3fd0479f8ef32a2401ddab0753
5
5
  SHA512:
6
- metadata.gz: 05d2807950dee52da723333cbfbc443cea8ab22e2ca7717e68c64e74f3f0cdcebd12c1d1bea5516117bda31b6f18ba1f6951db581cba521bc0ee228569923471
7
- data.tar.gz: '0087790fb58ed83ffdeb6ef07b403a889c6d3ef805af73a1ad231f57f8dfe20f2012da33fb3149eccd865c95521bf77184b976b48bfbbb33591478ea0d8df40c'
6
+ metadata.gz: '09a307c7f7d9deba9f4fe4407ae982b16c6a260bda34bbe140547cfe978a5268c0016210f995a8a6cf69c0b0815b3e883b369265586af64dfc07b41daa78e0ef'
7
+ data.tar.gz: 798272f7382f5da33c7bb6c03e30733a506346bc162eb042c1ef09fc1b62ae405d8660bb10771a07377cefeda9995852295dbd0cc37066f2c83944ae4b0777f8
data/HISTORY.md CHANGED
@@ -1,3 +1,7 @@
1
+ # 2.3.3
2
+
3
+ * Add _structures
4
+
1
5
  # 2.3.2
2
6
 
3
7
  * Add _inputs to templates
@@ -63,6 +63,9 @@
63
63
  "collections": {{ config.collections_dir | cc_jsonify }},
64
64
  "layouts": {{ config.layouts_dir | cc_jsonify }}
65
65
  },
66
+ {% if config._structures %}
67
+ "_structures": {{ config._structures | cc_jsonify: 50 }},
68
+ {% endif %}
66
69
  {% if config._array_structures %}
67
70
  "_array_structures": {{ config._array_structures | cc_jsonify: 50 }},
68
71
  {% endif %}
@@ -63,6 +63,9 @@
63
63
  "collections": {{ config.collections_dir | cc_jsonify }},
64
64
  "layouts": {{ config.layouts_dir | cc_jsonify }}
65
65
  },
66
+ {% if config._structures %}
67
+ "_structures": {{ config._structures | cc_jsonify: 50 }},
68
+ {% endif %}
66
69
  {% if config._array_structures %}
67
70
  "_array_structures": {{ config._array_structures | cc_jsonify: 50 }},
68
71
  {% endif %}
@@ -66,6 +66,9 @@
66
66
  "collections": {{ config.collections_dir | cc_jsonify }},
67
67
  "layouts": {{ config.layouts_dir | cc_jsonify }}
68
68
  },
69
+ {% if config._structures -%}
70
+ "_structures": {{ config._structures | cc_jsonify: 50 }},
71
+ {%- endif %}
69
72
  {% if config._array_structures -%}
70
73
  "_array_structures": {{ config._array_structures | cc_jsonify: 50 }},
71
74
  {%- endif %}
@@ -50,7 +50,7 @@ module CloudCannonJekyll
50
50
  next if prevent.include?(key) || key.nil?
51
51
 
52
52
  prevent.push key
53
- next_max_depth = key == "_array_structures" ? 20 : max_depth
53
+ next_max_depth = %w(_array_structures _structures).include?(key) ? 20 : max_depth
54
54
  "#{key.to_json}: #{JsonifyFilter.to_json(value, depth, next_max_depth)}"
55
55
  end
56
56
 
@@ -134,7 +134,7 @@ module CloudCannonJekyll
134
134
 
135
135
  def self.hash_to_json(input, depth, max_depth)
136
136
  out = input.map do |key, value|
137
- next_max_depth = key == "_array_structures" ? 20 : max_depth
137
+ next_max_depth = %w(_array_structures _structures).include?(key) ? 20 : max_depth
138
138
  string_key = key.to_s.to_json
139
139
  "#{string_key}: #{JsonifyFilter.to_json(value, depth, next_max_depth)}"
140
140
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CloudCannonJekyll
4
- VERSION = "2.3.2"
4
+ VERSION = "2.3.3"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cloudcannon-jekyll
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.2
4
+ version: 2.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - CloudCannon