quixotic-gol 0.1.5 → 0.1.7
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/dist/index.d.ts +21 -11
- package/dist/index.js +3 -3
- package/dist/index.mjs +1076 -1061
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -10,10 +10,10 @@ import { RefAttributes } from 'react';
|
|
|
10
10
|
export declare function createLayoutConfig(overrides?: Partial<LayoutConfig>): LayoutConfig;
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
|
-
* Decode a
|
|
14
|
-
*
|
|
15
|
-
* @param str - The
|
|
16
|
-
* @returns The
|
|
13
|
+
* Decode a JSON string that may be single or double-encoded.
|
|
14
|
+
* Tries direct parse first, then falls back to double-parse for double-encoded strings.
|
|
15
|
+
* @param str - The JSON string (either single or double-encoded)
|
|
16
|
+
* @returns The parsed object
|
|
17
17
|
*/
|
|
18
18
|
export declare function decodeDotString<T>(str: string): T;
|
|
19
19
|
|
|
@@ -41,12 +41,12 @@ declare interface DrawOp {
|
|
|
41
41
|
* Content structure for graph edges
|
|
42
42
|
*/
|
|
43
43
|
export declare interface EdgeContent {
|
|
44
|
-
/**
|
|
45
|
-
|
|
44
|
+
/** Index of the edge */
|
|
45
|
+
index: number;
|
|
46
46
|
/** Color of the edge */
|
|
47
47
|
color: string;
|
|
48
|
-
/** Text
|
|
49
|
-
|
|
48
|
+
/** Text elements on the edge */
|
|
49
|
+
elems: TextElem[];
|
|
50
50
|
}
|
|
51
51
|
|
|
52
52
|
/**
|
|
@@ -219,9 +219,9 @@ export declare interface NodeContent {
|
|
|
219
219
|
/** Tags associated with the node */
|
|
220
220
|
tags: string[];
|
|
221
221
|
/** Display label for the node */
|
|
222
|
-
label:
|
|
222
|
+
label: TextElem;
|
|
223
223
|
/** Text content of the node */
|
|
224
|
-
text:
|
|
224
|
+
text: TextElem;
|
|
225
225
|
}
|
|
226
226
|
|
|
227
227
|
export declare interface NodeMapping {
|
|
@@ -241,7 +241,7 @@ declare interface NodeMapping_2 {
|
|
|
241
241
|
* @param config - Layout configuration
|
|
242
242
|
* @returns Object containing zoom behavior and SVG references for imperative control
|
|
243
243
|
*/
|
|
244
|
-
export declare function renderCustomGraph(container: HTMLDivElement, json: GraphvizJson, _nodeMapping?: Record<string, NodeMapping_2>, maxDepth?: number | null, includeLesserDepths?: boolean, config?: LayoutConfig, useOrthogonalRendering?: boolean, svgFontSize?: number, debug?: boolean, selectedEdgeId?: number | null, onEdgeSelect?: (
|
|
244
|
+
export declare function renderCustomGraph(container: HTMLDivElement, json: GraphvizJson, _nodeMapping?: Record<string, NodeMapping_2>, maxDepth?: number | null, includeLesserDepths?: boolean, config?: LayoutConfig, useOrthogonalRendering?: boolean, svgFontSize?: number, debug?: boolean, selectedEdgeId?: number | null, onEdgeSelect?: (edgeIndex: number | null) => void, nodeWidth?: number, nodeHeight?: number, nodeColumnSpacing?: number): {
|
|
245
245
|
zoomBehavior: any;
|
|
246
246
|
svgElement: SVGSVGElement;
|
|
247
247
|
gElement: SVGGElement;
|
|
@@ -254,6 +254,16 @@ export declare function renderCustomGraph(container: HTMLDivElement, json: Graph
|
|
|
254
254
|
*/
|
|
255
255
|
export declare function setupZoomPan(container: HTMLDivElement): void;
|
|
256
256
|
|
|
257
|
+
/**
|
|
258
|
+
* Text element with optional color
|
|
259
|
+
*/
|
|
260
|
+
export declare interface TextElem {
|
|
261
|
+
/** Text content */
|
|
262
|
+
text: string;
|
|
263
|
+
/** Optional color for the text */
|
|
264
|
+
color?: string;
|
|
265
|
+
}
|
|
266
|
+
|
|
257
267
|
export declare function useGraphvizWorker(): UseGraphvizWorkerResult;
|
|
258
268
|
|
|
259
269
|
declare interface UseGraphvizWorkerResult {
|