diff --git a/dist/ReactGraph.css b/dist/ReactGraph.css index c9f1d064..1ab30709 100644 --- a/dist/ReactGraph.css +++ b/dist/ReactGraph.css @@ -60,7 +60,7 @@ width: 100%; height: 100%; position: absolute; - z-index: 2; + z-index: 3; pointer-events: none; transform-origin: 0 0; } diff --git a/dist/ReactGraph.js b/dist/ReactGraph.js index 542ddbcd..32b33fec 100644 --- a/dist/ReactGraph.js +++ b/dist/ReactGraph.js @@ -204,6 +204,10 @@ return element.data && element.data.source && element.data.target; }; var parseElements = function parseElements(e) { + if (isEdge(e)) { + return e; + } + return _objectSpread2({}, e, { __rg: { position: e.position, @@ -32893,6 +32897,7 @@ className: nodeClasses, ref: nodeElement, style: { + zIndex: selected ? 10 : 3, transform: "translate(".concat(position.x, "px,").concat(position.y, "px)") }, onClick: function onClick(e) { diff --git a/example/index.html b/example/index.html index 8ac422f9..323a4f14 100644 --- a/example/index.html +++ b/example/index.html @@ -4,6 +4,7 @@ +