Christoph Cullmann 2024-04-28 17:33:09 +02:00
parent 4b35583782
commit e77051ccc4
1987 changed files with 1147290 additions and 5648 deletions

View file

@ -0,0 +1,8 @@
import type { Direction } from '../../src/diagrams/block/blockTypes.js';
export declare const getArrowPoints: (duplicatedDirections: Direction[], bbox: {
width: number;
height: number;
}, node: any) => {
x: any;
y: number;
}[];

View file

@ -0,0 +1,4 @@
export function insertCluster(elem: any, node: any): void;
export function getClusterTitleWidth(elem: any, node: any): number;
export function clear(): void;
export function positionCluster(node: any): void;

View file

@ -0,0 +1,9 @@
export default createLabel;
/**
* @param _vertexText
* @param style
* @param isTitle
* @param isNode
* @deprecated svg-util/createText instead
*/
declare function createLabel(_vertexText: any, style: any, isTitle: any, isNode: any): SVGTextElement | SVGForeignObjectElement;

View file

@ -0,0 +1,12 @@
import type { SVG } from '../diagram-api/types.js';
import type { EdgeData } from '../types.js';
/**
* Adds SVG markers to a path element based on the arrow types specified in the edge.
*
* @param svgPath - The SVG path element to add markers to.
* @param edge - The edge data object containing the arrow types.
* @param url - The URL of the SVG marker definitions.
* @param id - The ID prefix for the SVG marker definitions.
* @param diagramType - The type of diagram being rendered.
*/
export declare const addEdgeMarkers: (svgPath: SVG, edge: Pick<EdgeData, 'arrowTypeStart' | 'arrowTypeEnd'>, url: string, id: string, diagramType: string) => void;

View file

@ -0,0 +1 @@
export {};

View file

@ -0,0 +1,14 @@
export function clear(): void;
export function insertEdgeLabel(elem: any, edge: any): any;
export function positionEdgeLabel(edge: any, paths: any): void;
export function intersection(node: any, outsidePoint: any, insidePoint: any): {
x: any;
y: number;
} | {
x: number;
y: any;
};
export function insertEdge(elem: any, e: any, edge: any, clusterDb: any, diagramType: any, graph: any, id: any): {
updatedPath: any;
originalPath: any;
};

View file

@ -0,0 +1 @@
export function render(elem: any, graph: any, markers: any, diagramType: any, id: any): Promise<void>;

View file

@ -0,0 +1,13 @@
declare namespace _default {
export { node };
export { circle };
export { ellipse };
export { polygon };
export { rect };
}
export default _default;
import node from './intersect-node.js';
import circle from './intersect-circle.js';
import ellipse from './intersect-ellipse.js';
import polygon from './intersect-polygon.js';
import rect from './intersect-rect.js';

View file

@ -0,0 +1,10 @@
export default intersectCircle;
/**
* @param node
* @param rx
* @param point
*/
declare function intersectCircle(node: any, rx: any, point: any): {
x: any;
y: any;
};

View file

@ -0,0 +1,11 @@
export default intersectEllipse;
/**
* @param node
* @param rx
* @param ry
* @param point
*/
declare function intersectEllipse(node: any, rx: any, ry: any, point: any): {
x: any;
y: any;
};

View file

@ -0,0 +1,13 @@
export default intersectLine;
/**
* Returns the point at which two lines, p and q, intersect or returns undefined if they do not intersect.
*
* @param p1
* @param p2
* @param q1
* @param q2
*/
declare function intersectLine(p1: any, p2: any, q1: any, q2: any): {
x: number;
y: number;
} | undefined;

View file

@ -0,0 +1,6 @@
export default intersectNode;
/**
* @param node
* @param point
*/
declare function intersectNode(node: any, point: any): any;

View file

@ -0,0 +1,10 @@
export default intersectPolygon;
/**
* Returns the point ({x, y}) at which the point argument intersects with the node argument assuming
* that it has the shape specified by polygon.
*
* @param node
* @param polyPoints
* @param point
*/
declare function intersectPolygon(node: any, polyPoints: any, point: any): any;

View file

@ -0,0 +1,5 @@
export default intersectRect;
declare function intersectRect(node: any, point: any): {
x: any;
y: any;
};

View file

@ -0,0 +1,2 @@
export default insertMarkers;
declare function insertMarkers(elem: any, markerArray: any, type: any, id: any): void;

View file

@ -0,0 +1,8 @@
export let clusterDb: {};
export function clear(): void;
export function extractDescendants(id: any, graph: any): any[];
export function validate(graph: any): boolean;
export function findNonClusterChild(id: any, graph: any): any;
export function adjustClustersAndEdges(graph: any, depth: any): void;
export function extractor(graph: any, depth: any): void;
export function sortNodesByHierarchy(graph: any): any;

View file

@ -0,0 +1,4 @@
export function insertNode(elem: any, node: any, dir: any): Promise<any>;
export function setNodeElem(elem: any, node: any): void;
export function clear(): void;
export function positionNode(node: any): any;

View file

@ -0,0 +1,2 @@
export default note;
declare function note(parent: any, node: any): Promise<any>;

View file

@ -0,0 +1,14 @@
/**
* @param parent
* @param w
* @param h
* @param points
*/
export function insertPolygonShape(parent: any, w: any, h: any, points: any): any;
export function labelHelper(parent: any, node: any, _classes: any, isNode: any): Promise<{
shapeSvg: any;
bbox: any;
halfPadding: number;
label: any;
}>;
export function updateNodeBounds(node: any, element: any): void;