JavaScript graph editor