Class: HtmlToProsemirror::Nodes::Node
- Inherits:
-
Object
- Object
- HtmlToProsemirror::Nodes::Node
- Defined in:
- lib/html_to_prosemirror/nodes/node.rb
Direct Known Subclasses
BulletList, CodeBlock, CodeBlockWrapper, HardBreak, Heading, Image, ListItem, OrderedList, Paragraph, Text, User
Instance Attribute Summary collapse
- #type ⇒ Object
-
#wrapper ⇒ Object
writeonly
Sets the attribute wrapper.
Instance Method Summary collapse
- #data ⇒ Object
-
#initialize(dom_node) ⇒ Node
constructor
A new instance of Node.
- #matching ⇒ Object
Constructor Details
#initialize(dom_node) ⇒ Node
Returns a new instance of Node.
12 13 14 |
# File 'lib/html_to_prosemirror/nodes/node.rb', line 12 def initialize(dom_node) @node = dom_node end |
Instance Attribute Details
#type ⇒ Object
8 9 10 |
# File 'lib/html_to_prosemirror/nodes/node.rb', line 8 def type @type || 'node' end |
#wrapper=(value) ⇒ Object (writeonly)
Sets the attribute wrapper
5 6 7 |
# File 'lib/html_to_prosemirror/nodes/node.rb', line 5 def wrapper=(value) @wrapper = value end |
Instance Method Details
#data ⇒ Object
20 21 22 |
# File 'lib/html_to_prosemirror/nodes/node.rb', line 20 def data {} end |
#matching ⇒ Object
16 17 18 |
# File 'lib/html_to_prosemirror/nodes/node.rb', line 16 def matching false end |