Skip to content

feat(react): add optional 3D city map - #238

Draft
raphox wants to merge 5 commits into
TanStack:mainfrom
raphox:codex/atlas-city-map
Draft

raphox wants to merge 5 commits into
TanStack:mainfrom
raphox:codex/atlas-city-map

Conversation

@raphox

@raphox raphox commented Oct 21, 2026 •

Copy link
Copy Markdown

Add an opt-in React city renderer that encodes metrics as building heights, category intersections as districts, and health status as building effects. Records retain their identity through the existing mark, scene, renderer, focus, and selection contracts.

image

Reference: https://raphox.github.io/atlas/

  • Expose the city capability from @tanstack/react-charts/city, mirrored at @tanstack/charts/react/city, with an optional Three.js peer.
  • Own scoped presentation in the renderer, preserving sideEffects: false and the ordinary chart entry points. Consumers import the component without a separate stylesheet.
  • Render the normal semantic SVG scene for SSR and WebGL initialization failure; the WebGL canvas paints the interactive city above that scene.
  • Register benchmarks/conformance/cases/city-map with the standard case.json, self-contained example.tsx, typed data, tanstack.ts, isolated Plot reference, and package/case regressions.
  • Use the shared React mount and definition-only preview helpers. The live catalog displays the WebGL map and source; compact previews and the Plot comparison use its semantic district layout.
  • Document the capability in the mark reference and existing maps/spatial guide, with the regular catalog embed, navigation, metadata index, preview, and coverage inventories.
  • Keep regression tests alongside the package and use the existing Vitest, conformance, documentation, and packaging commands.

The internal Atlas engine remains JavaScript behind explicit TypeScript public contracts. This draft requests feedback on the API and package placement. The Atlas code is offered under the repository's MIT license with authorization to distribute it.

Validation:

  • Main Vitest suite: 306 files / 2,300 tests passed.
  • TypeScript, public callback, source-example, catalog index, documentation, formatting, and diff contracts passed.
  • Standard first-party conformance matrix passed. The scoped Plot comparison passed with clean types and matching semantic geometry/paints.
  • Chromium catalog check passed with WebGL, camera controls, and source display, with no page errors.
  • Installed tarball runtime/declaration checks passed, including React 18 SSR without warnings, React Native/Expo, framework adapters, and the unified city entry.
  • Catalog previews generated and checked with the existing catalog tooling.

To try locally, run pnpm dev:conformance and open /charts/city-map/.

@coderabbitai

coderabbitai Bot commented Oct 21, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@changeset-bot

changeset-bot Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 70bf7ae

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 12 packages
Name Type
@tanstack/react-charts Minor
@tanstack/charts Minor
@tanstack/alpine-charts Minor
@tanstack/angular-charts Minor
@tanstack/lit-charts Minor
@tanstack/octane-charts Minor
@tanstack/preact-charts Minor
@tanstack/react-native-charts Minor
@tanstack/solid-charts Minor
@tanstack/svelte-charts Minor
@tanstack/vue-charts Minor
@tanstack/charts-scales Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@socket-security

socket-security Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Addedthree@​0.180.0981009892100

View full report

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant