Views map
Generated graph of every built-in SDK view and the action edges between them.
The diagram below is the live, build-time-extracted graph of every built-in
view in @uidex/sdk and the action edges that move between them. It is
regenerated by pnpm --filter @uidex/sdk views-map and drift-checked in CI by
pnpm --filter @uidex/sdk views-map:check.
How it is built
Each ShellAction in the SDK declares an intent discriminator describing
what the action does:
type ShellActionIntent =
| { kind: "push"; viewId: string; refKind?: EntityKind }
| { kind: "pop" }
| { kind: "close" }
| { kind: "navigate"; refKind?: EntityKind }
| { kind: "external"; describe: string }The extractor walks DEFAULT_VIEWS, builds a synthetic ViewContext, calls
each view's actions(ctx) for every matching EntityKind, and harvests the
resulting intent values into edges. The output is committed as
packages/sdk/src/views/map.gen.json (canonical) plus this Mermaid file
(apps/docs/content/docs/sdk/views-map.mmd, deterministically derived from the
JSON).
intent is metadata only — the shell still dispatches via action.perform()
at runtime. A unit test in @uidex/sdk runs each perform() against a
recording stub and asserts the recorded calls match the declared intent,
guarding against drift.
The graph
Nodes:
- Rectangles are SDK views (the things you
pushonto the view stack). - Stadiums are external sinks —
clipboard,highlight, the cloud — i.e. side effects that don't push a view. __exit__(when present) is a synthetic terminal forpopandcloseintents.
Edge labels are the action's label (the human-facing copy in the command
palette and detail panels).
On This Page