Merge pull request #4038 from natasha-jarus/bug/missing-flowchart-curves

bugfix: add missing d3 curves to flowchart and docs
This commit is contained in:
Sidharth Vinod
2023-02-07 14:00:53 +05:30
committed by GitHub
4 changed files with 31 additions and 5 deletions

View File

@@ -842,8 +842,8 @@ In the example below the style defined in the linkStyle statement will belong to
### Styling line curves ### Styling line curves
It is possible to style the type of curve used for lines between items, if the default method does not meet your needs. It is possible to style the type of curve used for lines between items, if the default method does not meet your needs.
Available curve styles include `basis`, `bump`, `linear`, `monotoneX`, `monotoneY`, `natural`, `step`, `stepAfter`, Available curve styles include `basis`, `bumpX`, `bumpY`, `cardinal`, `catmullRom`, `linear`, `monotoneX`, `monotoneY`,
and `stepBefore`. `natural`, `step`, `stepAfter`, and `stepBefore`.
In this example, a left-to-right graph uses the `stepBefore` curve style: In this example, a left-to-right graph uses the `stepBefore` curve style:

View File

@@ -52,8 +52,16 @@ vi.mock('d3', () => {
curveBasis: 'basis', curveBasis: 'basis',
curveBasisClosed: 'basisClosed', curveBasisClosed: 'basisClosed',
curveBasisOpen: 'basisOpen', curveBasisOpen: 'basisOpen',
curveLinear: 'linear', curveBumpX: 'bumpX',
curveBumpY: 'bumpY',
curveBundle: 'bundle',
curveCardinalClosed: 'cardinalClosed',
curveCardinalOpen: 'cardinalOpen',
curveCardinal: 'cardinal', curveCardinal: 'cardinal',
curveCatmullRomClosed: 'catmullRomClosed',
curveCatmullRomOpen: 'catmullRomOpen',
curveCatmullRom: 'catmullRom',
curveLinear: 'linear',
curveLinearClosed: 'linearClosed', curveLinearClosed: 'linearClosed',
curveMonotoneX: 'monotoneX', curveMonotoneX: 'monotoneX',
curveMonotoneY: 'monotoneY', curveMonotoneY: 'monotoneY',

View File

@@ -552,8 +552,8 @@ linkStyle 3 stroke:#ff3,stroke-width:4px,color:red;
### Styling line curves ### Styling line curves
It is possible to style the type of curve used for lines between items, if the default method does not meet your needs. It is possible to style the type of curve used for lines between items, if the default method does not meet your needs.
Available curve styles include `basis`, `bump`, `linear`, `monotoneX`, `monotoneY`, `natural`, `step`, `stepAfter`, Available curve styles include `basis`, `bumpX`, `bumpY`, `cardinal`, `catmullRom`, `linear`, `monotoneX`, `monotoneY`,
and `stepBefore`. `natural`, `step`, `stepAfter`, and `stepBefore`.
In this example, a left-to-right graph uses the `stepBefore` curve style: In this example, a left-to-right graph uses the `stepBefore` curve style:

View File

@@ -4,6 +4,15 @@ import {
curveBasis, curveBasis,
curveBasisClosed, curveBasisClosed,
curveBasisOpen, curveBasisOpen,
curveBumpX,
curveBumpY,
curveBundle,
curveCardinalClosed,
curveCardinalOpen,
curveCardinal,
curveCatmullRomClosed,
curveCatmullRomOpen,
curveCatmullRom,
CurveFactory, CurveFactory,
curveLinear, curveLinear,
curveLinearClosed, curveLinearClosed,
@@ -28,6 +37,15 @@ const d3CurveTypes = {
curveBasis: curveBasis, curveBasis: curveBasis,
curveBasisClosed: curveBasisClosed, curveBasisClosed: curveBasisClosed,
curveBasisOpen: curveBasisOpen, curveBasisOpen: curveBasisOpen,
curveBumpX: curveBumpX,
curveBumpY: curveBumpY,
curveBundle: curveBundle,
curveCardinalClosed: curveCardinalClosed,
curveCardinalOpen: curveCardinalOpen,
curveCardinal: curveCardinal,
curveCatmullRomClosed: curveCatmullRomClosed,
curveCatmullRomOpen: curveCatmullRomOpen,
curveCatmullRom: curveCatmullRom,
curveLinear: curveLinear, curveLinear: curveLinear,
curveLinearClosed: curveLinearClosed, curveLinearClosed: curveLinearClosed,
curveMonotoneX: curveMonotoneX, curveMonotoneX: curveMonotoneX,