string |
label
The text for the label.
|
string |
labelElId
The derived element id of the label for this node
|
string |
labelStyle
The CSS class for the label href.
|
Class YAHOO.widget.TextNode
Object | +--YAHOO.widget.Node | +--YAHOO.widget.TextNode
- Direct Known Subclasses:
- YAHOO.widget.MenuNode
class
YAHOO.widget.TextNode
Field Summary [top]
Fields inherited from class YAHOO.widget.Node [top]
Constructor Summary [top]
YAHOO.widget.TextNode
The default node presentation.
Method Summary [top]
object |
getLabelEl
()
Returns the label element
|
Object |
getNodeHtml
()
Get the markup for the node.
|
Object |
onLabelClick
(me)
Executed when the label is clicked
|
void |
setUpLabel
(oData)
Sets up the node label
|
Object |
toString
()
toString
|
Methods inherited from class YAHOO.widget.Node
init, applyParent, appendTo, insertBefore, insertAfter, getSiblings, showChildren, hideChildren, getElId, getChildrenElId, getToggleElId, getEl, getChildrenEl, getToggleEl, getToggleLink, collapse, expand, getStyle, getHoverStyle, expandAll, collapseAll, setDynamicLoad, isRoot, isDynamic, getIconMode, hasChildren, toggle, getHtml, completeRender, loadComplete, getAncestor, getDepthStyle, refresh
Field Detail [top]
label
string
label
The text for the label. It is assumed that the oData parameter will
either be a string that will be used as the label, or an object that
has a property called "label" that we will use.
labelElId
string
labelElId
The derived element id of the label for this node
labelStyle
string
labelStyle
The CSS class for the label href. Defaults to ygtvlabel, but can be
overridden to provide a custom presentation for a specific node.
Constructor Detail [top]
YAHOO.widget.TextNode
YAHOO.widget.TextNode
()
The default node presentation. The first parameter should be
either a string that will be used as the node's label, or an object
that has a string propery called label. By default, the clicking the
label will toggle the expanded/collapsed state of the node. By
changing the href property of the instance, this behavior can be
changed so that the label will go to the specified href.
- Parameters:
-
oData
- {object} a string or object containing the data that will be used to render this node -
oParent
- {YAHOO.widget.Node} this node's parent node -
expanded
- {boolean} the initial expanded/collapsed state
Method Detail [top]
getLabelEl
object
getLabelEl
()
Returns the label element
- Returns:
- the element
getNodeHtml
Object
getNodeHtml
()
Get the markup for the node. This is designed to be overrided so that we can
support different types of nodes.
- Returns:
- The HTML that will render this node.
onLabelClick
Object
onLabelClick
(me)
Executed when the label is clicked
- Parameters:
-
me
- {Node} this node
- Returns:
- false to cancel the anchor click
setUpLabel
void
setUpLabel
(oData)
Sets up the node label
- Parameters:
-
oData
- string containing the label, or an object with a label property
toString
Object
toString
()
toString
- Returns:
- string representation of the node