Module: Maglove::Widgets::YahooScreen::Helpers

Defined in:
lib/maglove/widgets/yahoo_screen.rb

Instance Method Summary collapse

Instance Method Details

#yahoo_screen_widget(options = {}, &block) ⇒ Object



17
18
19
20
21
22
23
# File 'lib/maglove/widgets/yahoo_screen.rb', line 17

def yahoo_screen_widget(options = {}, &block)
  widget_block(Widgets::YahooScreen.new(options)) do |widget|
    haml_tag :div, class: "flex-video widescreen", style: style_string(widget.options, :margin, :padding) do
      haml_tag :iframe, src: "http://screen.yahoo.com/#{widget.options[:yahoo_screen_id]}.html?format=embed", type: "text/html", style: "max-width: 100%; position: absolute; top: 0px; left: 0px; width: 100%; height: 100%;", allowfullscreen: "", frameborder: "0", webkitallowfullscreen: "", mozallowfullscreen: ""
    end
  end
end