MCPcopy Index your code
hub / github.com/hizzgdev/jsmind / _flow_node_direction

Method _flow_node_direction

src/jsmind.mind.js:207–217  ·  view source on GitHub ↗

* Propagate direction to descendants. * @param {Node} node * @param {('left'|'center'|'right'|'-1'|'0'|'1'|number)=} direction - Direction for node placement. Supports string values ('left', 'center', 'right'), numeric strings ('-1', '0', '1'), and numbers (-1, 0, 1)

(node, direction)

Source from the content-addressed store, hash-verified

205 * @param {('left'|'center'|'right'|'-1'|'0'|'1'|number)=} direction - Direction for node placement. Supports string values ('left', 'center', 'right'), numeric strings ('-1', '0', '1'), and numbers (-1, 0, 1)
206 */
207 _flow_node_direction(node, direction) {
208 if (typeof direction === 'undefined') {
209 direction = node.direction;
210 } else {
211 node.direction = direction;
212 }
213 var len = node.children.length;
214 while (len--) {
215 this._flow_node_direction(node.children[len], direction);
216 }
217 }
218 /**
219 * Re-index node among siblings based on before_id marker.
220 * @param {Node} node

Callers 2

_move_nodeMethod · 0.95
jsmind.jsFile · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected