Support something like the language status UI for workspace status
The LanguageStatusItem api provides a nice, consolidated way to show language specific information based on the currently active file
However some status info is relevant to the entire workspace instead of just the active file. I'd like to have an equivalent of LanguageStatusItem for these workspace wide items
Currently the workarounds are:
-
Use a
LanguageStatusItemthat always shows. This means the language status UI will have a mix of workspace and language info -
Use normal workspace status items. These work but unfortunately can't be grouped like the
LanguageStatusItemapi provides
Two quick proposals:
WorkspaceStatusItem
Create a new WorkspaceStatusItem API similar to LanguageStatusItem but for workspace-wide information
We would also create a new workspace status UI element in the left side of the status bar
StatusBarItem.group
Add a way to group existing status bar items under a top level item, with a UI similar to the language status item
cc @bpasero with whom I have discussed something very similar today
After talking with @jrieken, we're currently learning towards the WorkspaceStatusItem. Will look into this next iteration
@jrieken For implementing this, I'd like to reuse as much of the language status item code as possible. What do you think about this proposal:
-
Split the common parts of the
LanguageStatusclass out into a new class called something likeGroupedStatusBarItem -
Implement a new class
WorkbenchStatususingGroupedStatusBarItem -
Implement a new
IWorkspaceStatusServicebased onILanguageStatusService
Yeah, that sounds like a reasonable plan
Hold off on verifying a day or so until I can adopt this new API for copilot