All Projects → seeksdream → Relation Graph

seeksdream / Relation Graph

Licence: mit
Vue 关联关系图谱组件,可以展示如组织机构图谱、股权架构图谱、集团关系图谱等知识图谱,可提供多种图谱布局,包括树状布局、中心布局、力学布局自动布局等。Vue component for relationship graph , which can display knowledge graphs, such as organization graph, equity structure graph, group relationship graph,

Labels

Projects that are alternatives of or similar to Relation Graph

Graphview
Flutter GraphView is used to display data in graph structures. It can display Tree layout, Directed and Layered graph. Useful for Family Tree, Hierarchy View.
Stars: ✭ 152 (-8.43%)
Mutual labels:  graph
Neo4j 3d Force Graph
Experiments with Neo4j & 3d-force-graph https://github.com/vasturiano/3d-force-graph
Stars: ✭ 159 (-4.22%)
Mutual labels:  graph
Blocks.js
JavaScript dataflow graph editor
Stars: ✭ 165 (-0.6%)
Mutual labels:  graph
Backprop
Heterogeneous automatic differentiation ("backpropagation") in Haskell
Stars: ✭ 154 (-7.23%)
Mutual labels:  graph
Hgp Sl
Hierarchical Graph Pooling with Structure Learning
Stars: ✭ 159 (-4.22%)
Mutual labels:  graph
Alga Paper
A minimalistic, elegant and powerful approach to working with graphs in a functional programming language
Stars: ✭ 163 (-1.81%)
Mutual labels:  graph
Graphlib
Simple but powerful graph library for Rust
Stars: ✭ 148 (-10.84%)
Mutual labels:  graph
Dragon
Dragon: A Computation Graph Virtual Machine Based Deep Learning Framework.
Stars: ✭ 168 (+1.2%)
Mutual labels:  graph
Baklavajs
Graph / node editor in the browser using VueJS
Stars: ✭ 157 (-5.42%)
Mutual labels:  graph
Patches
Patches is a visual programming editor for building WebVR and WebGL experiences.
Stars: ✭ 164 (-1.2%)
Mutual labels:  graph
Graphembedding
Implementation and experiments of graph embedding algorithms.
Stars: ✭ 2,461 (+1382.53%)
Mutual labels:  graph
Boost graph cookbook 1
Boost.Graph Cookbook 1: Basics
Stars: ✭ 157 (-5.42%)
Mutual labels:  graph
Animatedgraph
Animated Graph which you can include in your application to show information in more attractive way
Stars: ✭ 162 (-2.41%)
Mutual labels:  graph
Graspologic
Python package for graph statistics
Stars: ✭ 153 (-7.83%)
Mutual labels:  graph
Algo Tree
Algo-Tree is a collection of Algorithms and data structures which are fundamentals to efficient code and good software design. Creating and designing excellent algorithms is required for being an exemplary programmer. It contains solutions in various languages such as C++, Python and Java.
Stars: ✭ 166 (+0%)
Mutual labels:  graph
Neo4j Php Ogm
Neo4j Object Graph Mapper for PHP
Stars: ✭ 151 (-9.04%)
Mutual labels:  graph
Awesome Graph Attack Papers
Adversarial attacks and defenses on Graph Neural Networks.
Stars: ✭ 162 (-2.41%)
Mutual labels:  graph
Awesome Gnn Recommendation
Graph Neural Network
Stars: ✭ 168 (+1.2%)
Mutual labels:  graph
Cargo Deps
Cargo subcommand for building dependency graphs of Rust projects
Stars: ✭ 168 (+1.2%)
Mutual labels:  graph
Diagram Maker
A library to display an interactive editor for any graph-like data.
Stars: ✭ 2,086 (+1156.63%)
Mutual labels:  graph

relation-graph

这是一个Vue关系图谱组件,可以展示如组织机构图谱、股权架构图谱、集团关系图谱等知识图谱,可提供多种图谱布局,包括树状布局、中心布局、力学布局自动布局等。

这个项目使用典型的vue编程方式,代码简单易懂。如果需要实现一些自定义的高级功能,你可以直接使用源码作为一个component放到你的项目中去用,轻松、任意的修改。

