-
Notifications
You must be signed in to change notification settings - Fork 2.6k
fix: add tooltips to truncated file paths in chat UI #8280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- Add StandardTooltip wrapper to truncated file paths in ChatRow.tsx - Add StandardTooltip wrapper to truncated file paths in BatchFilePermission.tsx - Shows full file path on hover when text is truncated with ellipsis - Fixes #8278
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test Review
| {removeLeadingNonAlphanumeric(tool.path ?? "") + "\u200E"} | ||
| {tool.reason} | ||
| </span> | ||
| <StandardTooltip content={`${tool.path}${tool.reason ? ` ${tool.reason}` : ""}`}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[P2] If tool.path is undefined the tooltip renders 'undefined'. Use a safe fallback and include an LRM to match the visible text’s directionality.
| <StandardTooltip content={`${tool.path}${tool.reason ? ` ${tool.reason}` : ""}`}> | |
| <StandardTooltip content={`${(tool.path ?? "")}${tool.reason ? ` ${tool.reason}` : ""}${(tool.path ?? "") || tool.reason ? "\u200E" : ""}`}> |
| {file.lineSnippet && ` ${file.lineSnippet}`} | ||
| </span> | ||
| <StandardTooltip | ||
| content={`${file.path}${file.lineSnippet ? ` ${file.lineSnippet}` : ""}`}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[P2] Same issue here. Guard against undefined and add an LRM so the tooltip mirrors the RTL-safe rendering used for the visible text.
| content={`${file.path}${file.lineSnippet ? ` ${file.lineSnippet}` : ""}`}> | |
| <StandardTooltip content={`${(file.path ?? "")}${file.lineSnippet ? ` ${file.lineSnippet}` : ""}${(file.path ?? "") || file.lineSnippet ? "\u200E" : ""}`}> |
This PR fixes issue #8278 by adding tooltips to display full file paths when they are truncated in narrow chat window layouts.
Problem
When file paths are long, they get truncated with ellipsis (...) in the chat UI, making it impossible to see the full path without resizing the chat window.
Solution
StandardTooltipwrapper to truncated file paths inChatRow.tsxfor file read operationsStandardTooltipwrapper to truncated file paths inBatchFilePermission.tsxfor batch file permissionsTesting
Fixes #8278
Important
Add tooltips to truncated file paths in
ChatRow.tsxandBatchFilePermission.tsxto display full paths on hover.StandardTooltipto truncated file paths inChatRow.tsxfor file read operations.StandardTooltipto truncated file paths inBatchFilePermission.tsxfor batch file permissions.This description was created by
for 08cacea. You can customize this summary. It will automatically update as commits are pushed.