All Projects → bitterbit → flowjs

bitterbit / flowjs

Licence: MIT license
FlowJS allows you to render dynamic, animated flow charts using HTML5 canvas

Programming Languages

javascript
184084 projects - #8 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to flowjs

awesome-canvas
Canvas资源库大全中文版。An awesome Canvas packages and resources.
Stars: ✭ 288 (+464.71%)
Mutual labels:  html5-canvas, flowchart
Gown.js
UI system for pixi.js inspired by feathers-ui
Stars: ✭ 195 (+282.35%)
Mutual labels:  html5-canvas
Phaser Kinetic Scrolling Plugin
Kinetic Scrolling plugin for Canvas using Phaser Framework
Stars: ✭ 117 (+129.41%)
Mutual labels:  html5-canvas
Jsmind
Javascript version of mind mapping
Stars: ✭ 2,254 (+4319.61%)
Mutual labels:  html5-canvas
Canvas Text Editor Tutorial
Simple text editor using html5 canvas
Stars: ✭ 130 (+154.9%)
Mutual labels:  html5-canvas
Audiomotion.js
High-resolution real-time spectrum analyzer and music player using Web Audio and Canvas APIs.
Stars: ✭ 177 (+247.06%)
Mutual labels:  html5-canvas
The Matrix Effect
The incredible effect of rain of letters in the style of the Matrix trilogy.
Stars: ✭ 109 (+113.73%)
Mutual labels:  html5-canvas
Rough
Create graphics with a hand-drawn, sketchy, appearance
Stars: ✭ 16,472 (+32198.04%)
Mutual labels:  html5-canvas
Nude.js
Nudity detection with JavaScript and HTMLCanvas
Stars: ✭ 2,236 (+4284.31%)
Mutual labels:  html5-canvas
C4
🔴🔵 Connect Four game in JS + Canvas
Stars: ✭ 156 (+205.88%)
Mutual labels:  html5-canvas
Node Tileserver
A lightweight tileserver based on NodeJS for serving bitmap and vector tiles.
Stars: ✭ 148 (+190.2%)
Mutual labels:  html5-canvas
Vue Canvas Nest
💫 A Vue.js background component for canvas-nest.
Stars: ✭ 136 (+166.67%)
Mutual labels:  html5-canvas
Mednes
A cycle-accurate, cross-platform NES emulator written in C++
Stars: ✭ 189 (+270.59%)
Mutual labels:  html5-canvas
Tap Tap Adventure
Tap Tap Adventure is a massively online 2D MMORPG set in the medieval times with twists.
Stars: ✭ 123 (+141.18%)
Mutual labels:  html5-canvas
Codetest
🐷个人代码库,日常JS代码都在这里,防止电脑数据丢失。。。0.0。更新内容请关注README.md
Stars: ✭ 204 (+300%)
Mutual labels:  html5-canvas
Foster Ts
A WebGL + TypeScript 2D Game framework with a Scene>Entity>Component model.
Stars: ✭ 112 (+119.61%)
Mutual labels:  html5-canvas
Wechat Turntalbe Canvas
用微信小程序开发的Canvas绘制可配置的转盘抽奖。
Stars: ✭ 144 (+182.35%)
Mutual labels:  html5-canvas
Classic Pool Game
Classic 8 Ball pool game written in JavaScript
Stars: ✭ 177 (+247.06%)
Mutual labels:  html5-canvas
product-person
Interactive tool based on “What you should be looking for in a product person” by Uri Haramati
Stars: ✭ 21 (-58.82%)
Mutual labels:  html5-canvas
One Html Page Challenge
Can you create something cool without modern tools?
Stars: ✭ 205 (+301.96%)
Mutual labels:  html5-canvas

FlowJS

Simple HTML5 flow chart using the canvas element.
FlowJS allows you to render dynamic, animated flow charts using HTML5 canvas with the help of CreateJs.
No more complex graphs and endles zooming. Any contribution or suggestion will be welcomed

Visit https://prufer.surge.sh/ for a live demo! (using flowjs to display prufer trees)

Usage

flow chart example

<script type="text/javascript" src="lib/createjs-2015.05.21.min.js"></script>
<script type="text/javascript" src="flow.min.js"></script>
<canvas id="canvasID" width="500" height="300"></canvas>
var graph = new flowjs.DiGraph();
graph.addPaths([
    ["Peter Q", "Gamora", "Nova Prime", "Rocket"],
    ["Drax", "Groot", "Rocket"],
    ["Merdith Q", "Groot"]
]);

new flowjs.DiFlowChart("canvasID", graph).draw();

Advanced Usage

Here we show how to update a node after we draw it We simulate an app the loads data about the node in the background and when its ready, updates the displayed chart

flow chart loading example

var graph = new flowjs.DiGraph();
// ... init the graph
new flowjs.DiFlowChart(graph, "canvasID").draw();


// this function simulates loading a flow chart and coloring parts of it
// we simulate loading using the setTimeout function 
function simuLoad(flowChart, graph){
    // helps walk over all the graphs nodes
    var walker = new flowjs.GraphWalker(graph);
    
    walker.forEach(function(node){
        var start = Math.random() * 1000 * 5;
        var dur = Math.random() * 1000 * 5;
        simulateLoading(node.id, start);
        simulateDoneLoading(node.id, start + dur);
    }, this);
    
    
    // start running an animation on the given iten
    function simulateLoading(itemId, timeout){
        setTimeout(function(){
            flowChart.updateItem(itemId, function(item){
                item.flowItem.toggleFlashing();
            });
        }, timeout);
        
    }
    
    // stop the animation on the item and color it
    function simulateDoneLoading(itemId, timeout){
        setTimeout(function(){
            flowChart.updateItem(itemId, function(item){
                item.flowItem.toggleFlashing();
                item.flowItem.color = "cyan";
                if (item.connectors === undefined){return;}
                item.connectors.forEach(function(conn){
                   conn.color = "cyan"; 
                });
            });
        }, timeout);
    }
}

License

flowjs is available under the MIT License

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].