Repository navigation
fix(ui): reserve bubble space for code block copy (#69605) - #69689
ly85206559 wants to merge 1 commit into
Conversation
Apply has-copy on assistant bubbles when copy/expand actions show, so floating controls do not overlap fenced code-block copy. Fixes openclaw#69605.
Greptile SummaryApplies the existing Confidence Score: 5/5Safe to merge — minimal, well-scoped CSS class addition with new unit test coverage. The change is a single-line addition that applies an already-defined CSS class. The condition is correctly scoped to assistant-only messages with markdown content (mirrors the exact predicate already used to decide whether to render the actions overlay). Two new tests verify both the positive and negative cases. No logic, data flow, or security surface was touched. No files require special attention. Reviews (1): Last reviewed commit: "fix(ui): reserve bubble space for code b..." | Re-trigger Greptile |
|
Related work from PRtags group Title: Open PR duplicate: code block copy overlap in Control UI
|
Summary
.chat-bubble.has-copyclass when assistant bubbles show copy/expand actions (ui/src/ui/chat/grouped-render.ts), reserving right padding perui/src/styles/chat/grouped.css.handleCodeBlockCopy, or clipboard APIs.Change Type
Scope
Linked Issue/PR
Root Cause
has-copyCSS existed for bubble actions but was never applied inrenderAssistantBubble, so.chat-bubble-actionscould overlap fenced code-block Copy controls; users hit “Copy as markdown” instead.hover: none) keeps actions always interactive on some setups, increasing overlap risk.Regression Test Plan
ui/src/ui/chat/grouped-render.test.tshas-copy; user bubbles do not.User-visible / Behavior Changes
Diagram
Security Impact
Repro + Verification
Environment
Steps
Expected
Actual (before fix)
Evidence
pnpm test ui/src/ui/chat/grouped-render.test.ts— passpnpm check:changed— passHuman Verification
has-copywhen actions present).has-copy).Compatibility / Migration
Risks and Mitigations