class Maglove::Widget::LegacyHeading
Public Instance Methods
defaults()
click to toggle source
# File lib/maglove/widget/heading.rb, line 24 def defaults { type: "h1", style: "default", align: "left", margin_bottom: "1em", line_height: nil, letter_spacing: nil, id: nil } end
identifier()
click to toggle source
# File lib/maglove/widget/heading.rb, line 20 def identifier "heading" end
render() { |self| ... }
click to toggle source
Calls superclass method
Maglove::Widget::V1#render
# File lib/maglove/widget/heading.rb, line 36 def render(&block) super do haml_tag :header, id: options[:id].to_s, class: "#{options[:style]} align-#{options[:align]}", style: style_string(options, :margin, :padding) do haml_tag options[:type], class: "_typeloft_editable _typeloft_widget_autoselect", style: style_string(options, :line_height, :letter_spacing) do yield self if block_given? end end end end