render_parent 0.0.6 → 0.0.7

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: 05f854b5c56d02e9463b1960fbb42d371daa260c
4
- data.tar.gz: 474071be6019acd892b1e4de2ddad62aefa2fcf3
3
+ metadata.gz: 7a6a7c509bb7cd2ca896ade76896f000c7bdba34
4
+ data.tar.gz: cca2f96a37664f288580cf40c4069331191c79b9
5
5
  SHA512:
6
- metadata.gz: f81d87a55e53e30088f94c8492068d5c4d0cbb18ca4042f6209fb53de50096b016f4e53da77988ee6633c3d0f84f12587ed21037e4d7d8608954c5ddedd5ba57
7
- data.tar.gz: 8f5443fe9f5243130204fa65e17c8a6a9299bd9937e69fbcca1ecb2f71b0decd226a504282027086a4eeabff813bc282870b3ef51d961d8dd307ecf01c4b2b0a
6
+ metadata.gz: bc86d10ec052c53447d0b69b2b039d93ce05e6219e0fb8ba5dcb57527f7c27b92412c035572b36dd79c525fe1ab650d9a1b20340d460c2fe4f2a837c23c2fce5
7
+ data.tar.gz: 484d0fedf8e276573c6ef3b75f3f95d376123888981c6867839dbf1b7c8fa9f50db18e75472cdb850556ab263f1aacbdd6c8c6d1a0e210fc2b93e0d7c28ca129
data/Rakefile CHANGED
@@ -18,7 +18,7 @@ Jeweler::Tasks.new do |gem|
18
18
  gem.homepage = "http://github.com/anteo/render-parent"
19
19
  gem.license = "MIT"
20
20
  gem.summary = %Q{Adds Rails "render :parent" helper, which renders template with the same name as current but higher on the view path}
21
- gem.description = %Q{This version adds Rails 4 compatibility}
21
+ gem.description = %Q{This version fixes render_collection}
22
22
  gem.email = "anton.argirov@gmail.com"
23
23
  gem.authors = ["Anton Argirov"]
24
24
  gem.files = Dir.glob('lib/**/*.rb') + %w(.document Gemfile LICENSE.txt README.rdoc Rakefile VERSION)
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.6
1
+ 0.0.7
@@ -1,5 +1,5 @@
1
1
  require 'action_view/helpers/rendering_helper'
2
- require 'action_view/renderer/template_renderer'
2
+ require 'action_view/template'
3
3
 
4
4
  ActionView::Helpers::RenderingHelper.module_eval do
5
5
  def render_parent_template(locals = {}, &block)
@@ -51,26 +51,14 @@ ActionView::PathSet.class_eval do
51
51
  alias_method_chain :find_all, :exclusions
52
52
  end
53
53
 
54
- ActionView::TemplateRenderer.class_eval do
55
- def render_template_with_active_template(template, layout_name = nil, locals = {})
56
- template_stack = @view.controller.respond_to?(:active_template_stack) && @view.controller.active_template_stack
57
- template_stack.push(template) if template_stack
58
- result = render_template_without_active_template( template, layout_name, locals)
54
+ ActionView::Template.class_eval do
55
+ def render_with_active_template(view, locals, buffer=nil, &block)
56
+ template_stack = view.controller.respond_to?(:active_template_stack) && view.controller.active_template_stack
57
+ template_stack.push(self) if template_stack
58
+ result = render_without_active_template(view, locals, buffer, &block)
59
59
  template_stack.pop if template_stack
60
60
  result
61
61
  end
62
62
 
63
- alias_method_chain :render_template, :active_template
63
+ alias_method_chain :render, :active_template
64
64
  end
65
-
66
- ActionView::PartialRenderer.class_eval do
67
- def render_partial_with_active_template
68
- template_stack = @view.controller.respond_to?(:active_template_stack) && @view.controller.active_template_stack
69
- template_stack.push(@template) if template_stack
70
- result = render_partial_without_active_template
71
- template_stack.pop if template_stack
72
- result
73
- end
74
-
75
- alias_method_chain :render_partial, :active_template
76
- end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: render_parent
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.6
4
+ version: 0.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anton Argirov
@@ -52,7 +52,7 @@ dependencies:
52
52
  - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
- description: This version adds Rails 4 compatibility
55
+ description: This version fixes render_collection
56
56
  email: anton.argirov@gmail.com
57
57
  executables: []
58
58
  extensions: []