-
Notifications
You must be signed in to change notification settings - Fork 36.9k
Add 'Use Excludes and Ignore Files' toggle to quick access #283663
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
📬 CODENOTIFYThe following users are being notified based on files changed in this PR: @bpaseroMatched files:
|
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.
Pull request overview
This PR adds a toggle control to quick access (file and text search) that allows users to enable or disable exclude settings and ignore files during searches. The toggle uses the same icon (Codicon.exclude) as the Search View and is accessible via Ctrl+Dot (Cmd+Period on Mac) when quick access is open.
Key changes:
- New
UseExcludesTogglewidget extending baseToggleclass with search-specific configuration - Integration of toggle into both file search (
anythingQuickAccess.ts) and text search (textSearchQuickAccess.ts) quick access providers - New
reload()method onIQuickPickinterface to refresh items without changing the search value - Cache key modification to differentiate results based on exclude settings state
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
src/vs/workbench/contrib/search/browser/useExcludesToggle.ts |
New toggle widget class and keyboard action registration for toggling excludes/ignore files |
src/vs/workbench/contrib/search/browser/anythingQuickAccess.ts |
Integrates exclude toggle into file search quick access, modifying query options based on toggle state |
src/vs/workbench/contrib/search/browser/quickTextSearch/textSearchQuickAccess.ts |
Integrates exclude toggle into text search quick access, includes typo fix in comment |
src/vs/workbench/contrib/search/browser/search.contribution.ts |
Registers the toggle contributions with the search module |
src/vs/workbench/contrib/search/common/constants.ts |
Adds new command ID for the toggle action |
src/vs/base/browser/ui/toggle/toggle.ts |
Adds new toggle() method to programmatically toggle state |
src/vs/platform/quickinput/common/quickInput.ts |
Adds reload() method to IQuickPick interface |
src/vs/platform/quickinput/browser/quickInput.ts |
Implements reload() method by firing change value event with current value |
src/vs/workbench/contrib/search/test/browser/useExcludesToggle.test.ts |
Unit tests for the new UseExcludesToggle widget |
src/vs/platform/quickinput/test/browser/quickinput.test.ts |
Tests for the new reload() functionality |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
To be fair, I think Copilot pulled most changes for me from #281303 which is essentially the same. If we decide to take it, probably best to update that PR and let it go in. |
|
I would like to review and test this change but will probably not get to it until next year. |
We will likely be moving it to the original community PR and you're welcome to look at it there. |
Pull request was closed
Fixes #15604
Added a toggle to file and text search quick access to disable exclusions/ignore files. The toggle uses same icon as in Search View and is bound to Ctrl+Dot shortcut.