Conversation
walkDir dropped symlink entries because a symlink Dirent reports false for both isFile() and isDirectory(). Resolve the target type via stat so linked files/dirs appear; broken links surface as files. (#353) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The Copy button is position:fixed at coords captured when the selection was made. Scrolling the chat (trackpad, no mousedown) or resizing left it pinned in the viewport forever. Reposition on scroll/resize, hide once the selection scrolls out of the chat's visible bounds. Placement math extracted to computeCopyButtonPlacement with unit tests. (#353) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Following the symlink walkDir fix, a symlinked directory pointing outside cwd would get its contents enumerated, bypassing the resolveWithin / file-protocol containment boundary. Gate recursion on an isWithinCwd realpath check (mirrors main.ts file handler); outside-cwd linked dirs still show but render empty. Add right-edge clamp test for copy button. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
Addresses both items from #353 (GCC user feedback session).
1. Show symlinked files in the files tab
walkDirdropped symlink entries because a symlinkDirentreportsfalsefor bothisFile()andisDirectory(). It now resolves the target type viastat:main.tsfile-protocol containment guard, so a symlink can't expose content outside the working directory); outside-cwd linked dirs still show but render empty2. Copy button sticks around forever
The selection Copy button is
position:fixedat coords captured when text was selected. Scrolling the chat with a trackpad (no mousedown) left it pinned in the viewport. It now repositions on scroll/resize and hides once the selection scrolls out of the chat's visible bounds. Placement math extracted to a purecomputeCopyButtonPlacementfor unit testing.Tests
New
tests/files-walkdir-symlinks.test.ts(real tmpdir with file/dir/broken/outside-cwd links) andcomputeCopyButtonPlacementcases intests/chat-panel.test.ts. Full suite: 924 passing; apptsc --noEmitclean.🤖 Generated with Claude Code