Render the open request family through the pending-interaction banner (WS3 layer 4) - #2209
Closed
SawyerHood wants to merge 1 commit into
Closed
Render the open request family through the pending-interaction banner (WS3 layer 4)#2209SawyerHood wants to merge 1 commit into
SawyerHood wants to merge 1 commit into
Conversation
SawyerHood
force-pushed
the
ws3-l4-open-requests
branch
from
August 21, 2026 17:38
f2ae7e8 to
4a104bb
Compare
… (WS3 layer 4)
UI only — WS5 owns the producers. The client now renders interactions by
the §4 split: approvals (command, fileChange, permissionGrant, toolUse)
keep their decision buttons; the open requests render with core renderers
(`user_question`, `plan_review`) or, for `"<pluginId>/<kind>"`, through the
plugin's `pendingInteraction` slot.
- `interaction-request.ts` classifies either wire shape: today's
`PendingInteraction` (a plan review riding the `plan` approval subject, a
plugin request as `kind: "plugin"` + origin) and the target
`InteractionRequestPayload` (`plan_review`, the namespaced plugin kind), so
the UI is ready before the wire moves and unchanged after.
- `PlanReviewRequestBanner`: "Ready to code?" with the plan Markdown and
file path, plan-verdict actions ("Approve plan" / "Keep planning")
resolved through the approval resolution today's wire carries.
- The banner routes plugin requests to `PluginPendingInteractionComposer`
itself (child-thread source link included), so the prompt area no longer
special-cases plugin interactions.
Tests: the classifier over both shapes; the banner rendering a plan review
as a request and a plugin request through the slot keyed by
`<pluginId>/<kind>`. `turbo test --filter=@bb/app`: 3,214 passed.
SawyerHood
force-pushed
the
ws3-l4-open-requests
branch
from
August 21, 2026 18:09
4a104bb to
e2814c2
Compare
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.
WS3 layer 4 of 5, stacked on #2208 (layer 3: mobile). Do not merge — the coordinator reviews, Sawyer merges the stack.
What was wrong
The contract PR defined the open request family (
interactionRequestPayloadSchema:user_question,plan_review,"<pluginId>/<kind>") beside today's wire, but the client still dispatched on the old shape: a finished plan rendered as a permission approval (theplanapproval subject), and a plugin request was special-cased at every mount point (isPluginPendingInteractionbranches in the prompt area) instead of being a request thependingInteractionslot renders. Per §4,userQuestionandplanReviewrender with core renderers and"<pluginId>/<kind>"with the plugin — the UI side of that split did not exist.What changed (UI only; WS5 owns producers)
apps/app/src/components/thread/pending-interactions/interaction-request.ts:classifyInteractionRequestmaps an interaction to{ family: "approval" }or{ family: "request", kind }. It reads both wire shapes — today'sPendingInteraction(plan review on theplanapproval subject; plugin request askind: "plugin"+origin) and the targetInteractionRequestPayload(plan_reviewdirectly; the namespaced plugin kind split withparseExtensionKind) — so the UI is ready before the wire moves and unchanged after it does.ThreadPendingInteractionBannerdispatches through the classifier: approvals keep the decision buttons;user_questionkeeps the answer form;plan_reviewgetsPlanReviewRequestBanner("Ready to code?", the plan Markdown, the plan file path, "Approve plan" / "Keep planning" — never the permission vocabulary), resolving through the approval resolution today's wire carries (resolvesAs: "approval"); a"<pluginId>/<kind>"request mountsPluginPendingInteractionComposer(the plugin'spendingInteractionslot, resolved by plugin id + renderer name) with the child-thread source link.ThreadDetailPromptAreadrops its plugin special-casing and always renders the banner.How you verified
interaction-request.test.ts: approvals stay approvals; today's plan approval lifts into aplan_reviewrequest; the targetplan_reviewanduser_questionpayloads classify; a plugin request classifies identically from today's origin shape and from the namespaced kind.ThreadPendingInteractionBanner.test.tsx: the plan review renders as a request (title, plan body, file path, plan-verdict buttons; "Allow once" absent) and resolvesallow_once/denythrough the approval resolution; a plugin request renders through the registered slot component keyed bysecrets/secret-request.turbo test --filter=@bb/app: 420 files, 3,214 passed (one prompt-area expectation updated: the stack item is the banner's placeholder now that the banner routes plugin requests).turbo typecheck --filter=@bb/appclean.