Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 | export interface Point {
x: number;
y: number;
}
export interface Bounds {
x: number;
y: number;
width: number;
height: number;
}
export interface ElementDimension {
width: number;
height: number;
}
export interface AutoLayoutOptions {
/**
* Primary flow direction. Defaults to 'horizontal' (left-to-right).
*/
direction?: 'horizontal' | 'vertical';
/**
* Grid channel spacing between nodes. Defaults to 60.
*/
gridSpacing?: number;
/**
* Whether to allow invalid sequence flows (e.g. cross-container or unresolvable endpoints)
* without throwing an error. Defaults to false.
*/
lenientFlowValidation?: boolean;
/**
* Additional Moddle extensions to register.
*/
moddleExtensions?: Record<string, any>;
/**
* Maximum width budget before wrapping flow nodes onto multiple rows.
*/
widthBudget?: number;
}
export interface HardViolations {
shapeOverlaps: number;
edgeShapeCrossings: number;
nonOrthogonalSegments: number;
}
export interface QualityMetrics {
totalBends: number;
totalEdgeLength: number;
edgeCrossings: number;
}
export interface ContainerCompactness {
id: string;
elementId: string;
width: number;
height: number;
area: number;
aspectRatio: number;
densityRatio: number;
}
export interface CompactnessMetrics {
width: number;
height: number;
area: number;
aspectRatio: number;
densityRatio: number;
containers: ContainerCompactness[];
}
export interface DiagramQualityScore {
hardViolations: HardViolations;
metrics: QualityMetrics;
compactness: CompactnessMetrics;
isValid: boolean;
}
export type { LayoutWarning, LayoutWarningCode } from './layout-warnings';
|