feat: live R3F effort graph viz with SSE subscriptions#223
Draft
tonyketcham wants to merge 4 commits into
Draft
Conversation
Add a Vercel-styled interactive Effort Graph visualization and the live channel it needs. - Mount GET /events SSE on the GraphQL live server (ready + generation) - Expose LiveSchemaReloader.subscribe for leak-free generation fans-out - Ship examples/effort-viz: R3F 2D scene, space-colonization growth physics, deterministic OKLCH effort colors, light/dark theme - Dogfoods ../../.flatbread-efforts via flatbread start --watch - Convenience script: pnpm play:efforts Change-Id: I85953a7374dcfea1e84c52dc48cc286e71165881
Frame the orthographic camera on settled simulation bounds so the graph fills the viewport, show labels on hover, and fetch rejected_by / mitigated_by / decision invalidates for richer live edges. Change-Id: I41dec139e1489ccb286314b1b51e6fcc9e1bbdaf
Drop invalidates/rejected_by/mitigated_by selections that the dogfood content graph does not currently expose on Decision/Risk, restoring a valid live GraphQL document. Change-Id: I2019b14f534695707452a27f02c2b11180cdf685
Use deterministic OKLCH samples in the kind legend instead of muted grey dots. Change-Id: Ia2294aac2e76fb152ab8a5ffb8b1aa747643c286
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a Vercel-styled interactive Effort Graph visualization and the live channel it needs.
What's included
GET /eventsSSE on the GraphQL live server (ready+generationframes) so clients can subscribe to content reloads without pollingLiveSchemaReloader.subscribefor leak-free generation fan-out (SSE unsubscribes on disconnect)examples/effort-viz: R3F orthographic 2D scene with space-colonization / slime-growth physics, soft repulsion displacement on add/remove, deterministic vibrant OKLCH colors per effort, light/dark theme.flatbread-effortsviaflatbread start --watchpnpm play:effortsHow to try
Open http://localhost:3000 — GraphQL on
:5057, live updates via/events.Tests
packages/flatbread/src/graphql/liveServerEvents.test.ts— SSE ready + generation framespackages/coreliveSchema subscribe coverageexamples/effort-vizphysics unit tests (pnpm --filter effort-viz test)Manual verification