Class: Riddler::Elements::Heading
Instance Attribute Summary
#context, #definition
Class Method Summary
collapse
Instance Method Summary
collapse
for, inherited, #initialize, subclasses
#include?, #include_predicate
Class Method Details
.type ⇒ Object
5
6
7
|
# File 'lib/riddler/elements/heading.rb', line 5
def self.type
"heading"
end
|
Instance Method Details
#text ⇒ Object
9
10
11
|
# File 'lib/riddler/elements/heading.rb', line 9
def text
context.render definition["text"]
end
|
#to_hash ⇒ Object
13
14
15
|
# File 'lib/riddler/elements/heading.rb', line 13
def to_hash
super.merge text: text
end
|