A case-sensitive string representing the event type to listen for.
The object that receives a notification when an event of the specified type occurs. This must be a JavaScript function.
Occurs when node tree menu button is clicked. Use this event to modify the nodes in the tree menu.
var family = new FamilyTree('#tree', {});
family.onNodeTreeMenuShow((args) => {
});
Occurs when the node data has been updated, removed or added.
var family = new FamilyTree('#tree', {});
family.onUpdateNode((args) => {
//return false; to cancel the operation
});
Adds child and partner
id of the existing partner node
child data
partner data
called at the end of the animation
indicates if the update event will be called or not See doc...
Adds child
child node data
called at the end of the animation
indicates if the update event will be called or not See doc...
Adds parrent
node child id
mother or father
new added parent data
called at the end of the animation
indicates if the update event will be called or not See doc...
id of the existing partner node
ids of the child nodes
partner data
called at the end of the animation
indicates if the update event will be called or not See doc...
Adds partner node
data.pids partner id should be an existing id
new added partner data
called at the end of the animation
indicates if the update event will be called or not See doc...
Hides the tree menu
called at the end of the animation
Removes an event listener previously registered. The event listener to be removed is identified using a combination of the event type and the event listener function itself. Returns true if success and false if fail.
A string which specifies the type of event for which to remove an event listener
The event listener function of the event handler to remove from the event target
Removes node if the node can be removed
node id to be removed
called at the end of the animation
indicates if the update event will be called or not See doc...
Shows tree menu
node id
called at the end of the animation
Generated using TypeDoc
The on() method of the OrgChart class sets up a function that will be called whenever the specified event is delivered to the target. *