Class: ListElements::DefinitionDescription

Inherits:
ContainerElement
  • Object
show all
Defined in:
lib/reparcs/elements/list_elements.rb

Overview

A definition description element ‘<dd></dd>’ for use within a DefiniitonList. Use: define a definition.

Instance Method Summary collapse

Constructor Details

#initialize(attrs = {}) ⇒ DefinitionDescription

Create a new Definition, takes an optional hash of attributes as parameter.



31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# File 'lib/reparcs/elements/list_elements.rb', line 31

def initialize(attrs={})
  aattrs = [
    "class", "id", "title", "dir" ,"xml:lang",
    "onclick", "ondblclick", "onkeydown",
    "onkeypress", "onkeyup", "onmousedown",
    "onmousemove", "onmouseout", "onmouseover",
    "onmouseup"
  ]
  childs = [
    "a", "abbr", "acronym", "b" ,"bdo", "big",
    "blockquote", "br", "button", "cite", "code",
    "del", "dfn", "div", "dl", "fieldset", "form",
    "h1", "h2", "h3", "h4", "h5", "h6", "hr",
    "i", "img", "input", "ins", "kbd", "label",
    "map", "noscript", "object", "ol", "p", "pre",
    "q", "samp", "script", "select", "small", "span",
    "strong", "sub", "sup", "table", "textarea",
    "tt", "ul", "var"
  ]
  super("dd", aattrs, childs, attrs)
  @start_element = "<dd"
  @end_element = "</dd>"
end