MoonGeometry is an interactive educational web app for seeing how the Moon’s orbital geometry becomes the Moon’s apparent path in a local sky.
The current working app lives in app/. It is a React / Vite / Three.js prototype imported from the Grok-generated moon-path-source.zip and then iterated in this repository.
Run the app from the app/ directory:
cd app
npm ci
npm run dev
The app is committed with app/.grok/app-env.json containing:
{
"VITE_AUTH_ENABLED": "false"
}
That flag disables the imported Grok auth gate for local/public development. If you regenerate the Grok scaffold or delete .grok/, restore that file or set VITE_AUTH_ENABLED=false in your environment.
The local development server runs at:
http://localhost:8080/
The current screen contains two main synchronized views:
The app also includes an Explain panel with:
The current implementation is an educational mean-orbit model, not a precision ephemeris.
It uses:
It does not currently implement:
The label in the app is intentional:
Angles true · distances fiction
The goal is to make the geometry understandable before replacing the simplified model with a production-grade ephemeris.
app/ Current runnable React/Vite/Three.js app
sketches/ Earlier disposable UI layout sketches
*.md Product, astronomy and UI design notes
Moon_Path_Vision_Specification.docx Imported vision/spec document
The app/ tree still contains some imported Grok scaffold code for auth, app-data and preview hosting. The MoonGeometry product code is concentrated in app/src/components/moon-app.tsx, space-scene.tsx, sky-chart.tsx, moon-phase.tsx, and app/src/lib/astro.ts.
Ignored local/generated items include:
app/node_modules/
app/.vercel/
tools/
*.zip
The root specification documents were written before and during the prototype process. They describe the intended broader product direction, not the exact current screen.
In particular:
PRODUCT_SPEC.md, TECHNICAL_SPEC.md, ASTRONOMY_MODEL.md, UI_UX_SPEC.md, DESIGN_SYSTEM.md, DEVELOPMENT_ROADMAP.md, DIAGRAM_STRATEGY.md and REQUIRED_DIAGRAMS.md are planning / next-design documents.app/ is a different prototype direction: a compact two-view React/Three.js app with an orrery-style view and local sky-path chart.sketches/ contains previous UI explorations and should not be treated as the current app layout.When in doubt, treat app/ as the program and the root specs as design background / future roadmap.
From app/:
npm run dev # local server
npm run typecheck # TypeScript check
npm test # scaffold tests plus astronomy tests
npm run build # production build
The current app’s implementation is deliberately simpler than full precision astronomy, but it is grounded in standard ideas:
The scientific-basis section in the app distinguishes what is implemented now from historical and modern reference context.