refactor(vscode): improve statusbar item display#17511
refactor(vscode): improve statusbar item display#17511graphite-app[bot] merged 1 commit intomainfrom
Conversation
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
8a45f42 to
3b9ba0b
Compare
There was a problem hiding this comment.
Pull request overview
This PR refactors the VSCode extension's status bar item display logic to improve how tool states are communicated to users. The changes centralize tooltip generation and simplify the handling of missing binary paths.
- Introduced a new
ToolStatetype to track tool enabled state, content, and version in a structured way - Moved binary path validation logic from
extension.tsinto individual toolactivatemethods - Simplified status bar icon and background color logic based on binary availability
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
editors/vscode/client/StatusBarItemHandler.ts |
Refactored tooltip handling to use ToolState type and unified tooltip generation with version display |
editors/vscode/client/extension.ts |
Simplified binary path handling by moving validation into tools and added icon logic based on binary availability |
editors/vscode/client/tools/ToolInterface.ts |
Changed binaryPath parameter from required to optional in the activate method signature |
editors/vscode/client/tools/linter.ts |
Added early return for missing binary paths and refactored status bar state logic to use new isEnabled pattern |
editors/vscode/client/tools/formatter.ts |
Added early return for missing binary paths and updated status bar method call to use new unified API |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
3b9ba0b to
31d28b8
Compare
31d28b8 to
44d7681
Compare
Merge activity
|
This PR refactors the VSCode extension's status bar item display logic . - Double Checkmark: Both tools (oxlint / oxfmt) are found and can be used - Single Checkmark: One of the tools binary could not be found and is deactivated - Circle: None of tools binary could be found The background color changed a bit too. The error background is not shown anymore, only the warning background when no binaries could be found. closes #17483 <img width="204" height="271" alt="grafik" src="https://github.com/user-attachments/assets/95f180a0-34ec-4d59-bd89-477d4d5fe754" /> <img width="198" height="247" alt="grafik" src="https://github.com/user-attachments/assets/2155bff6-e7e6-46b5-8ebb-8ab5036fafbc" /> <img width="179" height="177" alt="grafik" src="https://github.com/user-attachments/assets/32ed59db-4caa-4a0a-89c9-65ca7caef171" /> <img width="184" height="287" alt="grafik" src="https://github.com/user-attachments/assets/759bd775-fa43-4371-a3db-ef668951aa6d" /> PS: the `v(version)` in the screenshots are outdated 😅
44d7681 to
dc37666
Compare
|
@Sysix thanks for the fix, any idea when it's going to be released? |

This PR refactors the VSCode extension's status bar item display logic .
The background color changed a bit too. The error background is not shown anymore, only the warning background when no binaries could be found.
closes #17483
PS: the
v(version)in the screenshots are outdated 😅