详细使用方法、配置选项、在线demo,以及可视化的配置工具,可以访问这个网址:

http://relation-graph.com


快速使用:

npm install --save relation-graph
<template>
   <div>
     <div style="height:calc(100vh - 50px);">
        <RelationGraph ref="seeksRelationGraph" :options="graphOptions" :on-node-click="onNodeClick" :on-line-click="onLineClick" />
     </div>
   </div>
 </template>
 
 <script>
 import RelationGraph from 'relation-graph'
 export default {
   name: 'Demo',
   components: { RelationGraph },
   data() {
     return {
       graphOptions: {
         allowSwitchLineShape: true,
         allowSwitchJunctionPoint: true,
         defaultJunctionPoint: 'border'
         // 这里可以参考"Graph 图谱"中的参数进行设置:http://relation-graph.com/#/docs/graph
       }
     }
   },
   mounted() {
     this.showSeeksGraph()
   },
   methods: {
     showSeeksGraph() {
       var __graph_json_data = {
         rootId: 'a',
         nodes: [
            // node配置选项:http://relation-graph.com/#/docs/node
            // node支持通过插槽slot完全自定义,示例:http://relation-graph.com/#/demo/adv-slot
           { id: 'a', text: 'A', borderColor: 'yellow' },
           { id: 'b', text: 'B', color: '#43a2f1', fontColor: 'yellow' },
           { id: 'c', text: 'C', nodeShape: 1, width: 80, height: 60 },
           { id: 'e', text: 'E', nodeShape: 0, width: 150, height: 150 }
         ],
         links: [
            // link配置选项:http://relation-graph.com/#/docs/link
           { from: 'a', to: 'b', text: '关系1', color: '#43a2f1' },
           { from: 'a', to: 'c', text: '关系2' },
           { from: 'a', to: 'e', text: '关系3' },
           { from: 'b', to: 'e', color: '#67C23A' }
         ]
       }
       this.$refs.seeksRelationGraph.setJsonData(__graph_json_data, (seeksRGGraph) => {
         // Called when the relation-graph is completed 
       })
     },
     onNodeClick(nodeObject, $event) {
       console.log('onNodeClick:', nodeObject)
     },
     onLineClick(lineObject, $event) {
       console.log('onLineClick:', lineObject)
     }
   }
 }
 </script>

上面代码的效果: 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图 简单示例效果图

更多效果及使用方法: http://relation-graph.com

最新版本v1.1.0:

修改问题:

  • 修复了ie浏览器下滚动轴只能放大无法缩小的问题
  • 修复了导出图片不全或留白太多的问题
  • 修复了工具栏按钮样式错误和节点的收缩按钮样式错误

新特性:


v1.0.9:

主要修改的问题:

  • 1,解决了当使用者没有使用element-ui时图谱工具栏样式异常的问题
  • 2,默认关闭组件中的打印信息,只有在设置debug时打印信息
  • 3,解决了_graph.removeNodeById方法的bug
  • 4,解决了当图谱大小调整后调用refresh方法无法让图谱位置居中的问题
  • 5,解决了当调整图谱大小后工具栏位置不自动调整的问题
  • 6,解决了无法将图谱数据放在Vue data()中的问题

新特性:

  • 1,提供一种新布局:固定位置布局《fixed/固定坐标布局》,介绍:http://relation-graph.com/#/docs/layout 示例:http://relation-graph.com/#/demo/layout-diy
  • 2,提供getGraphJsonData和getGraphJsonOptions方法,获取图谱中当前所有数据和配置信息的json数据
  • 3,提供图谱配置:禁用图谱缩放、禁用工具栏缩放按钮的配置
  • 4,提供节点配置:禁用节点拖拽、禁用节点点击的默认选中效果

这个项目使用典型的vue编程方式,代码简单易懂,如果需要实现一些高级功能,你还可以直接使用源码作为一个component放到你的项目中去用,如果有一些优化或者新特性,欢迎提交pull request。

如果这个项目能帮到大家,有更多的人关注,后续我会开发用于小程序、react、angular的版本,以及基于canvas的实现。

有问题可以加QQ:3235808353,提bug、提建议、一起交流分享前端开发心得,第一获取新版本发布消息。

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].