feat(broker): carry shell project identity to embedded apps - #13
Merged
Conversation
The capability-bridge welcome dropped BridgeIdentity.project, surfacing
only webId + podRoot. A project-scoped embedded app (Projects) therefore
fell back to its own build-time default and silently disagreed with the
shell's project switcher.
- BrokerIdentity gains `project: { id, name } | null` (null = whole-
workspace / "no project" scope), parsed from the welcome message.
- Add subscribeBrokeredIdentity(fn): fires when the brokered identity or
active project changes so embedded apps re-resolve without an iframe
reload.
- Register the Projects app in the launcher catalog
(NEXT_PUBLIC_APP_PROJECTS_URL, default http://localhost:3160).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
What
Makes the capability bridge propagate the shell's active project to embedded apps, and registers the Projects app in the launcher catalog.
Why
The broker's
welcomehandler droppedBridgeIdentity.project(only surfacedwebId+podRoot). A project-scoped embedded app (Projects) fell back to its build-time default and silently disagreed with the shell's project switcher ("No project" in the shell while the app showed a phantom project).Changes
BrokerIdentitygainsproject: { id, name } | null(null= whole-workspace / "no project" scope), parsed from the welcome message.subscribeBrokeredIdentity(fn)— fires when the brokered identity/project changes so embedded apps re-resolve without an iframe reload.catalog.ts: register Projects (NEXT_PUBLIC_APP_PROJECTS_URL, defaulthttp://localhost:3160).Companion PRs
setProject()push over the bridgeVerification
Playwright-verified live: switching No-project ↔ My-Workspace in the shell updates the embedded app without reloading the iframe.
🤖 Generated with Claude Code