fix(desktop): preserve multiline approval descriptions - #62092
fix(desktop): preserve multiline approval descriptions#62092BlackishGreen33 wants to merge 3 commits into
Conversation
|
This PR fixes the floating bar, but the approval card on the tool call still doesn't show the description. Its "Command" toggle shows a placeholder instead of the real command. Asking "what folder are you in?" runs So you approve without seeing the command. Showing the description on that card too would close it. |
|
Thanks for catching this. You're right: once the inline tool approval card is mounted, the floating fallback is hidden, so the description was not visible there. The Command toggle could therefore show only the plugin approval label. I've updated the PR to show the approval description on the inline card as well, with the same multi-line wrapping and bounded scrolling behavior. I also added a regression test for the The follow-up is in |
|
Thanks for the focused follow-up. No blocking problems were identified.
Automated hermes-sweeper review. |
# Conflicts: # apps/desktop/src/components/assistant-ui/tool/approval.test.tsx
Related to open #62411: both render inline approval descriptions, while this PR also preserves multiline, bounded scrolling on the floating fallback. The added fallback scope makes this competing related work, not a duplicate. |
What does this PR do?
Fixes #61249.
Desktop approval descriptions can be hard to review: the floating fallback cuts them down to one line, while the inline tool approval card does not show them at all.
This change preserves line breaks, wraps long text, and lets very long descriptions scroll inside a limited-height area on both approval surfaces.
This keeps the existing plain-text approval payload. It does not add a new rich-content field or renderer.
Related Issue
Fixes #61249
Changes Made
Verification
npm --workspace apps/desktop run test:ui -- approval.test.tsx approval-group.test.tsx(18 passed)npm --workspace apps/desktop run typechecknpm --workspace apps/desktop exec eslint -- src/components/assistant-ui/tool/approval.tsx src/components/assistant-ui/tool/approval.test.tsxnpx prettier --check apps/desktop/src/components/assistant-ui/tool/approval.tsx apps/desktop/src/components/assistant-ui/tool/approval.test.tsxnpm audit(0 vulnerabilities)git diff --checkChecklist