view_component 2.56.2 → 2.57.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 +4 -4
- data/docs/CHANGELOG.md +14 -0
- data/lib/view_component/base.rb +6 -2
- data/lib/view_component/version.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a22d7248560f80072ed000776afa4f92b164cd80931570feb4a3416bb6ba3627
|
4
|
+
data.tar.gz: 9bc617ae2ff51bad6f61b41412b4b3827c4bbe3f2366e0a3829ee00216d9518d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 648585993d06389775c8d14edee060fc551394edadaa7337a4b10709183941f9143cad71dc045ec4dca50db5bd568b8b57066518c0222e32e569f89e787043af
|
7
|
+
data.tar.gz: 4c8fbee2640a2fba303ce93010bdf789cbe094f233e7253dc4491207cadd3101914d86ae22c4b85e7c3db78b18e048b14955b41ce86ceb510fd4495e6ef216dc
|
data/docs/CHANGELOG.md
CHANGED
@@ -9,6 +9,20 @@ title: Changelog
|
|
9
9
|
|
10
10
|
## main
|
11
11
|
|
12
|
+
## 2.57.0
|
13
|
+
|
14
|
+
* Add missing `require` for `Translatable` module in `Base`.
|
15
|
+
|
16
|
+
*Hans Lemuet*
|
17
|
+
|
18
|
+
* Allow anything that responds to `#render_in` to be rendered in the parent component's view context.
|
19
|
+
|
20
|
+
*Cameron Dutro*
|
21
|
+
|
22
|
+
* Fix script/release so it honors semver.
|
23
|
+
|
24
|
+
*Cameron Dutro*
|
25
|
+
|
12
26
|
## 2.56.2
|
13
27
|
|
14
28
|
* Restore removed `rendered_component`, marking it for deprecation in v3.0.0.
|
data/lib/view_component/base.rb
CHANGED
@@ -9,6 +9,7 @@ require "view_component/polymorphic_slots"
|
|
9
9
|
require "view_component/previewable"
|
10
10
|
require "view_component/slotable"
|
11
11
|
require "view_component/slotable_v2"
|
12
|
+
require "view_component/translatable"
|
12
13
|
require "view_component/with_content_helper"
|
13
14
|
|
14
15
|
module ViewComponent
|
@@ -182,8 +183,11 @@ module ViewComponent
|
|
182
183
|
#
|
183
184
|
# @private
|
184
185
|
def render(options = {}, args = {}, &block)
|
185
|
-
if options.
|
186
|
-
options.
|
186
|
+
if options.respond_to?(:render_in)
|
187
|
+
if options.is_a?(ViewComponent::Base)
|
188
|
+
options.__vc_original_view_context = __vc_original_view_context
|
189
|
+
end
|
190
|
+
|
187
191
|
super
|
188
192
|
else
|
189
193
|
__vc_original_view_context.render(options, args, &block)
|
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.
|
4
|
+
version: 2.57.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: 2022-06-
|
11
|
+
date: 2022-06-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|