Topology Visualization Architecture¶
InfraLynx topology visualization is split across three ownership layers so graph rendering does not leak into network modeling rules.
Ownership Layers¶
packages/network-domain/src/topology-viewcreates deterministic graph nodes and edges from explicit device and cable relationships.packages/ui/src/topologyowns view-model filtering and selection helpers that are safe to reuse across frontend surfaces.apps/web/src/components/topologyowns SVG rendering, viewport interaction, and operator-facing controls.
Architectural Rules¶
- Connections are explicit. The graph only renders relationships supplied by the backend contract.
- Layout is deterministic. The same topology payload must produce the same node order and position.
- Filtering is applied before rendering, not inferred during drawing.
- UI state such as selection, zoom, and pan stays in the web layer.
Runtime Flow¶
apps/apiserves/api/topology/demo.apps/web/src/services/topology-graph.tsnormalizes the response.apps/web/src/state/topology-graph-state.tsapplies filter and viewport state.TopologyGraph.tsxrenders the filtered graph into an SVG canvas.
Why This Split Exists¶
This keeps graph generation testable without a browser, keeps the UI package reusable, and avoids coupling the frontend directly to raw domain schemas.