Skip to content

Commit 17fdaf9

Browse files
committed
fix direction issue for condition adrai#151
1 parent 7e74665 commit 17fdaf9

File tree

8 files changed

+25
-8
lines changed

8 files changed

+25
-8
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"author": "adrai",
33
"name": "flowchart.js",
4-
"version": "1.11.0",
4+
"version": "1.11.1",
55
"main": "./index",
66
"private": false,
77
"engines": {

release/flowchart.js

Lines changed: 4 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

release/flowchart.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

release/flowchart.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

release/flowchart.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

releasenotes.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
### v1.11.1
2+
3+
- fix direction issue for condition [#151](https://github.com/adrai/flowchart.js/issues/151)
4+
15
### v1.11.0
26

37
- Add parallel component [#145](https://github.com/adrai/flowchart.js/pull/145) thanks to [sudhakar-sekar](https://github.com/sudhakar-sekar)

site

src/flowchart.symbol.condition.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,17 @@ function Condition(chart, options) {
2929
this.yes_direction = 'right';
3030
this.no_direction = 'bottom';
3131
}
32+
} else if (options.yes && options.direction_yes && options.no && options.direction_no && options.direction_no !== options.direction_yes) {
33+
if (options.direction_yes === 'right') {
34+
this.no_direction = 'bottom';
35+
this.yes_direction = 'right';
36+
} else if (options.direction_yes === 'top') {
37+
this.no_direction = 'right';
38+
this.yes_direction = 'top';
39+
} else {
40+
this.no_direction = 'right';
41+
this.yes_direction = 'bottom';
42+
}
3243
} else {
3344
this.yes_direction = 'bottom';
3445
this.no_direction = 'right';

0 commit comments

Comments
 (0)