Skip to content

Add React + Vite operator UI (Phase 9) - #2

Merged
naderassaleh merged 1 commit into
mainfrom
feature/operator-ui
Aug 5, 2026
Merged

naderassaleh merged 1 commit into
mainfrom
feature/operator-ui

Conversation

@naderassaleh

Copy link
Copy Markdown
Owner

What

A thin load-control SPA in frontend/ (React 18 + Vite + React Router). 5 pages, no business logic in the browser — the API is the source of truth.

  • Dashboard (/): today's flights with status
  • Flight Detail (/flights/:flightId): 6 tabs — Load plan, EZFW (v1 + v2 ML), Reconciliation, Loadsheet (with PDF links), EFB, Messages
  • EFB (/efb): fleet-wide acceptance inbox with Accept/Decline
  • Messages (/messages): Inbox, Outbox (with retransmit), Process outbox
  • Health (/health): deep health, audit chain, retention sweep

How to test locally

cd frontend
npm install
npm run dev    # http://localhost:5173

Vite proxies /api/* to :8000 in dev. Backend is unchanged.

Build

npm run build  # ~206 KB minified / 62 KB gzipped

Verification

  • npm run build succeeds
  • pytest still 510 passed
  • Headless Chromium end-to-end through all 5 pages: no console errors
  • 9 screenshots in frontend/screenshots/

Notes

  • Plain CSS (no Tailwind) — easier to read for a novice Python dev
  • No state library — backend is the truth, pages refetch on mount
  • Static dist/ — host from any CDN, set VITE_API_BASE at build time

Adds a thin load-control SPA in frontend/:

  - Dashboard: today's flights with status
  - Flight Detail (6 tabs): load plan, EZFW v1+v2, reconciliation,
    loadsheet with PDF links, EFB acceptance, messages
  - EFB: fleet-wide acceptance inbox with Accept/Decline
  - Messages: Inbox, Outbox (with retransmit), Process outbox
  - Health: deep health, audit chain integrity, retention sweep

Stack: React 18, React Router 6, Vite 5, plain CSS (no Tailwind /
utility framework — easier for a novice to read).

Build output: ~206 KB minified / 62 KB gzipped.

Verified end-to-end against the live backend with Playwright
(headless Chromium, no browser errors).
@naderassaleh
naderassaleh merged commit 1230f84 into main Aug 5, 2026
2 checks passed
@naderassaleh
naderassaleh deleted the feature/operator-ui branch August 5, 2026 05:44
naderassaleh pushed a commit that referenced this pull request Aug 5, 2026
Quick wins #1 and #2:

1. New Fleet page (frontend/src/pages/FleetPage.jsx, +250 lines)
   - Browse all 9 aircraft types with their holds, ULDs, CG envelopes
   - Each type row is expandable to show full details
   - Stats row at top: 9 types, 27 holds, 19 ULDs, 15 envelopes
   - Added 'Fleet' link to top nav
   - CSS for stats row, expand rows, nested tables in styles.css

2. Address book expanded from 10 to 31 tails (data/messages/address_book_seed.json)
   - 21 new tails × 5 message types (LDM, MVT, NOTOC, CPM, UCM) = 105 new addresses
   - Narrow-bodies (A320/A321/E-jets): LDM/MVT/NOTOC → AMMOPRJ, CPM/UCM → AMMFFRJ
   - Wide-bodies (B787):             LDM/MVT/NOTOC → AMMOPRJ, CPM/UCM → AMMKKRJ
   - New script: scripts/expand_address_book.py (idempotent, can be re-run)

Build: vite build passes. Tests: 528/528 pass.
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