code: function click(e) {
        if (!self.settings('eventsEnabled'))
          return;
  
        // Generic event
        self.dispatchEvent('click', e);
  
        // Are we on a node?
        var element = new Element(e.target);
  
        if (element.isNode())
          self.dispatchEvent('clickNode', {
            node: graph.nodes(element.attr('data-node-id'))
          });
        else
          self.dispatchEvent('clickStage');
  
        e.preventDefault();
        e.stopPropagation();
      }
docs: Click