ActiveTween
AnimationManager - Lightweight orchestrator that ticks all active tweens each frame.
Usage:
const am = new AnimationManager();
am.setInvalidateCallback(() => runtime.invalidate());
am.add("flyTo", new CameraTween(...));
// In render loop:
am.tick(performance.now());
interface ActiveTween {
done: boolean;
update: unknown;
}
Fields
| | |
|---|
done | boolean | Whether the tween has completed |
AggregateConfig
interface AggregateConfig {
formula: AggregateFormula;
sourceProperty: string;
}
Fields
| | |
|---|
formula | AggregateFormula | |
sourceProperty | string | |
AggregateOptions
interface AggregateOptions {
along?: string | string[];
depth?: number;
formulaFn?: (values: unknown[]) => unknown;
from?: string | string[];
separator?: string;
targetProperty?: string;
to?: string | string[];
}
Fields
| | |
|---|
along | string | string[] | |
depth | number | |
formulaFn | (values: unknown[]) => unknown | |
from | string | string[] | |
separator | string | |
targetProperty | string | |
to | string | string[] | |
AggregatedEdge
Aggregated edge (created when groups are collapsed)
interface AggregatedEdge {
originalEdgeIds: string[];
sourceGroupId: string;
target: AggregatedEdgeTarget;
weight: number;
}
Fields
AggregatedEdgeTarget
Aggregated edge target (discriminated union)
type AggregatedEdgeTarget = object | object
AlgorithmInfo
Generic algorithm-callback payload. The R type parameter lets typed
algorithms (e.g. centrality returns Map<string, number>) narrow the
result field. Default is unknown for the generic prop.
interface AlgorithmInfo {
algo: string;
durationMs?: number;
edgeCount?: number;
error?: Error;
jobId: string;
nodeCount?: number;
progress?: number;
result?: R;
}
Fields
| | |
|---|
algo | string | Algorithm name (e.g. "betweennessCentrality", "louvain"). |
durationMs | number | Wall-clock milliseconds since start. Defined on end only. |
edgeCount | number | Edge count at the time the algorithm began (start only). |
error | Error | Error object. Defined on error only. |
jobId | string | Unique correlation ID, stable across start → end (or start → error). |
nodeCount | number | Node count at the time the algorithm began (start only). |
progress | number | Progress 0..1. Defined on progress only. |
result | R | Result payload. Defined on end only. |
AlignByLayoutOptions
interface AlignByLayoutOptions {
axis?: "x" | "y" | "z";
}
Fields
AnimateOptions
Options for animated camera operations such as resetRotation.
interface AnimateOptions {
duration?: number;
smooth?: boolean;
}
Fields
| | |
|---|
duration | number 400 | Animation duration in ms |
smooth | boolean true | Whether to animate smoothly |
AnimationEasingType
type AnimationEasingType = typeOperator
AnyPickResult
type AnyPickResult = NodePickResult | EdgePickResult | BackgroundPickResult
ApiGraphSnapshot
interface ApiGraphSnapshot {
camera: CameraState;
collections: object[];
data: GraphData;
edgeOverrides: object[];
extensions: Record<string, unknown>;
hiddenEdgeIds: string[];
hiddenNodeIds: string[];
layout: object;
map: object;
nodeOverrides: object[];
plot: object;
positions: object[];
selection: object;
styles: SerializedStyles;
version: string;
}
Fields
| | |
|---|
camera | CameraState | |
collections | object[] | |
data | GraphData | |
edgeOverrides | object[] | |
extensions | Record<string, unknown> | |
hiddenEdgeIds | string[] | |
hiddenNodeIds | string[] | |
layout | object | |
map | object | |
nodeOverrides | object[] | |
plot | object | |
positions | object[] | |
selection | object | |
styles | SerializedStyles | |
version | string | |
ApiOptions
Construction options for RenderEngineApi.
interface ApiOptions {
algorithmWorker?: IAlgorithmWorkerClient;
autoCommitDelay?: number;
hoverEmphasis?: HoverEmphasisSource;
initialDimensions?: 2 | 3;
layoutRuntime?: LayoutRuntime;
maxUndoStackSize?: number;
}
Fields
| | |
|---|
algorithmWorker | IAlgorithmWorkerClient | Optional: inject a custom worker client (used by tests to avoid spawning real Workers). |
autoCommitDelay | number | |
hoverEmphasis | HoverEmphasisSource | Optional: the hover-ring controller owned by RenderRuntime, or a GETTER
for it. When provided, exposes EmphasisApi.setHoverDimOpacity /
setHoverDuration / setEmphasisGlow* and the trace-dim methods to the host.
When omitted, those methods no-op. (Hover-dim was deleted — hover only
draws the ring; dim comes from click dim / trace.)
Pass a getter whenever the owning RenderRuntime can be recreated during
the api's lifetime (React StrictMode remounts it): the api is built once,
so a snapshot would pin it to the first runtime's controller forever
(U4 fix round 2, Important 1). |
initialDimensions | 2 | 3 | Initial dimension at construction time. Pass 2 when the host starts in 2D mode so that
getDimensions() immediately agrees with the renderer. Defaults to 3 for backwards compat. |
layoutRuntime | LayoutRuntime | |
maxUndoStackSize | number | |
ApiStyleRule
interface ApiStyleRule {
category?: string;
color?: string;
icon?: string;
relationship?: string;
size?: number;
}
Fields
| | |
|---|
category | string | Category to apply to (undefined = all categories) |
color | string | |
icon | string | |
relationship | string | Relationship to apply to (undefined = all relationships) |
size | number | |
ApplyGeoLayoutOptions
interface ApplyGeoLayoutOptions {
alphaBump?: number;
autoPlaceJitter?: number;
geoMapping?: GeoMappingSpec;
globeRadius?: number;
mapSize?: number;
mode: MapMode;
nonGeoFallback?: "preserve" | "geoCentroid";
nonGeoStrategy?: "autoPlace" | "preserve";
pinAutoPlaced?: boolean;
}
Fields
| | |
|---|
alphaBump | number `0.5` | Simulation alpha to set after applying positions, to drive remaining convergence (e.g. for non-geo nodes that still need to settle). Set to 0 to leave the simulation alpha untouched. (The underlying controller.pinNodes also auto-reheats to 0.3 when the sim has cooled below 0.1 — this option lets you push higher.) |
autoPlaceJitter | number `0.15` (≈ 30% | Jitter radius (world units) applied to autoPlaced non-geo nodes so co-edged ones don't pile on top of each other. of the default linkDistance, comfortable within one link-spring). |
geoMapping | GeoMappingSpec `'auto'` | How to find lat/lng on each node. |
globeRadius | number 5 | Globe radius for spherical mode. |
mapSize | number 10 | Flat map size for planar mode. |
mode | MapMode | Map projection. |
nonGeoFallback | "preserve" | "geoCentroid" | What to do (under nonGeoStrategy: 'autoPlace') with non-geo nodes that
have NO graph path to any geo node — an isolated non-geo component the
BFS can't anchor. These are reported in
ApplyGeoLayoutResult.disconnectedNonGeoIds either way.
- 'preserve' (default): keep their current x/y (planar still flattens
z to 0). They stay wherever force layout last put them.
- 'geoCentroid': park them at the centroid of all geo nodes (+ jitter)
so they sit near the data's geographic center instead of far off-map.
Ignored when nonGeoStrategy: 'preserve'. |
nonGeoStrategy | "autoPlace" | "preserve" | How to place nodes that lack a valid lat/lng.
- 'autoPlace' (default): a wavefront BFS out from the geo anchors. Each
non-geo node is teleported to the centroid of its already-placed
neighbors (with a small random jitter so co-edged nodes don't stack),
so even multi-hop non-geo nodes (non-geo → non-geo → geo) hang off the
geo cluster instead of being stranded at their far force-layout
positions. Nodes with no path to any geo node fall to nonGeoFallback.
Removes the "drift in from afar" delay the user otherwise sees on Show
Map.
- 'preserve': leave non-geo positions where they were; rely solely on
force layout to pull them in over time.
In planar mode, non-geo nodes are also flattened to z=0 (matching the
flat map plane) regardless of this option, so they don't float above/
below the map in 3D camera views. |
pinAutoPlaced | boolean | Whether to PIN the auto-placed non-geo nodes (default true). Non-geo
nodes have no lat/lng anchor, so if left unpinned the live force
simulation disperses them across the map right after autoPlace positions
them (geo nodes are pinned and tight; unpinned non-geo blow out to the map
edges). Pinning freezes them at their BFS-anchored positions — matching the
legacy globe path. Set false to keep them draggable / force-driven (and
accept the dispersal, or pair with your own constrained-force handling).
Only applies under nonGeoStrategy: 'autoPlace'. |
ApplyGeoLayoutResult
interface ApplyGeoLayoutResult {
disconnectedNonGeoIds: string[];
geoNodeIds: string[];
nonGeoNodeIds: string[];
resolvedMapping: object;
}
Fields
| | |
|---|
disconnectedNonGeoIds | string[] | Subset of nonGeoNodeIds that the autoPlace BFS could NOT anchor because
they have no graph path to any geo node (an isolated non-geo component).
Their final position is governed by nonGeoFallback. Callers that prefer
to drop them from the map view can api.nodes.hide(disconnectedNonGeoIds).
Empty under nonGeoStrategy: 'preserve' is NOT guaranteed — the field
always reflects geo-reachability, computed independently of strategy. |
geoNodeIds | string[] | IDs of nodes that were positioned + pinned. |
nonGeoNodeIds | string[] | IDs of nodes that lacked a valid lat/lng. |
resolvedMapping | object | The lat/lng property names that were used, or null if none matched. |
AudioSpectrumLayerConfig
interface AudioSpectrumLayerConfig {
amplitude?: number;
color?: ColorRepresentation;
opacity?: number;
}
Fields
| | |
|---|
amplitude | number | |
color | ColorRepresentation | |
opacity | number | |
AudioSpectrumLayerProps
interface AudioSpectrumLayerProps {
amplitude?: number;
analyser?: AudioSpectrumOptions;
audio: HTMLMediaElement | AudioSpectrum;
band?: "top" | "underlay" | "overlay";
bandOffset?: number;
bars?: number;
beatResponse?: number;
clickable?: boolean;
color?: ColorRepresentation;
filter?: (node: NodeData, index: number) => boolean;
innerRadius?: number;
maxNodes?: number;
name?: string;
opacity?: number;
size?: (node: NodeData, index: number) => number;
sizeFactor?: number;
style?: AudioSpectrumStyle;
thickness?: number;
}
Fields
| | |
|---|
amplitude | number | Extra amplitude multiplier on top of AudioSpectrumOptions.gain. Default 1. |
analyser | AudioSpectrumOptions | Analyser options, used only when audio is an element. |
audio | HTMLMediaElement | AudioSpectrum | The element to analyse, or a spectrum you already own (share one across
several layers rather than attaching two analysers to one element). |
band | "top" | "underlay" | "overlay" | |
bandOffset | number | |
bars | number | Bars drawn around the node. Default 48 (clamped to the analyser's bins). |
beatResponse | number | Grow the whole figure with the beat, 0..1. Default 0.18. |
clickable | boolean | Default false — a spectrum ring is decoration, not a click target. |
color | ColorRepresentation | |
filter | (node: NodeData, index: number) => boolean all of them | Nodes to decorate. |
innerRadius | number | Ring/bars inner radius as a fraction of the quad. Default 0.30. |
maxNodes | number | |
name | string | |
opacity | number | |
size | (node: NodeData, index: number) => number | |
sizeFactor | number | |
style | AudioSpectrumStyle | Default "ring". |
thickness | number | Band height as a fraction of the quad. Default 0.17. |
AudioSpectrumLayerSpec
interface AudioSpectrumLayerSpec {
amplitude?: number;
analyser?: AudioSpectrumOptions;
audio: HTMLMediaElement | AudioSpectrum;
band?: "top" | "underlay" | "overlay";
bandOffset?: number;
bars?: number;
beatResponse?: number;
clickable?: boolean;
color?: ColorRepresentation;
filter?: (node: NodeData, index: number) => boolean;
innerRadius?: number;
maxNodes?: number;
opacity?: number;
size?: (node: NodeData, index: number) => number;
sizeFactor?: number;
style?: AudioSpectrumStyle;
thickness?: number;
}
Fields
| | |
|---|
amplitude | number | Extra amplitude multiplier on top of AudioSpectrumOptions.gain. Default 1. |
analyser | AudioSpectrumOptions | Analyser options, used only when audio is an element. |
audio | HTMLMediaElement | AudioSpectrum | The element to analyse, or a spectrum you already own (share one across
several layers rather than attaching two analysers to one element). |
band | "top" | "underlay" | "overlay" | |
bandOffset | number | |
bars | number | Bars drawn around the node. Default 48 (clamped to the analyser's bins). |
beatResponse | number | Grow the whole figure with the beat, 0..1. Default 0.18. |
clickable | boolean | Default false — a spectrum ring is decoration, not a click target. |
color | ColorRepresentation | |
filter | (node: NodeData, index: number) => boolean all of them | Nodes to decorate. |
innerRadius | number | Ring/bars inner radius as a fraction of the quad. Default 0.30. |
maxNodes | number | |
opacity | number | |
size | (node: NodeData, index: number) => number | |
sizeFactor | number | |
style | AudioSpectrumStyle | Default "ring". |
thickness | number | Band height as a fraction of the quad. Default 0.17. |
AudioSpectrumOptions
interface AudioSpectrumOptions {
beatDecay?: number;
bins?: number;
fftSize?: number;
gain?: number;
monitor?: boolean;
smoothing?: number;
}
Fields
| | |
|---|
beatDecay | number | Seconds for beat to decay from 1 to 0. Default 0.22. |
bins | number | Texture width = number of bands exposed to the shader. Default 64. |
fftSize | number | AnalyserNode.fftSize. Default 1024. Must be a power of two ≥ 32. |
gain | number | Linear gain applied to every band before clamping. Default 1. |
monitor | boolean | Also route the audio to the speakers. Default true. |
smoothing | number | AnalyserNode.smoothingTimeConstant. Default 0.72. |
AudioSpectrumStyle
type AudioSpectrumStyle = "ring" | "bars" | "pulse" | "wave"
AxisLayerProps
interface AxisLayerProps {
axes?: object;
baseRange?: [number, number];
categoryAxes?: Record<string, object>;
categoryColors?: Record<string, [number, number, number]>;
gridColor?: number;
projectionColor?: number;
range: [number, number];
showGrid?: boolean;
visible?: boolean;
wallColor?: number;
}
Fields
| | |
|---|
axes | object | |
baseRange | [number, number] | Base range for inactive dimension positioning (from PlotLayoutResult.baseRange) |
categoryAxes | Record<string, object> | |
categoryColors | Record<string, [number, number, number]> | |
gridColor | number | |
projectionColor | number | |
range | [number, number] | |
showGrid | boolean | |
visible | boolean | |
wallColor | number | |
BackgroundPickResult
interface BackgroundPickResult {
index: -1;
ndcPosition: object;
picked: false;
screenPosition: object;
type: "background";
}
Fields
| | |
|---|
index | -1 | Index in the GPU buffer (-1 for background) |
ndcPosition | object | Normalized device coordinates (-1 to 1) |
picked | false | Whether something was picked (not background) |
screenPosition | object | Screen position of pick |
type | "background" | What was picked |
BackgroundPointerEvent
Click / context-menu on the empty canvas background (no node or edge under the pointer).
interface BackgroundPointerEvent {
canvasPos: [number, number];
modifiers: PointerModifiers;
originalEvent: MouseEvent;
worldPos: [number, number, number];
}
Fields
| | |
|---|
canvasPos | [number, number] | Canvas-relative position in CSS pixels, origin top-left. |
modifiers | PointerModifiers | Modifier-key state at event time. |
originalEvent | MouseEvent | Native pointer or mouse event the engine handled. Preserved so hosts can call preventDefault() / stopPropagation(). |
worldPos | [number, number, number] | Three.js world-space position [x, y, z] at the pointer's intersection with the cloudScene plane. |
BadgeSpec
interface BadgeSpec {
anchor: DecorationAnchor;
bg?: string;
fg?: string;
iconName?: string;
text?: string;
}
Fields
BinningSource
Fully describes how to project graph elements onto the time axis.
Because graph data has many node categories and many properties, binning is
not implicit — the caller must say which element kind, which date property,
and at what granularity.
interface BinningSource {
categories?: string[];
granularity: DateGranularity;
measure?: TimelineMeasure;
property: string;
target: TimelineTarget;
}
Fields
| | |
|---|
categories | string[] | Restrict to these categories (when target === "node") or relationship
types (when target === "edge"). Empty / undefined = all. |
granularity | DateGranularity | Bucket width. |
measure | TimelineMeasure | Height measure. Defaults to { kind: "count" }. |
property | string | Property key in element.properties holding the date/datetime value. |
target | TimelineTarget | Bin nodes or edges. Time most often lives on edges (relationships/events). |
BufferTextSource
Buffer-direct text source for large graphs (10K+ nodes).
Avoids creating TextItem objects for every node — resolvers are only called
for the few hundred nodes that pass frustum + distance culling.
interface BufferTextSource {
hiddenResolver?: (index: number) => boolean;
nodeCount: number;
opacityResolver?: (index: number) => number;
positions: Float32Array;
sizeResolver?: (index: number) => number;
textResolver: (index: number) => string;
}
Fields
| | |
|---|
hiddenResolver | (index: number) => boolean false | Return true if node at index is hidden. |
nodeCount | number | Number of nodes |
opacityResolver | (index: number) => number 1 | Return dim opacity for a node index (focusContext / click dim). |
positions | Float32Array | Interleaved xyz positions (length = nodeCount * 3) |
sizeResolver | (index: number) => number 1 | Return node size for a node index. |
textResolver | (index: number) => string | Return label text for a node index, or null to skip |
BuildGeoPositionProviderOptions
interface BuildGeoPositionProviderOptions {
geoMapping?: GeoMappingSpec;
globeRadius?: number;
mapSize?: number;
mode: MapMode;
nonGeoFill?: "preserve" | "origin";
}
Fields
| | |
|---|
geoMapping | GeoMappingSpec `'auto'` | How to find lat/lng on each node. |
globeRadius | number 5 | Globe radius for spherical mode. |
mapSize | number 10 | Flat map size for planar mode. |
mode | MapMode | Map projection. Required — there is no useful default. |
nonGeoFill | "preserve" | "origin" | What to write into the output buffer for nodes that lack a valid lat/lng.
- 'preserve' (default): copy each node's current position from
store.positionProvider so non-geo nodes stay visually anchored where
they were before the map was shown (matches legacy moveLocationsToMap
behavior — non-geo nodes are not touched). If the store has no provider
yet, falls back to origin.
- 'origin': leave at (0, 0, 0). The caller is expected to hide non-geo
nodes themselves (e.g. via api.nodes.hide(result.nonGeoNodeIds)). |
BuildGeoPositionProviderResult
interface BuildGeoPositionProviderResult {
geoNodeIds: string[];
nonGeoNodeIds: string[];
provider: StaticPositionProvider;
resolvedMapping: object;
}
Fields
| | |
|---|
geoNodeIds | string[] | IDs of nodes that mapped successfully to lat/lng. |
nonGeoNodeIds | string[] | IDs of nodes that lacked a valid lat/lng. |
provider | StaticPositionProvider | A StaticPositionProvider whose buffer has one (x, y, z) slot per node,
in the same order as store.data.nodes. null when no node has a valid
lat/lng (caller should leave the existing provider in place). |
resolvedMapping | object | The lat/lng property names that were actually used. null when no
property pair matched (i.e. dataset has no geo information at all). |
BuiltinEdgeShape
type BuiltinEdgeShape = "straight" | "curve" | "radial"
CameraDirectorConfig
interface CameraDirectorConfig {
allowLens?: boolean;
enabled?: boolean;
onFrame?: (frame: ShotFrame) => void;
onMark?: (mark: ShotMark, shot: Shot) => void;
}
Fields
| | |
|---|
allowLens | boolean | Permission to write camera.fov. Default false, and it should stay
false.
The engine animates by moving the SCENE: the camera sits still at
(0, 0, cameraZ) and cloudScene pans, zooms and turns. Every other
effect in this engine obeys that, and a host that owns the camera (map
mode captures and restores it, setViewState writes its z) must be able
to assume nothing else touches it. So the director writes the scene
transform and nothing else.
The single shot that cannot be done this way is dollyZoomShot,
because a scene scale S scales the depth SEPARATIONS too: with
S = c·d, a background node at local depth δ keeps the apparent-size
ratio d/(d + S·δ) = 1/(1 + c·δ), which is independent of d. The
perspective compression simply does not move. Only the lens moves it.
A host that wants that one shot opts in here and accepts that it owns the
consequences; stop() puts the lens back. |
enabled | boolean | false parks the director: the queue is kept, nothing is written. Default true. |
onFrame | (frame: ShotFrame) => void | Called with every frame the director applies — this is how a layer that
draws speed (streaks, a tunnel) stays in step with the flight. |
onMark | (mark: ShotMark, shot: Shot) => void | Called when the shot ARRIVES somewhere — see ShotMark. null means
it is back before the first arrival, so a host that put a card up can take
it down again.
It fires on a change of which mark is current, not on a crossing, so it is
correct under scrub in both directions and never fires twice for
the same arrival. Which is the point: it lets everything that should happen
at a waypoint — a card, a highlight, a ripple — hang off the flight itself
rather than off a second clock somebody has to keep in step by hand. |
CameraPositionSource
Minimal position source used by CameraApi for flyToAll / flyToNodes.
Both LayoutRuntime and a raw PositionProvider satisfy this interface.
The getNodePosition method is optional; when absent flyToNodes returns
immediately without animating.
interface CameraPositionSource {
getNodePosition?: unknown;
getPositions: unknown;
}
CameraTweenTarget
Target position for cloudScene group: x/y = pan, z = zoom distance
interface CameraTweenTarget {
x: number;
y: number;
z: number;
}
Fields
CanvasEvent
interface CanvasEvent {
originalEvent?: MouseEvent | TouchEvent;
target: null;
type: "canvas:click" | "canvas:dblclick" | "canvas:drag" | "canvas:zoom";
}
Fields
| | |
|---|
originalEvent | MouseEvent | TouchEvent | |
target | null | |
type | "canvas:click" | "canvas:dblclick" | "canvas:drag" | "canvas:zoom" | |
CapabilityState
Honest parity reporting for legacy features:
- 'implemented' — full visual + state behavior
- 'stub' — API exists, setter/getter round-trip, NO visual effect (deferred)
- 'none' — no API surface at all
type CapabilityState = "implemented" | "stub" | "none"
CaptionDef
Single caption definition.
Used in NodeCaptionConfig.captions to configure multi-line labels.
interface CaptionDef {
color?: string | [number, number, number];
sizeScale?: number;
source: string;
template?: string;
whenEmpty?: "hide" | "blank";
}
Fields
| | |
|---|
color | string | [number, number, number] | Color (hex or [r,g,b]). Leave empty = global caption color |
sizeScale | number 1.0 | Font size scale relative to global caption size. |
source | string | Value source:
- 'property:KEY' → node.properties[KEY]
- 'category' → node.category
- 'id' → node.id
- 'static:TEXT' → static text |
template | string | Template format. Use {value} as placeholder.
E.g., 'Age: {value}' → 'Age: 28'
Leave empty to show value directly. |
whenEmpty | "hide" | "blank" 'hide' | Behavior when value is empty/null: - 'hide' → skip this line - 'blank' → show empty line (preserves spacing) |
CaptionOptions
interface CaptionOptions {
category?: string;
hoverOnly?: boolean;
property?: string;
}
Fields
| | |
|---|
category | string | Restrict to a specific category |
hoverOnly | boolean | Show caption on hover only |
property | string | Property key to use as caption text |
CaptionProps
Simplified node caption configuration for GraphCanvas
interface CaptionProps {
autoCaption?: boolean;
maxLength?: number;
position?: LabelPosition;
properties?: string[];
property?: string;
scale?: number;
visible?: boolean;
}
Fields
| | |
|---|
autoCaption | boolean true | Auto-select property for caption (name > label > title > id). |
maxLength | number 50 | Maximum text length before truncation. |
position | LabelPosition "right" | Label position relative to node. |
properties | string[] | Multiple properties to display as multi-line captions. Overrides property when set. |
property | string | Specific node property to display as caption |
scale | number 1.0 | Text size multiplier. |
visible | boolean true | Show node captions. |
CardLayerProps
interface CardLayerProps {
container: HTMLElement;
handle?: Pick<GraphContextValue, "cloudScene" | "camera" | "registerFrameCallback">;
manager: CardsManager;
project?: (localPos: Vector3, cloudScene: Object3D, camera: PerspectiveCamera, width: number, height: number) => object;
store: GraphStore;
}
Fields
| | |
|---|
container | HTMLElement | Element used as the portal target and for viewport dimensions. |
handle | Pick<GraphContextValue, "cloudScene" | "camera" | "registerFrameCallback"> | Optional engine handle override. Defaults to useGraphHandle() (from
the ambient GraphContext). Tests inject a fake handle here so they
don't need a full GraphRenderer context. |
manager | CardsManager | |
project | (localPos: Vector3, cloudScene: Object3D, camera: PerspectiveCamera, width: number, height: number) => object | World→screen projector. Defaults to localToNdc.
Inject a deterministic stub in tests. |
store | GraphStore | |
CardPlacement
Where a card sits relative to its anchor. "center" puts it ON the node —
that, with hideNode, is how a card becomes the node rather than a label
beside it.
type CardPlacement = "auto" | "top" | "right" | "bottom" | "left" | "center"
CardSpec
type CardSpec = PresetSpec | HtmlSpec | RenderSpec | ElementSpec
CascadeHighlightConfig
interface CascadeHighlightConfig {
color?: [number, number, number];
delayPerHop?: number;
direction?: "in" | "out" | "both";
maxHops?: number;
wavefrontScale?: number;
}
Fields
| | |
|---|
color | [number, number, number] [0.2, 0.6, 1.0] (blue) | Wave color [r,g,b]. |
delayPerHop | number 400 | Delay between hops in ms. |
direction | "in" | "out" | "both" "both" | Direction: "out" = follow edge direction, "in" = reverse, "both" = either. |
maxHops | number Infinity (until all reachable nodes hit) | Max hops. |
wavefrontScale | number 1.5 | Size boost for wavefront nodes. |
CategoricalFilter
Categorical filter — include only items whose property value is in the allowed set.
interface CategoricalFilter {
allValues?: string[];
categories?: string[];
includeNull?: boolean;
invert?: boolean;
label?: string;
property: string;
regex?: RegExp;
target: FilterTarget;
type: "categorical";
values: Set<string>;
}
Fields
| | |
|---|
allValues | string[] | All known values for this property (for UI rendering). Auto-populated if omitted. |
categories | string[] | Limit to specific categories (nodes) or relationship types (edges).
Empty/undefined = apply to all. |
includeNull | boolean true | Whether null/undefined values pass the filter. |
invert | boolean | Invert the filter result (show what would be hidden, hide what would be shown) |
label | string | Human-readable label for UI display |
property | string | Property key |
regex | RegExp | Regex pattern for matching values. Takes precedence over values when set. |
target | FilterTarget | Filter target: nodes or edges |
type | "categorical" | |
values | Set<string> | Set of allowed values (string-coerced for comparison) |
Category
FlowsApi — registry for host-injected schema callbacks consumed by engine
flow primitives (CreateNodeFlow, CreateEdgeFlow, ChangeCategoryFlow).
The engine does not know about specific node categories or relationship
types; the host (e.g. the Kineviz platform) calls setSchemaCallbacks at mount time
to inject async resolvers. Flow primitives invoke callbacks.onResolveX
when they need schema data; if no callback is registered the menu items
that depend on the schema auto-hide via hasCallback(...).
interface Category {
color?: string;
id: string;
name: string;
}
Fields
| | |
|---|
color | string | |
id | string | |
name | string | |
CategoryAxisMapping
Per-category axis mapping for multi-category scatter plots.
Each category can map different properties to X/Y/Z with independent options.
interface CategoryAxisMapping {
category: string;
dateAxisX?: boolean;
dateAxisY?: boolean;
dateAxisZ?: boolean;
domainX?: [number, number];
domainY?: [number, number];
domainZ?: [number, number];
niceX?: boolean;
niceY?: boolean;
niceZ?: boolean;
parseX?: (value: any) => number;
parseY?: (value: any) => number;
parseZ?: (value: any) => number;
propertyX?: string;
propertyY?: string;
propertyZ?: string;
scaleX?: "linear" | "log";
scaleY?: "linear" | "log";
scaleZ?: "linear" | "log";
tickCountX?: number;
tickCountY?: number;
tickCountZ?: number;
tickFormatX?: (value: number) => string;
tickFormatY?: (value: number) => string;
tickFormatZ?: (value: number) => string;
tickValuesX?: number[];
tickValuesY?: number[];
tickValuesZ?: number[];
}
Fields
| | |
|---|
category | string | |
dateAxisX | boolean | |
dateAxisY | boolean | |
dateAxisZ | boolean | |
domainX | [number, number] | |
domainY | [number, number] | |
domainZ | [number, number] | |
niceX | boolean | |
niceY | boolean | |
niceZ | boolean | |
parseX | (value: any) => number | |
parseY | (value: any) => number | |
parseZ | (value: any) => number | |
propertyX | string | |
propertyY | string | |
propertyZ | string | |
scaleX | "linear" | "log" | |
scaleY | "linear" | "log" | |
scaleZ | "linear" | "log" | |
tickCountX | number | |
tickCountY | number | |
tickCountZ | number | |
tickFormatX | (value: number) => string | |
tickFormatY | (value: number) => string | |
tickFormatZ | (value: number) => string | |
tickValuesX | number[] | |
tickValuesY | number[] | |
tickValuesZ | number[] | |
CategoryConfig
CategoryConfig - Visual binding configuration for each node category.
Declares the complete mapping from node properties to visual attributes.
Read and applied by VisualMapper.
interface CategoryConfig {
captionConfig?: NodeCaptionConfig;
category: string;
colorMapping?: ColorMappingType;
defaultAspect?: number;
defaultColor?: string;
defaultIcon?: string;
defaultShape?: string | number;
defaultSize?: number;
iconMapping?: IconMapping;
imageUrlMapping?: ImageUrlMapping;
shapeMapping?: ShapeMapping;
sizeMapping?: SizeMapping;
}
Fields
| | |
|---|
captionConfig | NodeCaptionConfig | |
category | string | Corresponding to NodeData.category |
colorMapping | ColorMappingType | |
defaultAspect | number | Default width / height ratio of the node box (1 = square) |
defaultColor | string | Default color when no colorMapping |
defaultIcon | string | Default icon when no iconMapping |
defaultShape | string | number | Default node shape when no shapeMapping (built-in name or id) |
defaultSize | number | Default size when no sizeMapping |
iconMapping | IconMapping | |
imageUrlMapping | ImageUrlMapping | |
shapeMapping | ShapeMapping | |
sizeMapping | SizeMapping | |
CategorySchema
interface CategorySchema {
name: string;
properties: PropertySchema[];
}
Fields
ChatMessage
Wire-format message for all LLM APIs.
interface ChatMessage {
content: string;
role: "system" | "user" | "assistant";
}
Fields
| | |
|---|
content | string | |
role | "system" | "user" | "assistant" | |
CineTarget
What a target may be: node ids, one id, explicit points, or the whole graph.
type CineTarget = string | string[] | ReadonlyArray<THREE.Vector3> | null | undefined
Cinematics
interface Cinematics {
director: CameraDirector;
playing: boolean;
warp: number;
cuePath: unknown;
dispose: unknown;
establish: unknown;
flyPath: unknown;
frame: unknown;
orbit: unknown;
stop: unknown;
warpTo: unknown;
}
Fields
| | |
|---|
director | CameraDirector | The director, for hand-rolled shots: cine.director.play(myShot). |
playing | boolean | |
warp | number | Warp intensity of the frame last applied, 0..1. |
CinematicsHost
The slice of RenderEngineApi a cinematics instance uses. Structural on
purpose: RenderEngineApi satisfies it, and so does a three-line fake in a
test, which is how the sequencing below is covered without a GPU.
interface CinematicsHost {
layers: object;
layout: object;
nodes: object;
}
Fields
| | |
|---|
layers | object | |
layout | object | |
nodes | object | |
CinematicsOptions
interface CinematicsOptions {
name?: string;
onFrame?: (frame: ShotFrame) => void;
}
Fields
| | |
|---|
name | string | Layer name to mount under. Default "cinematics". |
onFrame | (frame: ShotFrame) => void | Published on every applied frame. Point a streak layer's intensity at it
and the streaks cannot drift out of step with the flight. |
CircleLayoutOptions
interface CircleLayoutOptions {
radius?: number;
spacing?: number;
}
Fields
| | |
|---|
radius | number | Override the computed radius directly. |
spacing | number | Target gap between adjacent nodes along the circle arc. Default 1.5. |
ClusterRevealConfig
interface ClusterRevealConfig {
clusterAnimDuration?: number;
clusterOrder?: string[];
delayPerCluster?: number;
}
Fields
| | |
|---|
clusterAnimDuration | number 600 | Animation duration for each cluster's appearance in ms. |
clusterOrder | string[] auto from data categories | Order of clusters to reveal. |
delayPerCluster | number 800 | Delay between revealing each cluster in ms. |
CollectionState
Legacy type kept for back-compat with tests / external imports.
interface CollectionState {
childNodeIds: string[];
parentId: string;
savedEdges: object[];
savedState: Map<string, object>;
}
Fields
| | |
|---|
childNodeIds | string[] | |
parentId | string | |
savedEdges | object[] | |
savedState | Map<string, object> | |
ColorMappingOptions
interface ColorMappingOptions {
category?: string;
colorFrom?: string;
colorMap?: Record<string, string>;
colorTo?: string;
mode?: "sequential" | "ordinal";
}
Fields
| | |
|---|
category | string | Restrict to a specific category |
colorFrom | string "#0000ff" | Start color for sequential interpolation |
colorMap | Record<string, string> | Explicit color map for ordinal mode: value → CSS color |
colorTo | string "#ff0000" | End color for sequential interpolation |
mode | "sequential" | "ordinal" | "ordinal" uses colorMap or auto-generated palette; "sequential" uses linear interpolation |
ColorMappingType
Color mapping types
type ColorMappingType = object | object | object
ColorValue
type ColorValue = [number, number, number] | string
ColumnMapping
interface ColumnMapping {
categoryCol?: string;
edgeRelationship?: string;
edgeSourceCol?: string;
edgeTargetCol?: string;
labelCol?: string;
nodeIdCol: string;
properties: string[];
}
Fields
| | |
|---|
categoryCol | string | |
edgeRelationship | string | |
edgeSourceCol | string | |
edgeTargetCol | string | |
labelCol | string | |
nodeIdCol | string | |
properties | string[] | |
Command
interface Command {
type: string;
execute: unknown;
undo: unknown;
}
Fields
ConfigSource
type ConfigSource = "ontology" | "user"
ConflictReport
interface ConflictReport {
binding: KeyBinding;
commandIds: string[];
}
Fields
| | |
|---|
binding | KeyBinding | The binding that conflicts |
commandIds | string[] | Command IDs sharing this binding |
interface ContextMenuOverlayProps {
container?: HTMLElement;
manager: ContextMenuManager;
}
Fields
| | |
|---|
container | HTMLElement | Container element for boundary clamping |
manager | ContextMenuManager | |
Observable state of the context menu
interface ContextMenuState {
context: MenuContext;
position: object;
sections: ResolvedMenuSection[];
visible: boolean;
}
Fields
CoverageConfig
interface CoverageConfig {
items: CoverageItem[];
}
Fields
CoverageItem
Single coverage disc configuration. Domain-agnostic.
interface CoverageItem {
anchorNodeId?: string;
azimuthDeg?: number;
band?: "underlay" | "overlay";
beamWidthDeg?: number;
falloff?: number;
fillColor: [number, number, number];
fillOpacity?: number;
innerRadius?: number;
position?: [number, number, number];
pulse?: object;
radius: number;
ringColor?: [number, number, number];
ringOpacity?: number;
ringWidth?: number;
}
Fields
| | |
|---|
anchorNodeId | string | Graph node id whose position the disc is anchored to. |
azimuthDeg | number | Sector centre bearing, degrees clockwise from north. Default 0. |
band | "underlay" | "overlay" | Render band — mirrors PolygonItem.band. "overlay" (default) draws the
wedge OVER the graph (in front of nodes & captions). "underlay" draws it on the
GROUND, behind nodes & captions, so labels stay legible over the footprint.
Layer-level: all items in one set() share the band (the first item's band wins). |
beamWidthDeg | number | Wedge angular width in degrees. Default 360 → full disc (back-compat). |
falloff | number | Radial falloff exponent (signal weakens toward edge); default 2. |
fillColor | [number, number, number] | RGB fill colour [0..1]. |
fillOpacity | number | Interior fill opacity (0..1): the soft radial bloom inside the disc. Also
scales the radar pulse. Lower it to let the basemap show through. Does NOT
affect the boundary ring (see ringOpacity). Default 0.25. |
innerRadius | number | Inner radius as a fraction of radius (annular gap near the tower). Default 0. |
position | [number, number, number] | Explicit world-space position; used when anchorNodeId is absent. |
pulse | object | Radar-ping animation; omit to disable. |
radius | number | Disc radius in WORLD units (km→world resolved upstream in api.coverage). |
ringColor | [number, number, number] | Ring (boundary circle) colour; defaults to fillColor. |
ringOpacity | number | Boundary-ring opacity (0..1), independent of fillOpacity — so the
coverage boundary can stay crisp while the fill fades. Default 0.8. |
ringWidth | number | Ring width as a fraction of the disc radius; default 0.04. |
CoverageLayerProps
Props for CoverageLayer.
interface CoverageLayerProps {
items: CoverageItem[];
}
Fields
CoverageSpec
Extended coverage spec that allows specifying radius either in world units
(passthrough) or in km (resolved via the injected kmToWorld function).
Omits radius from CoverageItem so both radiusKm and radius can coexist.
interface CoverageSpec {
anchorNodeId?: string;
azimuthDeg?: number;
band?: "underlay" | "overlay";
beamWidthDeg?: number;
falloff?: number;
fillColor: [number, number, number];
fillOpacity?: number;
innerRadius?: number;
key?: string;
latitude?: number;
position?: [number, number, number];
pulse?: object;
radius?: number;
radiusKm?: number;
ringColor?: [number, number, number];
ringOpacity?: number;
ringWidth?: number;
}
Fields
| | |
|---|
anchorNodeId | string | Graph node id whose position the disc is anchored to. |
azimuthDeg | number | Sector centre bearing, degrees clockwise from north. Default 0. |
band | "underlay" | "overlay" | Render band — mirrors PolygonItem.band. "overlay" (default) draws the
wedge OVER the graph (in front of nodes & captions). "underlay" draws it on the
GROUND, behind nodes & captions, so labels stay legible over the footprint.
Layer-level: all items in one set() share the band (the first item's band wins). |
beamWidthDeg | number | Wedge angular width in degrees. Default 360 → full disc (back-compat). |
falloff | number | Radial falloff exponent (signal weakens toward edge); default 2. |
fillColor | [number, number, number] | RGB fill colour [0..1]. |
fillOpacity | number | Interior fill opacity (0..1): the soft radial bloom inside the disc. Also
scales the radar pulse. Lower it to let the basemap show through. Does NOT
affect the boundary ring (see ringOpacity). Default 0.25. |
innerRadius | number | Inner radius as a fraction of radius (annular gap near the tower). Default 0. |
key | string | Map key for dedup/replace; defaults to anchorNodeId. Provide a distinct key
to keep multiple wedges that share one anchorNodeId (e.g. the 3 sectors
of one base station, all selecting together when that node is clicked). |
latitude | number | Latitude for Mercator correction when radiusKm is used; defaults to 0. |
position | [number, number, number] | Explicit world-space position; used when anchorNodeId is absent. |
pulse | object | Radar-ping animation; omit to disable. |
radius | number | Disc radius in world units (passthrough — skips km→world resolution). |
radiusKm | number | True ground radius in km — resolved via kmToWorld(radiusKm, latitude). |
ringColor | [number, number, number] | Ring (boundary circle) colour; defaults to fillColor. |
ringOpacity | number | Boundary-ring opacity (0..1), independent of fillOpacity — so the
coverage boundary can stay crisp while the fill fades. Default 0.8. |
ringWidth | number | Ring width as a fraction of the disc radius; default 0.04. |
CubeLayoutOptions
interface CubeLayoutOptions {
size?: number;
spacing?: number;
}
Fields
| | |
|---|
size | number | Grid size per side (cube root of n if unset). |
spacing | number | Distance between adjacent cube-grid cells. Default 1.5. |
CuedFlight
A flight installed but not running, for a host that owns the clock — see
Cinematics.cuePath.
interface CuedFlight {
duration: number;
cancel: unknown;
release: unknown;
scrub: unknown;
scrubFraction: unknown;
}
Fields
| | |
|---|
duration | number | Length of the flight in ms. The domain scrub expects. |
CursorStyle
type CursorStyle = "default" | "grab" | "grabbing" | "crosshair" | "pointer"
CurveParams
interface CurveParams {
curvature: number;
planeRotation: number;
}
Fields
| | |
|---|
curvature | number | Curvature amount (0 = straight line, positive = curve one way, negative = other) |
planeRotation | number | 3D plane rotation angle (for 3D mode) |