Class: PandaCms::EditorJs::Blocks::Header
- Defined in:
- app/lib/panda_cms/editor_js/blocks/header.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 |
# File 'app/lib/panda_cms/editor_js/blocks/header.rb', line 5 def render content = sanitize(data["text"]) level = data["level"] || 2 html_safe("<h#{level}>#{content}</h#{level}>") end |