pistaa 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0b7239fd73ce7ca80d1474305f70792790664cb3
4
- data.tar.gz: d05b4023c36ce5a1e7fbda6f6bb8ebba4bb2a698
3
+ metadata.gz: 10f7e4d82198f31254dcf5248b7701e7dfb1f501
4
+ data.tar.gz: 2cda2238b79522ba7bbcc51d95ed8910d81c957c
5
5
  SHA512:
6
- metadata.gz: 2eb36ef4ea922e0d65e4ca7f4421e3a12be64e8d9f8ef5fffc887a3745bade86ae927d91a0acb336c69fc0129e5effa93d4185fdd138b9b9dbd7c5b4cbcaea53
7
- data.tar.gz: b6a0abdef259f6d165e74f7c0d9e3c64c12df900e053687de20fd027ec70003ca788a95d7c848fb5fafde93a98f707fc0f3b276acc94223cea5b4d34f9569f2b
6
+ metadata.gz: e10ea62cf94deab83a2adcf62311847470be323a7e4679c511655d7a1240d4dbf9c7bd1cc0d067f4c0f295adc0c62f01017b7c708ec1efae6bea6b03d3384881
7
+ data.tar.gz: 4de744453b4793b3d7ff233d45303f5c912144e11252789b484e10ea5e61f97002da7f9e06a818c16c12734d80e89ba491f4141ba196c59de53a97c02c05c3b1
data/README.md CHANGED
@@ -70,7 +70,7 @@ needs.
70
70
  ## Inspiration
71
71
 
72
72
  I'm aware of one other project that tries to solve this problem, but in a
73
- completely different way. [Deface](https://github.com/spree/deface is tool that
73
+ completely different way. [Deface](https://github.com/spree/deface) is tool that
74
74
  was used in older versions of [Spree](https://spreecommerce.com/) and also
75
75
  provides a way to alter templates from engines. It parses ERB templates to an
76
76
  XML structure using Nokogiri, exposes a DSL to manipulate the Nokogiri document
@@ -4,11 +4,13 @@ module PistaaHelper
4
4
  # hidden. It repeatedly calls `render_pistaa_slot_item`, so the rendered
5
5
  # templates will be registered as hidden.
6
6
  def render_pistaa_slot(slot)
7
- pistaa_slot_items(slot).map do |item|
8
- next if pistaa_slot_item_hidden?(slot, item)
7
+ capture do
8
+ pistaa_slot_items(slot).map do |item|
9
+ next if pistaa_slot_item_hidden?(slot, item)
9
10
 
10
- render_pistaa_slot_item(slot, item)
11
- end.join("\n").html_safe
11
+ concat(render_pistaa_slot_item(slot, item))
12
+ end
13
+ end
12
14
  end
13
15
 
14
16
  # Render a specific template from a slot (regardless of it was hidden), and
@@ -1,3 +1,3 @@
1
1
  module Pistaa
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pistaa
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rolf van de Krol