src/expandCollapseUtilities.js
function (renderedPosition) {
    var pan = cy.pan();
    var zoom = cy.zoom();

    var x = (renderedPosition.x - pan.x) / zoom;
    var y = (renderedPosition.y - pan.y) / zoom;

    return {
      x: x,
      y: y
    };
  }
function (renderedPosition) {
    var pan = cy.pan();
    var zoom = cy.zoom();

    var x = (renderedPosition.x - pan.x) / zoom;
    var y = (renderedPosition.y - pan.y) / zoom;

    return {
      x: x,
      y: y
    };
  }
function ( renderedPosition ) { var pan = cy . pan ( ) ; var zoom = cy . zoom ( ) ; var x = ( renderedPosition . x - pan . x ) / zoom ; var y = ( renderedPosition . y - pan . y ) / zoom ; return { x : x , y : y } ; }
Converst the rendered position to model position according to global pan and zoom values
Converst the rendered position to model position according to global pan and zoom values