@ajuhos/react-flow-chart
Advanced tools
Comparing version 0.0.43 to 0.0.44
{ | ||
"name": "@ajuhos/react-flow-chart", | ||
"version": "0.0.43", | ||
"version": "0.0.44", | ||
"description": "A flexible, stateless flow chart library for react.", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -117,12 +117,15 @@ "use strict"; | ||
PortWrapper.prototype.updatePortPosition = function () { | ||
var el = this.nodeRef.current; | ||
if (el) { | ||
// Ports component should be positions absolute | ||
// Factor this in so we get position relative to the node | ||
var nodesEl = el.parentElement | ||
? el.parentElement | ||
: { offsetLeft: 0, offsetTop: 0 }; | ||
// update port position after node size has been determined | ||
this.props.onPortPositionChange({ config: this.props.config, node: this.props.node, port: this.props.port, el: el, nodesEl: nodesEl }); | ||
} | ||
var _this = this; | ||
window.setTimeout(function () { | ||
var el = _this.nodeRef.current; | ||
if (el) { | ||
// Ports component should be positions absolute | ||
// Factor this in so we get position relative to the node | ||
var nodesEl = el.parentElement | ||
? el.parentElement | ||
: { offsetLeft: 0, offsetTop: 0 }; | ||
// update port position after node size has been determined | ||
_this.props.onPortPositionChange({ config: _this.props.config, node: _this.props.node, port: _this.props.port, el: el, nodesEl: nodesEl }); | ||
} | ||
}, 200); | ||
}; | ||
@@ -129,0 +132,0 @@ PortWrapper.prototype.portsOfType = function (props) { |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
187529
2782