Module: Card::Set::Abstract::Media::HtmlFormat

Extended by:
Card::Set::AbstractFormat
Defined in:
card/tmpsets/set/mod020-card-mod-bar_and_box/abstract/media.rb,
card/tmpsets/set/mod021-card-mod-bar_and_box/abstract/media.rb

Instance Method Summary collapse

Instance Method Details

#image_cardObject



9
10
11
# File 'card/tmpsets/set/mod020-card-mod-bar_and_box/abstract/media.rb', line 9

def image_card
  @image_card ||= card.fetch(:image, new: {})
end

#text_with_image(opts = {}) ⇒ Object



13
14
15
16
17
# File 'card/tmpsets/set/mod020-card-mod-bar_and_box/abstract/media.rb', line 13

def text_with_image opts={}
  class_up "media-left", "m-2"
  @image_card = Card.cardish(opts[:image]) if opts[:image]
  haml :media_snippet, normalized_text_with_image_opts(opts)
end