Extends
Classes
Methods
# addDomElement(tag) → {object}
Add a DOM element with an optional CSS class.
Parameters:
Name | Type | Description |
---|---|---|
tag |
string
|
The HTML tag to be created. |
- Overrides:
The DOM element.
object
# addElementClasslist(classList)
Helper method for adding classes to an DOM element.
Parameters:
Name | Type | Description |
---|---|---|
classList |
string
|
One ore more class names separated with spaces. |
- Overrides:
# build()
Build the DOM element(s) of a customized component.
This method has to be overriden by derived classes.
- Overrides:
# buildDOM(selector)
Build Document from all components, starting from the view.
Parameters:
Name | Type | Description |
---|---|---|
selector |
string
|
DOM selector to the element, where to mount the app. |
- Overrides:
# countDescendants() → {number}
Count all descendant components.
Descendants are children, grandchildren, and so on.
- Overrides:
Number of descendants.
number
# createDomElement(tag) → {object}
Create a DOM element with an optional CSS class.
Parameters:
Name | Type | Description |
---|---|---|
tag |
string
|
The HTML tag to be created. |
- Overrides:
The DOM element.
object
# getComponentById(id) → {Component}
Get component by id.
Parameters:
Name | Type | Description |
---|---|---|
id |
string
|
The id of the component to find. |
- Overrides:
The found component or null, if no component has the given id.
# getDomElement(selector) → {HTMLElement}
Retrieve an element from the DOM.
Parameters:
Name | Type | Description |
---|---|---|
selector |
string
|
DOM selector to the element. |
- Overrides:
The DOM element or null.
HTMLElement
# getPropertyNames(customPropertyNames) → {array}
Get property names.
Parameters:
Name | Type | Description |
---|---|---|
customPropertyNames |
array
|
An array with the names of a derived class. |
- Overrides:
An array with property names or undefined, if no properties exist.
array
# handleMessage(message)
Handles a message send to the component.
Parameters:
Name | Type | Description |
---|---|---|
message |
string
|
The message to be handled. |
- Overrides:
# propertiesChanged()
Update component after changes to it.
This method has to be overriden by derived classes.
This method will be called, when properties has been changed.
The component has to reflect the changes in its visual representation.
- Overrides:
# setProperties(data)
Set component properties by data.
Parameters:
Name | Type | Description |
---|---|---|
data |
array
|
An array with data in the form of name/value pairs. |
- Overrides: