view_component 2.16.0 → 2.17.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of view_component might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9ccdcdb195fbc49953c3663294a7345eb012f88344d1375456a07c6ef781b1d8
4
- data.tar.gz: b2cf7cb1139e318f2ca7712242e610c31a42c78448a5d3151db1550a41e00355
3
+ metadata.gz: 63cae604f99ce706878da0fb00ddfdde223bbb1431e33e3096448e4e65b569af
4
+ data.tar.gz: 2017fe3d3b8b2979fb5854fbb40cecc5b4c760953377a8e45ceccfbcc1eb01c3
5
5
  SHA512:
6
- metadata.gz: 72657816a14d62166791f37d2f83cfd81efe8f186678bcf21e40c50d38d64663fbc4e2b9fe881820ba26f2a7ea258d5d6c0cb47a73132d5443f66db3489d1921
7
- data.tar.gz: e7abe1071862dfb3208e2615176fd352b0f6cd6e7ef947b1dfb4528e435682908cd01ab8091b33612b234eebf7121a7dd00e5cb8890bc6ae1160fdf5bcbdcd3f
6
+ metadata.gz: ce31c6c2f4668c683ce037c9dc1e2de1e462e3ac5301176a70bf5ab4d7d10cafe33d611f00fd55e13f707b6c19e1731c1c18978ba5e0bc05c35c5986159ac5ef
7
+ data.tar.gz: 0fde2e678e6d671e77812f197180bcef3e90ac1e87615dede2890359bb9a594a490edbe43eee43ed60e568826e616cf16e59392427f952c35497dc3516e16bc3
@@ -1,5 +1,11 @@
1
1
  # master
2
2
 
3
+ # 2.17.0
4
+
5
+ * Slots return stripped HTML, removing leading and trailing whitespace.
6
+
7
+ *Jason Long, Joel Hawksley*
8
+
3
9
  # 2.16.0
4
10
 
5
11
  * Add `--sidecar` option to the erb, haml and slim generators. Places the generated template in the sidecar directory.
@@ -98,7 +98,7 @@ module ViewComponent
98
98
  slot_instance = args.present? ? slot_class.new(**args) : slot_class.new
99
99
 
100
100
  # Capture block and assign to slot_instance#content
101
- slot_instance.content = view_context.capture(&block) if block_given?
101
+ slot_instance.content = view_context.capture(&block).strip.html_safe if block_given?
102
102
 
103
103
  if slot[:collection]
104
104
  # Initialize instance variable as an empty array
@@ -3,7 +3,7 @@
3
3
  module ViewComponent
4
4
  module VERSION
5
5
  MAJOR = 2
6
- MINOR = 16
6
+ MINOR = 17
7
7
  PATCH = 0
8
8
 
9
9
  STRING = [MAJOR, MINOR, PATCH].join(".")
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: view_component
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.16.0
4
+ version: 2.17.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - GitHub Open Source
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-07-15 00:00:00.000000000 Z
11
+ date: 2020-07-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport