microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
162.39k stars 28.62k forks source link

API: Allow extensions to render a table in a view #118115

Open joaomoreno opened 3 years ago

joaomoreno commented 3 years ago

It would be great for extensions to be able to render a table in a view, instead of a tree.

@IanMatthewHuff says:

Basically we just wanted to ask if this is a control that would be exposed in the public API in the future? Working with webviews we have a lot of flexibility but there are big trade-offs with having to deal with stuff like theming, accessibility, UI look and feel, webview building and so on. If this table view is something that we could use or be involved with testing we’d be very interested.

And I tend to agree!

IanMatthewHuff commented 3 years ago

I know that things are just in the proposed stage now. But if this helps any I'll share out quick our teams planned usage of a table control to lay out what we are looking to do.

Currently this is the table control that we are using for variables. It's based off a third party grid control and while it works, it's not great with look / feel / accessibility compared to a VS Code native control: image

The data here is obviously placeholder, but this is the new design from our design team: image

Functionality wise. The columns are just basic value columns. The icon buttons (to the right of container 1) would appear when any row is hovered over. The icons are basically just action / commands relative to the row in question. With the option for icon overflow.

The pin icon on the left is an option to pin rows to the top of the view. This would break them out of the sort order and allow for keeping them at the top of the list.

Obviously some of these requests (like the pinning) might not be requests on the vscode table control to provide. But more requests on the vscode table control to be flexible enough for us to provider that functionality ourselves. As something like pinning would involve letting us break items out of sort order.

worksofliam commented 2 years ago

Please expose this API.

mariusGundersen commented 9 months ago

Di this nothing go anywhere? The tree view is nice, but it would be great with a table view

worksofliam commented 5 months ago

I am wondering what the state of this is. The table API is used by the Ports view, and is toggleable in the Problems view now.