@skydesign/tf 0.3.5 → 0.3.6
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 +46 -0
- package/dist/index.js +1 -1
- package/dist/index.mjs +475 -425
- package/dist/{render-SK2uaqmj.mjs → render-CyerC-P0.mjs} +645 -630
- package/dist/{render-aoKrPS96.js → render-DP-7B8CP.js} +3 -3
- package/dist/server.d.ts +18 -0
- package/dist/server.js +3 -3
- package/dist/server.mjs +66 -61
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -296,6 +296,45 @@ export declare interface LayoutConfig {
|
|
|
296
296
|
nearlyAlignedThreshold: number;
|
|
297
297
|
}
|
|
298
298
|
|
|
299
|
+
/**
|
|
300
|
+
* The frame showing the whole graph content with the standard padding — the
|
|
301
|
+
* initial minimap viewBox before the client starts tracking the viewport.
|
|
302
|
+
*/
|
|
303
|
+
export declare function minimapContentFrame(viewBoxWidth: number, viewBoxHeight: number): {
|
|
304
|
+
x: number;
|
|
305
|
+
y: number;
|
|
306
|
+
w: number;
|
|
307
|
+
h: number;
|
|
308
|
+
};
|
|
309
|
+
|
|
310
|
+
/** One grey rounded block per node. */
|
|
311
|
+
export declare function MinimapNodeBlocks({ nodes }: MinimapSceneProps): JSX.Element;
|
|
312
|
+
|
|
313
|
+
export declare interface MinimapSceneProps {
|
|
314
|
+
/** Non-virtual node boxes in SVG coordinates (`RenderResult.nodeBounds`). */
|
|
315
|
+
nodes: NodeBounds[];
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
/**
|
|
319
|
+
* SSR first-paint minimap: node blocks framed on the graph content. The
|
|
320
|
+
* viewport mask needs the live container size and transform, so it only
|
|
321
|
+
* appears once the client `Minimap` takes over.
|
|
322
|
+
*/
|
|
323
|
+
export declare function MinimapStatic({ nodes, viewBoxWidth, viewBoxHeight }: MinimapStaticProps): JSX.Element;
|
|
324
|
+
|
|
325
|
+
export declare interface MinimapStaticProps extends MinimapSceneProps {
|
|
326
|
+
viewBoxWidth: number;
|
|
327
|
+
viewBoxHeight: number;
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
/** Axis-aligned box in SVG coordinates (y grows downward). */
|
|
331
|
+
export declare interface NodeBounds {
|
|
332
|
+
x: number;
|
|
333
|
+
y: number;
|
|
334
|
+
width: number;
|
|
335
|
+
height: number;
|
|
336
|
+
}
|
|
337
|
+
|
|
299
338
|
/**
|
|
300
339
|
* Content structure for graph nodes
|
|
301
340
|
*/
|
|
@@ -396,8 +435,15 @@ declare interface RenderResult {
|
|
|
396
435
|
gElement: SVGGElement;
|
|
397
436
|
baseFontSize: number;
|
|
398
437
|
viewBoxWidth: number;
|
|
438
|
+
viewBoxHeight: number;
|
|
399
439
|
edges: EdgeInfo[];
|
|
400
440
|
initialTransform: InitialTransform;
|
|
441
|
+
/**
|
|
442
|
+
* Non-virtual node boxes in SVG coordinates — the minimap scene data.
|
|
443
|
+
* Computed from the layout model (not getBBox), so headless renders
|
|
444
|
+
* produce the exact same values as the browser.
|
|
445
|
+
*/
|
|
446
|
+
nodeBounds: NodeBounds[];
|
|
401
447
|
}
|
|
402
448
|
|
|
403
449
|
/**
|