Class: Tumblargh::Renderer::Blocks::Photos

Inherits:
Base show all
Defined in:
lib/tumblargh/renderer/blocks/photoset.rb

Overview

Rendered for each of the Photoset photos

Instance Attribute Summary

Attributes inherited from Tumblargh::Renderer::Base

#context, #node, #options

Instance Method Summary collapse

Methods inherited from Base

#should_render?

Methods inherited from Tumblargh::Renderer::Base

#context_post, contextual_tag, #escape_html, #escape_url, #initialize, #method_missing, #strip_html

Constructor Details

This class inherits a constructor from Tumblargh::Renderer::Base

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Tumblargh::Renderer::Base

Instance Method Details

#renderObject



13
14
15
16
17
18
19
20
21
22
# File 'lib/tumblargh/renderer/blocks/photoset.rb', line 13

def render
  if context.is_a? Resource::Photo
    super
  else
    context.photos.map do |photo|
      photo.context = self
      self.class.new(node, photo).render
    end.flatten.join('')
  end
end