sequential-workflow-designer 0.19.2 → 0.19.3

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 CHANGED
@@ -43,6 +43,7 @@ Pro:
43
43
  * [🍬 Custom Theme Flat](https://nocode-js.com/examples/sequential-workflow-designer-pro/webpack-pro-app/public/custom-theme-flat.html)
44
44
  * [🌹 Custom Step Types](https://nocode-js.com/examples/sequential-workflow-designer-pro/webpack-pro-app/public/custom-step-types.html)
45
45
  * [📺 Popup Editor](https://nocode-js.com/examples/sequential-workflow-designer-pro/webpack-pro-app/public/popup-editor.html)
46
+ * [💼 Copy Paste](https://nocode-js.com/examples/sequential-workflow-designer-pro/webpack-pro-app/public/copy-paste.html)
46
47
  * [👈 Goto](https://nocode-js.com/examples/sequential-workflow-designer-pro/webpack-pro-app/public/goto.html)
47
48
  * [📁 Folders](https://nocode-js.com/examples/sequential-workflow-designer-pro/webpack-pro-app/public/folders.html)
48
49
  * [⭕ Wheel Mode](https://nocode-js.com/examples/sequential-workflow-designer-pro/webpack-pro-app/public/wheel-mode.html)
@@ -99,10 +100,10 @@ Add the below code to your head section in HTML document.
99
100
  ```html
100
101
  <head>
101
102
  ...
102
- <link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.19.2/css/designer.css" rel="stylesheet">
103
- <link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.19.2/css/designer-light.css" rel="stylesheet">
104
- <link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.19.2/css/designer-dark.css" rel="stylesheet">
105
- <script src="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.19.2/dist/index.umd.js"></script>
103
+ <link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.19.3/css/designer.css" rel="stylesheet">
104
+ <link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.19.3/css/designer-light.css" rel="stylesheet">
105
+ <link href="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.19.3/css/designer-dark.css" rel="stylesheet">
106
+ <script src="https://cdn.jsdelivr.net/npm/sequential-workflow-designer@0.19.3/dist/index.umd.js"></script>
106
107
  ```
107
108
 
108
109
  Call the designer by:
package/dist/index.umd.js CHANGED
@@ -1786,7 +1786,7 @@
1786
1786
  }
1787
1787
 
1788
1788
  const SCALES = [0.06, 0.08, 0.1, 0.12, 0.16, 0.2, 0.26, 0.32, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1];
1789
- const MAX_DELTA_Y = 16;
1789
+ const MAX_DELTA_Y$1 = 16;
1790
1790
  const quantifiedScale = new NextQuantifiedNumber(SCALES);
1791
1791
  class QuantifiedScaleViewportCalculator {
1792
1792
  static zoom(current, direction) {
@@ -1803,8 +1803,8 @@
1803
1803
  const nextScale = quantifiedScale.next(current.scale, e.deltaY < 0);
1804
1804
  let scale;
1805
1805
  const absDeltaY = Math.abs(e.deltaY);
1806
- if (absDeltaY < MAX_DELTA_Y) {
1807
- const fraction = absDeltaY / MAX_DELTA_Y;
1806
+ if (absDeltaY < MAX_DELTA_Y$1) {
1807
+ const fraction = absDeltaY / MAX_DELTA_Y$1;
1808
1808
  const step = nextScale.next - nextScale.current;
1809
1809
  scale = current.scale + step * fraction;
1810
1810
  }
@@ -3741,6 +3741,7 @@
3741
3741
  }
3742
3742
  }
3743
3743
 
3744
+ const MAX_DELTA_Y = 25;
3744
3745
  const listenerOptions = {
3745
3746
  passive: false
3746
3747
  };
@@ -3819,9 +3820,9 @@
3819
3820
  e.preventDefault();
3820
3821
  e.stopPropagation();
3821
3822
  if (this.content) {
3822
- const delta = e.deltaY > 0 ? -25 : 25;
3823
+ const delta = Math.sign(e.deltaY) * Math.min(Math.abs(e.deltaY), MAX_DELTA_Y);
3823
3824
  const scrollTop = this.getScrollTop();
3824
- this.setScrollTop(scrollTop + delta);
3825
+ this.setScrollTop(scrollTop - delta);
3825
3826
  }
3826
3827
  }
3827
3828
  startScroll(startPosition) {
package/lib/cjs/index.cjs CHANGED
@@ -1784,7 +1784,7 @@ class NextQuantifiedNumber {
1784
1784
  }
1785
1785
 
1786
1786
  const SCALES = [0.06, 0.08, 0.1, 0.12, 0.16, 0.2, 0.26, 0.32, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1];
1787
- const MAX_DELTA_Y = 16;
1787
+ const MAX_DELTA_Y$1 = 16;
1788
1788
  const quantifiedScale = new NextQuantifiedNumber(SCALES);
1789
1789
  class QuantifiedScaleViewportCalculator {
1790
1790
  static zoom(current, direction) {
@@ -1801,8 +1801,8 @@ class QuantifiedScaleViewportCalculator {
1801
1801
  const nextScale = quantifiedScale.next(current.scale, e.deltaY < 0);
1802
1802
  let scale;
1803
1803
  const absDeltaY = Math.abs(e.deltaY);
1804
- if (absDeltaY < MAX_DELTA_Y) {
1805
- const fraction = absDeltaY / MAX_DELTA_Y;
1804
+ if (absDeltaY < MAX_DELTA_Y$1) {
1805
+ const fraction = absDeltaY / MAX_DELTA_Y$1;
1806
1806
  const step = nextScale.next - nextScale.current;
1807
1807
  scale = current.scale + step * fraction;
1808
1808
  }
@@ -3556,6 +3556,7 @@ class SmartEditorExtension {
3556
3556
  }
3557
3557
  }
3558
3558
 
3559
+ const MAX_DELTA_Y = 25;
3559
3560
  const listenerOptions = {
3560
3561
  passive: false
3561
3562
  };
@@ -3634,9 +3635,9 @@ class ScrollBoxView {
3634
3635
  e.preventDefault();
3635
3636
  e.stopPropagation();
3636
3637
  if (this.content) {
3637
- const delta = e.deltaY > 0 ? -25 : 25;
3638
+ const delta = Math.sign(e.deltaY) * Math.min(Math.abs(e.deltaY), MAX_DELTA_Y);
3638
3639
  const scrollTop = this.getScrollTop();
3639
- this.setScrollTop(scrollTop + delta);
3640
+ this.setScrollTop(scrollTop - delta);
3640
3641
  }
3641
3642
  }
3642
3643
  startScroll(startPosition) {
package/lib/esm/index.js CHANGED
@@ -1783,7 +1783,7 @@ class NextQuantifiedNumber {
1783
1783
  }
1784
1784
 
1785
1785
  const SCALES = [0.06, 0.08, 0.1, 0.12, 0.16, 0.2, 0.26, 0.32, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1];
1786
- const MAX_DELTA_Y = 16;
1786
+ const MAX_DELTA_Y$1 = 16;
1787
1787
  const quantifiedScale = new NextQuantifiedNumber(SCALES);
1788
1788
  class QuantifiedScaleViewportCalculator {
1789
1789
  static zoom(current, direction) {
@@ -1800,8 +1800,8 @@ class QuantifiedScaleViewportCalculator {
1800
1800
  const nextScale = quantifiedScale.next(current.scale, e.deltaY < 0);
1801
1801
  let scale;
1802
1802
  const absDeltaY = Math.abs(e.deltaY);
1803
- if (absDeltaY < MAX_DELTA_Y) {
1804
- const fraction = absDeltaY / MAX_DELTA_Y;
1803
+ if (absDeltaY < MAX_DELTA_Y$1) {
1804
+ const fraction = absDeltaY / MAX_DELTA_Y$1;
1805
1805
  const step = nextScale.next - nextScale.current;
1806
1806
  scale = current.scale + step * fraction;
1807
1807
  }
@@ -3555,6 +3555,7 @@ class SmartEditorExtension {
3555
3555
  }
3556
3556
  }
3557
3557
 
3558
+ const MAX_DELTA_Y = 25;
3558
3559
  const listenerOptions = {
3559
3560
  passive: false
3560
3561
  };
@@ -3633,9 +3634,9 @@ class ScrollBoxView {
3633
3634
  e.preventDefault();
3634
3635
  e.stopPropagation();
3635
3636
  if (this.content) {
3636
- const delta = e.deltaY > 0 ? -25 : 25;
3637
+ const delta = Math.sign(e.deltaY) * Math.min(Math.abs(e.deltaY), MAX_DELTA_Y);
3637
3638
  const scrollTop = this.getScrollTop();
3638
- this.setScrollTop(scrollTop + delta);
3639
+ this.setScrollTop(scrollTop - delta);
3639
3640
  }
3640
3641
  }
3641
3642
  startScroll(startPosition) {
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.19.2",
4
+ "version": "0.19.3",
5
5
  "type": "module",
6
6
  "main": "./lib/esm/index.js",
7
7
  "types": "./lib/index.d.ts",