@denysvuika/ng-bpmn
TypeScript icon, indicating that this package has built-in type declarations

0.0.3 • Public • Published

Angular BPMN

Standalone BPMN components for your Angular applications.

Getting Started

Install the dependency:

npm i @DenysVuika/ng-bpmn

BPMN

<ng-bpmn [url]="diagramUrl" />

default

Keyboard Hotkeys

<ng-bpmn [url]="diagramUrl" [hotkeys]="true" />

Supported hotkeys:

Keys MacOS Action
Ctrl+a Command+a select all
e e direct editing
h h hand tool
l l lasso tool
s s space tool
c c global connect tool
Ctrl+= Command+= zoom in
Ctrl+- Command+- zoom out
Ctrl+0 Command+0 reset zoom
Ctrl+9 Command+9 zoom to fit
Ctrl+z Command+z undo
Ctrl+Shift+z Command+Shift+z redo
Backspace Backspace remove selection
Ctrl+c Command+c copy selection
Ctrl+v Command+v paste
Ctrl+x Command+x cut selection
Ctrl+f Command+f find

Invoking Component API

You can get the reference to the ng-bpmn component, and pass to the underlying application code.

For the sake of simplicity, some of the code was omitted.

app.component.html

<ng-bpmn #bpmn [url]="diagramUrl" />
<button (click)="exportSVG(bpmn)">Export SVG</button>

app.component.ts

import { saveAs } from 'file-saver';

export class AppComponent {
  exportSVG(bpmnComponent: NgBpmnComponent) {
    bpmnComponent.saveXML().then((content) => {
      if (content) {
        const blob = new Blob([content]);
        saveAs(blob, 'diagram.xml');
      }
    });
  }
}

Properties Panel

<ng-bpmn [url]="diagramUrl" [showProperties]="true" />

properties panel

Minimap

<ng-bpmn [url]="diagramUrl" [showProperties]="true" [showMinimap]="true" />

minimap

DMN

<ng-dmn [url]="diagramUrl" />

Properties Panel

<ng-dmn [url]="diagramUrl" [showProperties]="true" />

Keyboard Hotkeys

<ng-dmn [url]="diagramUrl" [hotkeys]="true" />

Supported hotkeys:

Keys MacOS Action
Ctrl+a Command+a select all
e e direct editing
h h hand tool
l l lasso tool
Ctrl+= Command+= zoom in
Ctrl+- Command+- zoom out
Ctrl+0 Command+0 reset zoom
Ctrl+9 Command+9 zoom to fit
Ctrl+z Command+z undo
Ctrl+Shift+z Command+Shift+z redo
Backspace Backspace remove selection

CMMN

<ng-cmmn [url]="diagramUrl" />

Properties Panel

<ng-cmmn [url]="diagramUrl" [showProperties]="true" />

Keyboard Hotkeys

<ng-cmmn [url]="diagramUrl" [hotkeys]="true" />

Supported hotkeys:

Keys MacOS Action
Ctrl+a Command+a select all
e e direct editing
h h hand tool
l l lasso tool
c c global connect tool
Ctrl+= Command+= zoom in
Ctrl+- Command+- zoom out
Ctrl+0 Command+0 reset zoom
Ctrl+9 Command+9 zoom to fit
Ctrl+z Command+z undo
Ctrl+Shift+z Command+Shift+z redo
Backspace Backspace remove selection
Ctrl+f Command+f find

Readme

Keywords

none

Package Sidebar

Install

npm i @denysvuika/ng-bpmn

Weekly Downloads

2

Version

0.0.3

License

MIT

Unpacked Size

738 kB

Total Files

57

Last publish

Collaborators

  • denysvuika