Repository navigation
Conversation
ymichael
force-pushed
the
bb/a4-move-side-chat-s-special-cases-out-of-core-thr_5tzkxrtnns
branch
from
October 2, 2026 18:13
98ebb58 to
4e9a17f
Compare
ymichael
force-pushed
the
bb/a5-react-message-metadata-slot-thr_ru7pk3b7tf
branch
from
October 2, 2026 18:16
9f37f14 to
f5b980f
Compare
ymichael
force-pushed
the
bb/a4-move-side-chat-s-special-cases-out-of-core-thr_5tzkxrtnns
branch
from
October 5, 2026 19:16
4e9a17f to
8d9cab3
Compare
ymichael
force-pushed
the
bb/a5-react-message-metadata-slot-thr_ru7pk3b7tf
branch
from
October 5, 2026 19:22
f5b980f to
25f7a76
Compare
ymichael
force-pushed
the
bb/a4-move-side-chat-s-special-cases-out-of-core-thr_5tzkxrtnns
branch
2 times, most recently
from
October 5, 2026 23:08
9738d53 to
9a21b6b
Compare
Base automatically changed from
bb/a4-move-side-chat-s-special-cases-out-of-core-thr_5tzkxrtnns
to
main
October 5, 2026 23:31
ymichael
force-pushed
the
bb/a5-react-message-metadata-slot-thr_ru7pk3b7tf
branch
2 times, most recently
from
October 6, 2026 00:22
961dd7b to
8e4c472
Compare
ymichael
force-pushed
the
bb/a5-react-message-metadata-slot-thr_ru7pk3b7tf
branch
from
October 6, 2026 23:25
8e4c472 to
0422f5b
Compare
Collaborator
|
This is an automated message. We have closed this pull request because it has been open for more than two weeks. |
ymichael
added a commit
that referenced
this pull request
Oct 29, 2026
…ugin slot (#6519) ## Human comments ## What was wrong A message's send time was visible only in the footer of its `⋯` menu, so checking when a message was sent took two clicks per message (#5745). Plugins had no supported way to put metadata beside messages either. Marketplace plugins (Message Timestamps, Message Date & Time, Tok Speed, Turn TPS) find timeline rows with DOM selectors and MutationObservers, and they break when bb's markup changes: Message Timestamps' action-row selector no longer matches, so it falls back to rendering above the bubble. ## What changed - Revives #4701 as `app.slots.experimental_messageMetadata({ id, placement?, component })` (Plugin SDK 0.6.98), with two placements: - `"above"` (default): over the message, aligned to its side (13px inset on user bubbles to match the action row, the prose inset on assistant messages). - `"actionRow"`: in the message's action row. It shows and hides exactly like the actions, sits before them on user messages and after `⋯` on assistant messages, and extends into the space beside the message instead of narrowing them, so a short message keeps the same inline actions. - The component receives `{ message }`: `id`, `threadId`, `role`, `createdAt`, `turnId`, and `initiator` on user messages. It never gets message text, so streaming does not re-render metadata. Plugin contributions get plugin context, CSS, and their own error and Suspense boundaries. - A placement whose contributions all return null takes no space. - #4701's `below` placement is dropped: in the marketplace only Turn TPS decorates below a message, and its data is per turn. - Core uses the slot for the #5745 fix. `core-message-metadata.tsx` registers the inline time through `definePluginApp` (the same pattern as the core Info tab) with `placement: "actionRow"`, and it renders through the same `MessageMetadata` host as plugin contributions. The label is `formatShortMessageTime` ("4:29 PM" today, "Oct 27, 4:29 PM" before), with the full date in its tooltip. - Device policy belongs to the component. The core time returns null on coarse-pointer devices, so touch keeps the time only in the `⋯` drawer footer, as #5745 asks. - Time formatting moves to `message-time.tsx` and is shared by the inline time, the menu footer, and generated (agent/automation) messages. - Docs: `docs/api_to_audit.md` entry, plugin authoring references, and a Plugin Guide card, fixture, and wireframe. No server, daemon, or wire changes. ## How you verified - `pnpm exec turbo run typecheck lint test --filter=@bb/app --filter=@get-bb/plugin-sdk --filter=bb-plugin-plugin-api-docs`: all pass (644 app test files), plus the server's `plugin-authoring-docs.test.ts`. - New test in `ThreadTimelineRows.row-isolation.test.tsx`: the message time renders as a `<time>` in the action row without opening the menu, before the actions on user messages and after `⋯` on assistant messages. It fails when the core registration is removed. - The SDK harness covers placement validation; row tests cover the `above` and `actionRow` placements and that metadata does not re-render while assistant text streams. - Visual QA in a temporary Ladle story rendering real `ThreadTimelineRows`, at 1100px desktop and a 390px phone with emulated touch: - the time is hidden at rest, appears on hover, and stays visible while the menu is open; - short messages show the full date beside the bubble without changing the inline actions; - on touch the core time is hidden, while a plugin's own `actionRow` item still shows; - checked in light and dark, with multiple plugins per placement. Fixes #5745 > AGENT GENERATED 🤖 Generated with [Claude Code](https://claude.com/claude-code) --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
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.
Human comments
What was wrong
Plugins could add message actions and inline directives, but had no React slot for metadata beside a conversation message. Putting metadata inside the body also couples it to streaming text updates.
What changed
Adds
app.slots.experimental_messageMetadata({ id, placement?, component })above or below realized user and assistant messages in the main timeline and embeddedThreadChat. Components receive stable identity, creation time, role, nullable turn identity, and user initiator. Returning null filters messages. BB supplies deterministic ordering, plugin context, and independent error/suspense boundaries; windowed-out rows unmount. Creation time uses the message start timestamp so streaming deltas do not rerender unchanged metadata.A5 only: no action-role/placement filters or omitted surfaces. Adds SDK collector/harness support, Plugin Guide card/anchors, authoring inventory, and experimental audit entry. SDK is 0.6.26, above current main's 0.6.25. No daemon wire changes or new CLI commands; fixture plugins use existing build/install commands.
How you verified
pnpm exec turbo run typecheck lint test --filter=@bb/app --filter=@get-bb/plugin-sdk --filter=bb-plugin-plugin-api-docs --concurrency=2passes after rebasing onto current main: 5,475 app tests plus the SDK and Guide suites. The streaming regression fails with the previous update-timestamp mapping and passes with the start timestamp.ThreadChatverifies mount/unmount and remount, with no mounted metadata outside realized rows.Configured review fixture. The fixture intentionally includes a throwing contribution. CI is rerunning on the rebased head.