Class: PandaCms::EditorJs::Blocks::Quote
- Defined in:
- app/lib/panda_cms/editor_js/blocks/quote.rb
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
Methods inherited from Base
Constructor Details
This class inherits a constructor from PandaCms::EditorJs::Blocks::Base
Instance Method Details
#render ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 16 |
# File 'app/lib/panda_cms/editor_js/blocks/quote.rb', line 5 def render text = sanitize(data["text"]) = sanitize(data["caption"]) alignment = data["alignment"] || "left" html_safe( "<figure class=\"text-#{alignment}\">" \ "<blockquote><p>#{text}</p></blockquote>" \ "#{()}" \ "</figure>" ) end |