Code Monkey home page Code Monkey logo

flowbee's Introduction

flowbee

Simple, flexible, open flow diagramming.

See flowbee-demo.

Install

npm install --save flowbee

Themes

Themeable styles are here:
node_modules/flowbee/dist/style.css

Built-in themes are 'light' and 'dark'. You can override specific settings in these in your own css:

.flowbee-diagram-light .title {
  visibility: visible; /* show title in diagram */
}

Or you can create custom themes. For example, custom diagram theme styles should follow this pattern:
flowbee-diagram-<themename> By default your theme will extend flowbee-diagram-light styles. To extend flowbee-diagram-dark styles, your theme name should end with '-dark'.

Here's an ugly example:

.flowbee-diagram-garish {
  color: darkblue;
  background-color: pink;
}

.flowbee-diagram-garish .grid {
  color: yellow;
  width: 44px;
}

.flowbee-diagram-garish.line {
  width: 5px;
}

.flowbee-diagram-garish .step .start {
  background-color: purple;
}

To utilize your theme pass its name to FlowbeeDiagram.render():

flowDiagram.render('garish', contents, filename);

No Inline Styles

By default Flowbee uses inline styles via stylesheet injection. If you have a Content Security Policy and wish to avoid inline styles, you can point to the no-styles version of Flowbee:

import * as flowbee from '../node_modules/flowbee/dist/nostyles.js';

Then you'd want to separately include Flowbee's css in your HTML:

  <link href="flowbee/dist/css/style.css" rel="stylesheet" />

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.