@yggy-tech/graphraum 0.28.0 → 0.34.0
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/README.md +1 -1
- package/dist/index.d.ts +184 -7
- package/dist/index.js +1312 -200
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -65,7 +65,7 @@ Publishing is automated with semantic-release after CI succeeds on `main`. Commi
|
|
|
65
65
|
|
|
66
66
|
## Documentation
|
|
67
67
|
|
|
68
|
-
The [documentation](https://domudev.github.io/graphraum/), [API reference](https://domudev.github.io/graphraum/
|
|
68
|
+
The [documentation](https://domudev.github.io/graphraum/), [API reference](https://domudev.github.io/graphraum/reference/api/), and the live [playground](https://domudev.github.io/graphraum/playground/) with the Prove benchmark are published on GitHub Pages. Run them locally with:
|
|
69
69
|
|
|
70
70
|
```sh
|
|
71
71
|
bun install --cwd docs
|
package/dist/index.d.ts
CHANGED
|
@@ -3,6 +3,8 @@ import Graph from "graphology";
|
|
|
3
3
|
type GraphraumColor = number | string;
|
|
4
4
|
type GraphraumMode = "2d" | "3d";
|
|
5
5
|
type GraphraumNodeState = "dimmed" | "focused" | "hovered" | "selected";
|
|
6
|
+
/** Application-owned edge state applied with `setEdgeState`. Edge selection uses `setEdgeSelection`. */
|
|
7
|
+
type GraphraumEdgeState = "dimmed";
|
|
6
8
|
type GraphraumNodeShape = "circle" | "diamond" | "hexagon" | "pill" | "rounded" | "square" | "triangle";
|
|
7
9
|
interface GraphraumPosition {
|
|
8
10
|
x: number;
|
|
@@ -18,6 +20,11 @@ interface GraphraumNodeGeometry {
|
|
|
18
20
|
id: string;
|
|
19
21
|
position: GraphraumPosition;
|
|
20
22
|
color?: GraphraumColor;
|
|
23
|
+
/**
|
|
24
|
+
* Opt-in soft halo in 0..1 (default 0, none). Glowing nodes add one batched draw call;
|
|
25
|
+
* see the visual-language docs for the radius and opacity mapping.
|
|
26
|
+
*/
|
|
27
|
+
glow?: number;
|
|
21
28
|
height?: number;
|
|
22
29
|
shape?: GraphraumNodeShape;
|
|
23
30
|
size?: number;
|
|
@@ -28,6 +35,7 @@ interface GraphraumNodeGeometry {
|
|
|
28
35
|
type GraphraumNode<NodeAttributes = undefined> = GraphraumNodeGeometry & GraphraumAttributes<NodeAttributes>;
|
|
29
36
|
interface GraphraumNodeUpdate {
|
|
30
37
|
color?: GraphraumColor | undefined;
|
|
38
|
+
glow?: number | undefined;
|
|
31
39
|
height?: number | undefined;
|
|
32
40
|
id: string;
|
|
33
41
|
position?: GraphraumPosition;
|
|
@@ -72,6 +80,11 @@ interface GraphraumDataPatch<NodeAttributes = undefined, EdgeAttributes = undefi
|
|
|
72
80
|
}
|
|
73
81
|
interface GraphraumNodeVisual {
|
|
74
82
|
color?: GraphraumColor;
|
|
83
|
+
/**
|
|
84
|
+
* Opt-in soft halo in 0..1 (default 0, none). Glowing nodes add one batched draw call;
|
|
85
|
+
* see the visual-language docs for the radius and opacity mapping.
|
|
86
|
+
*/
|
|
87
|
+
glow?: number;
|
|
75
88
|
height?: number;
|
|
76
89
|
shape?: GraphraumNodeShape;
|
|
77
90
|
size?: number;
|
|
@@ -194,6 +207,10 @@ type GraphraumBackground = GraphraumColor | GraphraumPatternBackground | "transp
|
|
|
194
207
|
type GraphraumThemeName = "dark" | "light";
|
|
195
208
|
interface GraphraumTheme {
|
|
196
209
|
background: GraphraumBackground;
|
|
210
|
+
/** Color of edges dimmed with `setEdgeState("dimmed", ids)`. Selected edges stay selected. */
|
|
211
|
+
dimmedEdge: GraphraumColor;
|
|
212
|
+
/** Opacity cap (0..1) for dimmed edges; an edge that is already fainter keeps its own opacity. */
|
|
213
|
+
dimmedEdgeOpacity: number;
|
|
197
214
|
dimmedNode: GraphraumColor;
|
|
198
215
|
edge: GraphraumColor;
|
|
199
216
|
edgeOpacity: number;
|
|
@@ -227,8 +244,27 @@ interface GraphraumOptions<NodeAttributes = undefined, EdgeAttributes = undefine
|
|
|
227
244
|
viewportOverscan?: number;
|
|
228
245
|
visuals?: GraphraumVisualMapper<NodeAttributes, EdgeAttributes>;
|
|
229
246
|
}
|
|
247
|
+
/** Options for `Graphraum.setAutoOrbit`. */
|
|
248
|
+
interface GraphraumAutoOrbitOptions {
|
|
249
|
+
/** Orbit speed in radians per second. Must be above 0 and at most 2. Defaults to 0.07 (about 90 seconds per turn). */
|
|
250
|
+
speed?: number;
|
|
251
|
+
/** Idle time in milliseconds after a pointer, wheel or key interaction before the orbit resumes. Defaults to 3000. */
|
|
252
|
+
resumeAfterMs?: number;
|
|
253
|
+
}
|
|
254
|
+
/** Options for `Graphraum.flyTo`. */
|
|
255
|
+
interface GraphraumFlyToOptions {
|
|
256
|
+
/** Nodes to frame, as `fitView({ nodeIds })` frames them. Unknown IDs are ignored. */
|
|
257
|
+
nodeIds: readonly string[];
|
|
258
|
+
/** Flight time in milliseconds. 0 jumps. Defaults to 1200. */
|
|
259
|
+
durationMs?: number;
|
|
260
|
+
/** Multiplies the fitted 3D camera distance or 2D visible height; above 1 leaves air around the nodes. Defaults to 1. */
|
|
261
|
+
distanceScale?: number;
|
|
262
|
+
}
|
|
263
|
+
/** `off`: not enabled. `active`: orbiting with a running frame loop. `paused`: enabled but stopped by interaction, a hidden tab or an off-screen canvas. */
|
|
264
|
+
type GraphraumAutoOrbitStatus = "active" | "off" | "paused";
|
|
230
265
|
interface GraphraumDiagnostics {
|
|
231
266
|
aggregatedNodeClusters: number;
|
|
267
|
+
autoOrbit: GraphraumAutoOrbitStatus;
|
|
232
268
|
cpuFrameMilliseconds: number;
|
|
233
269
|
gpuFrameMilliseconds: number | null;
|
|
234
270
|
gpuDrawCalls: number;
|
|
@@ -236,6 +272,7 @@ interface GraphraumDiagnostics {
|
|
|
236
272
|
gpuTextures: number;
|
|
237
273
|
lodLevel: "density" | "detail" | "overview";
|
|
238
274
|
pickingStrategy: "raycaster-3d" | "spatial-grid-2d";
|
|
275
|
+
dimmedEdges: number;
|
|
239
276
|
selectedEdges: number;
|
|
240
277
|
selectedNodes: number;
|
|
241
278
|
totalEdges: number;
|
|
@@ -244,6 +281,8 @@ interface GraphraumDiagnostics {
|
|
|
244
281
|
visibleEdgeMarkers: number;
|
|
245
282
|
visibleEdgeSegments: number;
|
|
246
283
|
visibleEdges: number;
|
|
284
|
+
/** Glow halo instances in the final frame (at most 256; 0 in the density LOD tier). */
|
|
285
|
+
visibleGlowNodes: number;
|
|
247
286
|
visibleNodes: number;
|
|
248
287
|
visibleNodeCandidates: number;
|
|
249
288
|
}
|
|
@@ -262,6 +301,11 @@ interface EndpointOutline {
|
|
|
262
301
|
interface TrimEdgeEndpointsInput {
|
|
263
302
|
attach?: EndpointAttach;
|
|
264
303
|
clearance?: number;
|
|
304
|
+
/**
|
|
305
|
+
* `3d` trims along the 3D segment so ends meet camera-facing outlines; exact for circles,
|
|
306
|
+
* approximate for other shapes. Default `2d`.
|
|
307
|
+
*/
|
|
308
|
+
mode?: GraphraumMode;
|
|
265
309
|
source: GraphraumPosition;
|
|
266
310
|
sourceOutline: EndpointOutline;
|
|
267
311
|
target: GraphraumPosition;
|
|
@@ -270,8 +314,16 @@ interface TrimEdgeEndpointsInput {
|
|
|
270
314
|
/**
|
|
271
315
|
* Walk from the node center toward the far point and stop on the outline,
|
|
272
316
|
* then pull back by `clearance` so the stroke is not stabbed.
|
|
317
|
+
*
|
|
318
|
+
* In `2d` the outline lies in the xy plane, so only the xy part of the chord counts. In `3d` the
|
|
319
|
+
* billboard faces the camera, so the edge stops one outline radius from the center along the 3D
|
|
320
|
+
* segment. The radius is measured along the chord's world xy heading (or +x when the chord is
|
|
321
|
+
* parallel to z), not along its on-screen heading. For circles the radius is the same in every
|
|
322
|
+
* direction, so the projected end lies on the outline or inside it (where the node covers the
|
|
323
|
+
* edge) from every view. Other shapes are approximate in 3D: an elongated or angular node can end
|
|
324
|
+
* inside its outline or short of it, depending on the camera.
|
|
273
325
|
*/
|
|
274
|
-
declare function attachPointOnOutline(center: GraphraumPosition, far: GraphraumPosition, outline: EndpointOutline, clearance?: number): GraphraumPosition;
|
|
326
|
+
declare function attachPointOnOutline(center: GraphraumPosition, far: GraphraumPosition, outline: EndpointOutline, clearance?: number, mode?: GraphraumMode): GraphraumPosition;
|
|
275
327
|
/** Trim both ends of a center-to-center chord (or curve endpoints) to node boundaries. */
|
|
276
328
|
declare function trimEdgeEndpoints(input: TrimEdgeEndpointsInput): {
|
|
277
329
|
source: GraphraumPosition;
|
|
@@ -294,6 +346,12 @@ interface ForceLayoutRequest {
|
|
|
294
346
|
*/
|
|
295
347
|
linkDistances?: Float32Array;
|
|
296
348
|
nodeCount: number;
|
|
349
|
+
/**
|
|
350
|
+
* Optional cluster index per node (`nodeCount` values). `createForceSimulation()` seeds nodes
|
|
351
|
+
* around cluster centres and pulls each node towards its cluster centroid
|
|
352
|
+
* (`settings.clusterStrength`). A copy is stored; the array is never mutated.
|
|
353
|
+
*/
|
|
354
|
+
clusters?: Uint32Array;
|
|
297
355
|
settings?: ForceSettings;
|
|
298
356
|
/**
|
|
299
357
|
* Optional spring strength per edge (`edges.length / 2` values).
|
|
@@ -303,19 +361,29 @@ interface ForceLayoutRequest {
|
|
|
303
361
|
}
|
|
304
362
|
interface ForceSettings {
|
|
305
363
|
centerAttraction: number;
|
|
364
|
+
/**
|
|
365
|
+
* Pull of every node towards its cluster centroid, scaled by the step alpha.
|
|
366
|
+
* `0` disables the pull. Ignored without `clusters`.
|
|
367
|
+
* Omitted → `DEFAULT_FORCE_SETTINGS.clusterStrength`.
|
|
368
|
+
*/
|
|
369
|
+
clusterStrength?: number;
|
|
306
370
|
damping: number;
|
|
307
371
|
linkDistance: number;
|
|
308
372
|
repulsion: number;
|
|
309
373
|
springStrength: number;
|
|
310
374
|
}
|
|
311
|
-
declare const DEFAULT_FORCE_SETTINGS: ForceSettings
|
|
375
|
+
declare const DEFAULT_FORCE_SETTINGS: Required<ForceSettings>;
|
|
312
376
|
declare function forceIterationCount(nodeCount: number): number;
|
|
313
377
|
declare function createForceSimulation(request: ForceLayoutRequest): {
|
|
314
378
|
readonly nodeCount: number;
|
|
315
379
|
readonly edges: Uint32Array<ArrayBuffer>;
|
|
316
380
|
readonly positions: Float32Array<ArrayBuffer>;
|
|
317
|
-
/**
|
|
318
|
-
|
|
381
|
+
/**
|
|
382
|
+
* Add nodes while preserving every existing position and velocity. A simulation created with
|
|
383
|
+
* `clusters` requires one cluster index per added node (a new id starts a new cluster); a
|
|
384
|
+
* simulation created without clusters rejects them.
|
|
385
|
+
*/
|
|
386
|
+
addNodes(count: number, initial?: Float32Array, addedClusters?: Uint32Array): number;
|
|
319
387
|
/** Append endpoint indices for new edges; existing edge indices remain stable. */
|
|
320
388
|
addEdges(nextEdges: Uint32Array): void;
|
|
321
389
|
step(alpha: number): void;
|
|
@@ -420,12 +488,16 @@ declare class Graphraum<NodeAttributes = undefined, EdgeAttributes = undefined>
|
|
|
420
488
|
private nodeMesh;
|
|
421
489
|
private nodePickMesh;
|
|
422
490
|
private edgeMesh;
|
|
491
|
+
private readonly glowLayer;
|
|
492
|
+
private hasGlowNodes;
|
|
423
493
|
private nodeCapacity;
|
|
424
494
|
private edgeCapacity;
|
|
425
495
|
private markerCapacity;
|
|
426
496
|
private edgeInstanceCapacity;
|
|
427
497
|
private selectedNodeIds;
|
|
428
498
|
private selectedEdgeIds;
|
|
499
|
+
private dimmedEdgeIds;
|
|
500
|
+
private edgeIndexCache;
|
|
429
501
|
private hoveredNodeIds;
|
|
430
502
|
private focusedNodeIds;
|
|
431
503
|
private dimmedNodeIds;
|
|
@@ -446,6 +518,12 @@ declare class Graphraum<NodeAttributes = undefined, EdgeAttributes = undefined>
|
|
|
446
518
|
private edgeSegmentCapacity;
|
|
447
519
|
private mode;
|
|
448
520
|
private frameRequest;
|
|
521
|
+
private autoOrbit;
|
|
522
|
+
private flight;
|
|
523
|
+
private readonly flightDirection;
|
|
524
|
+
/** True only during the orbit's own `controls.update(dt)`; see `handleViewChange`. */
|
|
525
|
+
private orbitUpdating;
|
|
526
|
+
private destroyed;
|
|
449
527
|
private cpuFrameMilliseconds;
|
|
450
528
|
private gpuFrameMilliseconds;
|
|
451
529
|
private gpuTimer;
|
|
@@ -469,8 +547,28 @@ declare class Graphraum<NodeAttributes = undefined, EdgeAttributes = undefined>
|
|
|
469
547
|
/** Patches GPU edge instances for moved endpoints when the visible edge set is unchanged. */
|
|
470
548
|
private patchVisibleEdgeEndpoints;
|
|
471
549
|
setSelection(nodeIds: Iterable<string>): void;
|
|
472
|
-
/**
|
|
550
|
+
/**
|
|
551
|
+
* Highlights edges without changing node selection or source graph data. Unknown IDs are ignored.
|
|
552
|
+
* Only the instance colors of edges whose selection changed are rewritten and uploaded.
|
|
553
|
+
*/
|
|
473
554
|
setEdgeSelection(edgeIds: Iterable<string>): void;
|
|
555
|
+
/**
|
|
556
|
+
* Applies an application-owned edge state without changing source graph data. `dimmed` uses
|
|
557
|
+
* `theme.dimmedEdge` / `theme.dimmedEdgeOpacity`; selected edges stay selected. Unknown IDs are ignored.
|
|
558
|
+
*/
|
|
559
|
+
setEdgeState(state: GraphraumEdgeState, edgeIds: Iterable<string>): void;
|
|
560
|
+
private knownEdgeIds;
|
|
561
|
+
/**
|
|
562
|
+
* Visible slots, LOD tier, and geometry only change through materialize or endpoint patches,
|
|
563
|
+
* which keep `visibleEdgeLayouts` current, so a state change repaints in place. If a layout no
|
|
564
|
+
* longer fits the drawn instances, that invariant broke: fall back to a full materialize.
|
|
565
|
+
*/
|
|
566
|
+
private repaintEdgeStates;
|
|
567
|
+
private edgeStateStyling;
|
|
568
|
+
/** Edge ID to compiled index, rebuilt only when the edge list is replaced. */
|
|
569
|
+
private edgeIndicesById;
|
|
570
|
+
/** Drops edge states whose edges left the graph. */
|
|
571
|
+
private pruneEdgeStates;
|
|
474
572
|
/** Applies an application-owned visual state without changing source graph data. */
|
|
475
573
|
setNodeState(state: GraphraumNodeState, nodeIds: Iterable<string>): void;
|
|
476
574
|
/** One-hop neighbor node ids via incident edges (undirected adjacency). */
|
|
@@ -481,6 +579,14 @@ declare class Graphraum<NodeAttributes = undefined, EdgeAttributes = undefined>
|
|
|
481
579
|
render(): void;
|
|
482
580
|
setMode(mode: GraphraumMode): void;
|
|
483
581
|
getMode(): GraphraumMode;
|
|
582
|
+
/**
|
|
583
|
+
* Slowly orbits the 3D camera around its target until called with `false`. The orbit pauses while
|
|
584
|
+
* the camera controls handle a drag, pinch or wheel step and resumes after `resumeAfterMs` of idle;
|
|
585
|
+
* it also stops while the document is hidden or the canvas is off screen. While it is active a
|
|
586
|
+
* frame loop renders every frame (no viewport rematerialization), so check `prefers-reduced-motion`
|
|
587
|
+
* before enabling it. Throws in 2D mode; `setMode("2d")` turns it off. Does nothing after `destroy()`.
|
|
588
|
+
*/
|
|
589
|
+
setAutoOrbit(options: GraphraumAutoOrbitOptions | false): void;
|
|
484
590
|
getNodePresentation(nodeId: string): CompiledGraphraumPresentation | null;
|
|
485
591
|
/** Returns canvas-relative screen coordinates for a node, or null when the node does not exist. */
|
|
486
592
|
getNodeScreenPosition(nodeId: string): GraphraumScreenPosition | null;
|
|
@@ -514,13 +620,70 @@ declare class Graphraum<NodeAttributes = undefined, EdgeAttributes = undefined>
|
|
|
514
620
|
* the node pick mesh then the edge instance mesh.
|
|
515
621
|
*/
|
|
516
622
|
pickHit(clientX: number, clientY: number): GraphraumPickHit | null;
|
|
517
|
-
|
|
623
|
+
/** Frames every node, or only `nodeIds`; unknown ids are ignored and no match frames all nodes. Cancels a running `flyTo`. */
|
|
624
|
+
fitView(options?: {
|
|
625
|
+
nodeIds?: readonly string[];
|
|
626
|
+
}): void;
|
|
627
|
+
/**
|
|
628
|
+
* Animates the camera to frame `nodeIds` as `fitView({ nodeIds })` would, with an ease-in-out
|
|
629
|
+
* over `durationMs`. In 3D the camera and the orbit target move together and keep the current
|
|
630
|
+
* view direction, so a running auto-orbit carries on around the new target, at the fitted
|
|
631
|
+
* distance times `distanceScale`. In 2D it pans and zooms. Resolves `true` on arrival and
|
|
632
|
+
* `false` when cancelled by canvas pointer, wheel or key input, another `flyTo`, `fitView`,
|
|
633
|
+
* `setData`, `setMode`, a 2D resize or `destroy()`. Unknown IDs are ignored; when none match,
|
|
634
|
+
* or after `destroy()`, it resolves `false` without moving. With `prefers-reduced-motion:
|
|
635
|
+
* reduce` or a zero duration it jumps. Throws for an invalid duration or distance scale.
|
|
636
|
+
*/
|
|
637
|
+
flyTo(options: GraphraumFlyToOptions): Promise<boolean>;
|
|
638
|
+
/** Nodes whose id is in `nodeIds`, in graph order; every node when `nodeIds` is omitted. */
|
|
639
|
+
private nodesWithIds;
|
|
640
|
+
/** The closest front-view camera that frames `nodes` (issue #124); applies the container aspect. */
|
|
641
|
+
private perspectiveFit;
|
|
642
|
+
/**
|
|
643
|
+
* A 3D flight keeps the view direction it reads from the camera every frame, so an orbit step
|
|
644
|
+
* between frames turns the flight with it. The destination distance is the front-view fit
|
|
645
|
+
* distance; near and far span both ends while flying, and the far plane at arrival still holds
|
|
646
|
+
* the whole graph so the rest of it stays visible around the framed nodes.
|
|
647
|
+
*/
|
|
648
|
+
private planPerspectiveFlight;
|
|
649
|
+
/**
|
|
650
|
+
* A 2D flight switches to the destination frustum up front with a zoom that keeps the current
|
|
651
|
+
* view, then pans and eases the zoom back to 1, so it lands exactly on the fitted frustum.
|
|
652
|
+
*/
|
|
653
|
+
private planOrthographicFlight;
|
|
654
|
+
/** Largest distance from `center` to any node's far edge. */
|
|
655
|
+
private graphRadiusAround;
|
|
656
|
+
/** Steps a running flight to the frame time; settles and resolves it at the end. */
|
|
657
|
+
private advanceFlight;
|
|
658
|
+
private readonly cancelFlight;
|
|
518
659
|
setTheme(theme: Partial<GraphraumTheme> | GraphraumThemeName): void;
|
|
519
660
|
setBackground(background: GraphraumBackground): void;
|
|
520
661
|
resize(): void;
|
|
521
662
|
destroy(): void;
|
|
522
663
|
private readonly requestRender;
|
|
664
|
+
/** Renders a pending frame now instead of on the next animation frame. */
|
|
665
|
+
private flushRender;
|
|
666
|
+
private renderFrame;
|
|
667
|
+
private stopAutoOrbit;
|
|
668
|
+
/**
|
|
669
|
+
* One orbit frame. `autoRotate` is on only for this `update(dt)` call: OrbitControls also calls
|
|
670
|
+
* `update()` without a delta from wheel and key handlers and `fitView`, which would otherwise add
|
|
671
|
+
* a fixed per-call rotation. A moved camera emits `change` (a render request only, see
|
|
672
|
+
* `handleViewChange`); flushing that request renders this frame instead of the next one. During
|
|
673
|
+
* a `flyTo` the orbit still turns the camera but leaves the pending frame to the flight, which
|
|
674
|
+
* steps from the turned direction before it renders. A
|
|
675
|
+
* throwing update, render or view listener turns the orbit off rather than leaving it enabled
|
|
676
|
+
* without a loop.
|
|
677
|
+
*/
|
|
678
|
+
private readonly stepAutoOrbit;
|
|
523
679
|
private readGpuTimers;
|
|
680
|
+
/**
|
|
681
|
+
* Orbit frames skip materialization. In 3D the packed instances do not depend on camera
|
|
682
|
+
* orientation: there is no viewport culling, density LOD and edge tiers follow counts only,
|
|
683
|
+
* and the one orientation-dependent value (`worldUnitsPerPixel`, for edge hit slop) is used
|
|
684
|
+
* only by 2D picking. 3D picking raycasts the instances and screen positions are projected per
|
|
685
|
+
* call, so an orbit frame needs only a render, whose view listeners still run every frame.
|
|
686
|
+
*/
|
|
524
687
|
private readonly handleViewChange;
|
|
525
688
|
private createCamera;
|
|
526
689
|
private createControls;
|
|
@@ -528,6 +691,10 @@ declare class Graphraum<NodeAttributes = undefined, EdgeAttributes = undefined>
|
|
|
528
691
|
private pickEdge;
|
|
529
692
|
private worldUnitsPerPixel;
|
|
530
693
|
private applySelectionColors;
|
|
694
|
+
/** Rebuilds the opt-in halo pass; graphs without glow release it and skip the visible scan. */
|
|
695
|
+
private syncGlow;
|
|
696
|
+
private readonly glowAt;
|
|
697
|
+
private readonly describeGlowNode;
|
|
531
698
|
private getNodeStateIds;
|
|
532
699
|
private setNodeStateIds;
|
|
533
700
|
private getNodeColor;
|
|
@@ -593,6 +760,8 @@ declare function selectRichNodeIds(input: {
|
|
|
593
760
|
/** Dark canvas: Ink Black, Turf Green, Porcelain. */
|
|
594
761
|
declare const graphraumThemeDark: Readonly<{
|
|
595
762
|
background: string;
|
|
763
|
+
dimmedEdge: string;
|
|
764
|
+
dimmedEdgeOpacity: number;
|
|
596
765
|
dimmedNode: string;
|
|
597
766
|
edge: string;
|
|
598
767
|
edgeOpacity: number;
|
|
@@ -608,6 +777,8 @@ declare const graphraumThemeDark: Readonly<{
|
|
|
608
777
|
/** Light canvas: Porcelain field with Turf marks and Ink selection. */
|
|
609
778
|
declare const graphraumThemeLight: Readonly<{
|
|
610
779
|
background: string;
|
|
780
|
+
dimmedEdge: string;
|
|
781
|
+
dimmedEdgeOpacity: number;
|
|
611
782
|
dimmedNode: string;
|
|
612
783
|
edge: string;
|
|
613
784
|
edgeOpacity: number;
|
|
@@ -623,6 +794,8 @@ declare const graphraumThemeLight: Readonly<{
|
|
|
623
794
|
declare const graphraumThemes: Readonly<{
|
|
624
795
|
dark: Readonly<{
|
|
625
796
|
background: string;
|
|
797
|
+
dimmedEdge: string;
|
|
798
|
+
dimmedEdgeOpacity: number;
|
|
626
799
|
dimmedNode: string;
|
|
627
800
|
edge: string;
|
|
628
801
|
edgeOpacity: number;
|
|
@@ -637,6 +810,8 @@ declare const graphraumThemes: Readonly<{
|
|
|
637
810
|
}>;
|
|
638
811
|
light: Readonly<{
|
|
639
812
|
background: string;
|
|
813
|
+
dimmedEdge: string;
|
|
814
|
+
dimmedEdgeOpacity: number;
|
|
640
815
|
dimmedNode: string;
|
|
641
816
|
edge: string;
|
|
642
817
|
edgeOpacity: number;
|
|
@@ -653,6 +828,8 @@ declare const graphraumThemes: Readonly<{
|
|
|
653
828
|
/** Alias of {@link graphraumThemeDark} for backward compatibility. */
|
|
654
829
|
declare const graphraumTheme: Readonly<{
|
|
655
830
|
background: string;
|
|
831
|
+
dimmedEdge: string;
|
|
832
|
+
dimmedEdgeOpacity: number;
|
|
656
833
|
dimmedNode: string;
|
|
657
834
|
edge: string;
|
|
658
835
|
edgeOpacity: number;
|
|
@@ -674,4 +851,4 @@ declare function isTransparentGraphraumBackground(background: GraphraumBackgroun
|
|
|
674
851
|
/** Defines typed, serializable graph visuals without coupling application data to the render loop. */
|
|
675
852
|
declare function defineVisuals<NodeAttributes = undefined, EdgeAttributes = undefined>(visuals: GraphraumVisualMapper<NodeAttributes, EdgeAttributes>): GraphraumVisualMapper<NodeAttributes, EdgeAttributes>;
|
|
676
853
|
//#endregion
|
|
677
|
-
export { type CompiledGraphraumPresentation, DEFAULT_ENDPOINT_ATTACH, DEFAULT_ENDPOINT_CLEARANCE, DEFAULT_FORCE_SETTINGS, type EndpointAttach, type EndpointOutline, type ForceLayoutRequest, type ForceSettings, type GraphologyEdgeAttributes, type GraphologyNodeAttributes, type GraphologyRenderer, Graphraum, type GraphraumBackground, type GraphraumColor, type GraphraumData, type GraphraumDataPatch, type GraphraumDiagnostics, type GraphraumEdge, type GraphraumEdgeEncoding, type GraphraumEdgeMarker, type GraphraumEdgeMarkerEnd, type GraphraumEdgePath, type GraphraumEdgeStyle, type GraphraumEdgeVisual, type GraphraumLabelCandidate, type GraphraumLayoutPositions, type GraphraumMode, type GraphraumNode, type GraphraumNodeEncoding, type GraphraumNodeGeometry, type GraphraumNodeShape, type GraphraumNodeState, type GraphraumNodeUpdate, type GraphraumNodeVisual, type GraphraumOptions, GraphraumOverlay, type GraphraumOverlayNode, type GraphraumOverlayOptions, type GraphraumPatternBackground, type GraphraumPickHit, type GraphraumPosition, type GraphraumPresentation, type GraphraumPresentationAction, type GraphraumPresentationProperty, type GraphraumPropertyValue, type GraphraumScreenPosition, type GraphraumTheme, type GraphraumThemeName, type GraphraumVisualMapper, type LabelBudgetCandidate, type RichNodePolicy, type SelectBudgetedLabelIdsInput, type SelectFocusLabelIdsInput, attachPointOnOutline, bindGraphology, boundOverlayIds, computeClusteredForcePositions, computeForcePositions, createForceSimulation, defineVisuals, forceIterationCount, graphraumEdgePaths, graphraumNodeShapes, graphraumTheme, graphraumThemeDark, graphraumThemeLight, graphraumThemes, isTransparentGraphraumBackground, normalizeGraphraumBackground, orderFocusNodeIds, resolveGraphraumTheme, selectBudgetedLabelIds, selectFocusLabelIds, selectRichNodeIds, trimEdgeEndpoints };
|
|
854
|
+
export { type CompiledGraphraumPresentation, DEFAULT_ENDPOINT_ATTACH, DEFAULT_ENDPOINT_CLEARANCE, DEFAULT_FORCE_SETTINGS, type EndpointAttach, type EndpointOutline, type ForceLayoutRequest, type ForceSettings, type GraphologyEdgeAttributes, type GraphologyNodeAttributes, type GraphologyRenderer, Graphraum, type GraphraumAutoOrbitOptions, type GraphraumAutoOrbitStatus, type GraphraumBackground, type GraphraumColor, type GraphraumData, type GraphraumDataPatch, type GraphraumDiagnostics, type GraphraumEdge, type GraphraumEdgeEncoding, type GraphraumEdgeMarker, type GraphraumEdgeMarkerEnd, type GraphraumEdgePath, type GraphraumEdgeState, type GraphraumEdgeStyle, type GraphraumEdgeVisual, type GraphraumFlyToOptions, type GraphraumLabelCandidate, type GraphraumLayoutPositions, type GraphraumMode, type GraphraumNode, type GraphraumNodeEncoding, type GraphraumNodeGeometry, type GraphraumNodeShape, type GraphraumNodeState, type GraphraumNodeUpdate, type GraphraumNodeVisual, type GraphraumOptions, GraphraumOverlay, type GraphraumOverlayNode, type GraphraumOverlayOptions, type GraphraumPatternBackground, type GraphraumPickHit, type GraphraumPosition, type GraphraumPresentation, type GraphraumPresentationAction, type GraphraumPresentationProperty, type GraphraumPropertyValue, type GraphraumScreenPosition, type GraphraumTheme, type GraphraumThemeName, type GraphraumVisualMapper, type LabelBudgetCandidate, type RichNodePolicy, type SelectBudgetedLabelIdsInput, type SelectFocusLabelIdsInput, attachPointOnOutline, bindGraphology, boundOverlayIds, computeClusteredForcePositions, computeForcePositions, createForceSimulation, defineVisuals, forceIterationCount, graphraumEdgePaths, graphraumNodeShapes, graphraumTheme, graphraumThemeDark, graphraumThemeLight, graphraumThemes, isTransparentGraphraumBackground, normalizeGraphraumBackground, orderFocusNodeIds, resolveGraphraumTheme, selectBudgetedLabelIds, selectFocusLabelIds, selectRichNodeIds, trimEdgeEndpoints };
|