sequential-workflow-designer 0.35.0 → 0.35.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/dist/index.umd.js +4 -4
- package/lib/cjs/index.cjs +4 -4
- package/lib/esm/index.js +4 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -106,10 +106,10 @@ Add the below code to your head section in HTML document.
|
|
|
106
106
|
```html
|
|
107
107
|
<head>
|
|
108
108
|
...
|
|
109
|
-
<link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.35.
|
|
110
|
-
<link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.35.
|
|
111
|
-
<link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.35.
|
|
112
|
-
<script src="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.35.
|
|
109
|
+
<link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.35.1/css/designer.css" rel="stylesheet">
|
|
110
|
+
<link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.35.1/css/designer-light.css" rel="stylesheet">
|
|
111
|
+
<link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.35.1/css/designer-dark.css" rel="stylesheet">
|
|
112
|
+
<script src="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.35.1/dist/index.umd.js"></script>
|
|
113
113
|
```
|
|
114
114
|
|
|
115
115
|
Call the designer by:
|
package/dist/index.umd.js
CHANGED
|
@@ -435,7 +435,7 @@
|
|
|
435
435
|
this.cache = undefined;
|
|
436
436
|
};
|
|
437
437
|
}
|
|
438
|
-
find(vLt, vWidth, vHeight) {
|
|
438
|
+
find(vLt, vWidth, vHeight, vScale) {
|
|
439
439
|
var _a;
|
|
440
440
|
if (!this.cache) {
|
|
441
441
|
const scroll = new Vector(window.scrollX, window.scrollY);
|
|
@@ -452,8 +452,8 @@
|
|
|
452
452
|
});
|
|
453
453
|
this.cache.sort((a, b) => a.diagSq - b.diagSq);
|
|
454
454
|
}
|
|
455
|
-
const vR = vLt.x + vWidth;
|
|
456
|
-
const vB = vLt.y + vHeight;
|
|
455
|
+
const vR = vLt.x + vWidth * vScale;
|
|
456
|
+
const vB = vLt.y + vHeight * vScale;
|
|
457
457
|
return (_a = this.cache.find(p => {
|
|
458
458
|
return Math.max(vLt.x, p.lt.x) < Math.min(vR, p.br.x) && Math.max(vLt.y, p.lt.y) < Math.min(vB, p.br.y);
|
|
459
459
|
})) === null || _a === void 0 ? void 0 : _a.placeholder;
|
|
@@ -514,7 +514,7 @@
|
|
|
514
514
|
if (this.state) {
|
|
515
515
|
const newPosition = this.state.startPosition.subtract(delta).subtract(this.state.offset);
|
|
516
516
|
this.view.setPosition(newPosition);
|
|
517
|
-
const placeholder = this.state.finder.find(newPosition, this.view.component.width, this.view.component.height);
|
|
517
|
+
const placeholder = this.state.finder.find(newPosition, this.view.component.width, this.view.component.height, this.view.component.scale);
|
|
518
518
|
if (this.currentPlaceholder !== placeholder) {
|
|
519
519
|
if (this.currentPlaceholder) {
|
|
520
520
|
this.currentPlaceholder.setIsHover(false);
|
package/lib/cjs/index.cjs
CHANGED
|
@@ -433,7 +433,7 @@ class PlaceholderFinder {
|
|
|
433
433
|
this.cache = undefined;
|
|
434
434
|
};
|
|
435
435
|
}
|
|
436
|
-
find(vLt, vWidth, vHeight) {
|
|
436
|
+
find(vLt, vWidth, vHeight, vScale) {
|
|
437
437
|
var _a;
|
|
438
438
|
if (!this.cache) {
|
|
439
439
|
const scroll = new Vector(window.scrollX, window.scrollY);
|
|
@@ -450,8 +450,8 @@ class PlaceholderFinder {
|
|
|
450
450
|
});
|
|
451
451
|
this.cache.sort((a, b) => a.diagSq - b.diagSq);
|
|
452
452
|
}
|
|
453
|
-
const vR = vLt.x + vWidth;
|
|
454
|
-
const vB = vLt.y + vHeight;
|
|
453
|
+
const vR = vLt.x + vWidth * vScale;
|
|
454
|
+
const vB = vLt.y + vHeight * vScale;
|
|
455
455
|
return (_a = this.cache.find(p => {
|
|
456
456
|
return Math.max(vLt.x, p.lt.x) < Math.min(vR, p.br.x) && Math.max(vLt.y, p.lt.y) < Math.min(vB, p.br.y);
|
|
457
457
|
})) === null || _a === void 0 ? void 0 : _a.placeholder;
|
|
@@ -512,7 +512,7 @@ class DragStepBehavior {
|
|
|
512
512
|
if (this.state) {
|
|
513
513
|
const newPosition = this.state.startPosition.subtract(delta).subtract(this.state.offset);
|
|
514
514
|
this.view.setPosition(newPosition);
|
|
515
|
-
const placeholder = this.state.finder.find(newPosition, this.view.component.width, this.view.component.height);
|
|
515
|
+
const placeholder = this.state.finder.find(newPosition, this.view.component.width, this.view.component.height, this.view.component.scale);
|
|
516
516
|
if (this.currentPlaceholder !== placeholder) {
|
|
517
517
|
if (this.currentPlaceholder) {
|
|
518
518
|
this.currentPlaceholder.setIsHover(false);
|
package/lib/esm/index.js
CHANGED
|
@@ -432,7 +432,7 @@ class PlaceholderFinder {
|
|
|
432
432
|
this.cache = undefined;
|
|
433
433
|
};
|
|
434
434
|
}
|
|
435
|
-
find(vLt, vWidth, vHeight) {
|
|
435
|
+
find(vLt, vWidth, vHeight, vScale) {
|
|
436
436
|
var _a;
|
|
437
437
|
if (!this.cache) {
|
|
438
438
|
const scroll = new Vector(window.scrollX, window.scrollY);
|
|
@@ -449,8 +449,8 @@ class PlaceholderFinder {
|
|
|
449
449
|
});
|
|
450
450
|
this.cache.sort((a, b) => a.diagSq - b.diagSq);
|
|
451
451
|
}
|
|
452
|
-
const vR = vLt.x + vWidth;
|
|
453
|
-
const vB = vLt.y + vHeight;
|
|
452
|
+
const vR = vLt.x + vWidth * vScale;
|
|
453
|
+
const vB = vLt.y + vHeight * vScale;
|
|
454
454
|
return (_a = this.cache.find(p => {
|
|
455
455
|
return Math.max(vLt.x, p.lt.x) < Math.min(vR, p.br.x) && Math.max(vLt.y, p.lt.y) < Math.min(vB, p.br.y);
|
|
456
456
|
})) === null || _a === void 0 ? void 0 : _a.placeholder;
|
|
@@ -511,7 +511,7 @@ class DragStepBehavior {
|
|
|
511
511
|
if (this.state) {
|
|
512
512
|
const newPosition = this.state.startPosition.subtract(delta).subtract(this.state.offset);
|
|
513
513
|
this.view.setPosition(newPosition);
|
|
514
|
-
const placeholder = this.state.finder.find(newPosition, this.view.component.width, this.view.component.height);
|
|
514
|
+
const placeholder = this.state.finder.find(newPosition, this.view.component.width, this.view.component.height, this.view.component.scale);
|
|
515
515
|
if (this.currentPlaceholder !== placeholder) {
|
|
516
516
|
if (this.currentPlaceholder) {
|
|
517
517
|
this.currentPlaceholder.setIsHover(false);
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sequential-workflow-designer",
|
|
3
3
|
"description": "Customizable no-code component for building flow-based programming applications.",
|
|
4
|
-
"version": "0.35.
|
|
4
|
+
"version": "0.35.1",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./lib/esm/index.js",
|
|
7
7
|
"types": "./lib/index.d.ts",
|