From 8925a502ae141f669bd078a375512818dc4bfe79 Mon Sep 17 00:00:00 2001 From: mos-dt-0 Date: Tue, 11 Aug 2026 17:14:38 -0500 Subject: [PATCH] style(webui): prettier-format PHASE-P-STRUCTURE.md format:check was the only red CI step on #1147. Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01Dtdjx4Gxude9fwyLezCrhh --- docs/webui/PHASE-P-STRUCTURE.md | 36 ++++++++++++++++----------------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/webui/PHASE-P-STRUCTURE.md b/docs/webui/PHASE-P-STRUCTURE.md index b82475fb..176f9517 100644 --- a/docs/webui/PHASE-P-STRUCTURE.md +++ b/docs/webui/PHASE-P-STRUCTURE.md @@ -13,7 +13,7 @@ Phase P migrates the Mosaic **web UI** (`apps/web`) from the legacy **Next.js Ap "increment 1/6". The migration is deliberately **incremental and non-destructive**: the new SPA is built up -*beside* the existing Next app, sharing one `apps/web/src/lib` networking/auth layer, until the +_beside_ the existing Next app, sharing one `apps/web/src/lib` networking/auth layer, until the final cutover (P5) removes the Next tree. At every point in between, **both app trees exist in the same package** — this is intentional, not drift. @@ -62,32 +62,32 @@ Legend: `──` new SPA (keep), `══` legacy Next (removed at P5), shared `l - **Dev:** `vite.config.ts` runs a dev-only proxy that forwards those paths to the Gateway (so the SPA on its dev port and the Gateway on `:14242` behave as one origin). - **Prod (target):** the SPA is **same-origin with the Gateway** — the Gateway serves the built - static bundle and the API/WS on `:14242`, so no proxy and no CORS. *(The Gateway does not serve - the web `dist` yet — adding that is the core of P5; see §5.)* + static bundle and the API/WS on `:14242`, so no proxy and no CORS. _(The Gateway does not serve + the web `dist` yet — adding that is the core of P5; see §5.)_ ## 4. Build scripts (`apps/web/package.json`) -| Script | Today | Notes | -|---|---|---| -| `dev` | `next dev` | legacy dev server | -| `dev:vite` | `vite` | SPA dev server (+ dev proxy) | -| `build` | `node ../../scripts/build-web.mjs` | currently a **Next** build | -| `build:vite` | `vite build` | SPA production build → `dist/` | -| `lint` / `typecheck` / `test` | `eslint src` / `tsc --noEmit` / `vitest run` | tree-agnostic | +| Script | Today | Notes | +| ----------------------------- | -------------------------------------------- | ------------------------------ | +| `dev` | `next dev` | legacy dev server | +| `dev:vite` | `vite` | SPA dev server (+ dev proxy) | +| `build` | `node ../../scripts/build-web.mjs` | currently a **Next** build | +| `build:vite` | `vite build` | SPA production build → `dist/` | +| `lint` / `typecheck` / `test` | `eslint src` / `tsc --noEmit` / `vitest run` | tree-agnostic | At **P5** the `:vite` variants become the defaults (`dev`→vite, `build`→vite build) and the Next build path is retired. ## 5. Increment map (P1–P6) -| # | Increment | Branch | Status | -|---|---|---|---| -| **P1** | Vite + React Router skeleton beside Next (entry, router, guards, vitest) | `feat/webui-p1-vite-skeleton` | ✅ merged — PR **#1143** | -| **P2** | SPA data layer + same-origin auth (login/register/SSO pages, guards, relative api/socket/auth-client) | `feat/webui-p2-data-auth` | ✅ merged — PR **#1144** | -| **P3** | Typed SPA **chat** (`spa/chat/*`, `chat-contract.ts`, chat page + error boundary) | `feat/webui-p3-chat` | 🚧 in progress (unmerged) | -| **P4** | Port **projects / tasks / settings / admin** dashboard surfaces into the SPA | _tbd_ | ⏳ not started | -| **P5** | **Cutover**: Gateway serves the Vite `dist` on `:14242`; flip `dev`/`build` to vite; **remove** the legacy Next `app/` tree + `next.config.ts` | _tbd_ | ⏳ not started | -| **P6** | CI / images (trails): build the SPA in CI, ship images | _tbd_ | ⏳ trails | +| # | Increment | Branch | Status | +| ------ | ---------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------- | ------------------------- | +| **P1** | Vite + React Router skeleton beside Next (entry, router, guards, vitest) | `feat/webui-p1-vite-skeleton` | ✅ merged — PR **#1143** | +| **P2** | SPA data layer + same-origin auth (login/register/SSO pages, guards, relative api/socket/auth-client) | `feat/webui-p2-data-auth` | ✅ merged — PR **#1144** | +| **P3** | Typed SPA **chat** (`spa/chat/*`, `chat-contract.ts`, chat page + error boundary) | `feat/webui-p3-chat` | 🚧 in progress (unmerged) | +| **P4** | Port **projects / tasks / settings / admin** dashboard surfaces into the SPA | _tbd_ | ⏳ not started | +| **P5** | **Cutover**: Gateway serves the Vite `dist` on `:14242`; flip `dev`/`build` to vite; **remove** the legacy Next `app/` tree + `next.config.ts` | _tbd_ | ⏳ not started | +| **P6** | CI / images (trails): build the SPA in CI, ship images | _tbd_ | ⏳ trails | Each increment follows the same delivery pipeline: brief traceable to the RFC → author → **independent** integrator verification (build+test+typecheck+lint) → **independent** code + security