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
Context menu for comment threads #151533
Comments
This one may actually be possible for extensions to do with submenus. I'll double check. |
Optimistically adding for June, but will likely end up moving to July. |
Menu proposal (name will likely change):
We already have The current proposal shows the same context menu when you right click anywhere in the comment thread widget (title, individual comment, etc.) and passes the comment thread object to the command that's executed. @laurentlb, would you expect to have different context menus depending on where the right click happened? |
That sounds reasonable. It's possible that someone would want a separate menu when clicking on a specific comment (this could be added later if needed). |
I got some more feedback on the initial proposal. Changes include:
For a full example of how to these menus can be used, you can see microsoft/vscode-pull-request-github#3835 |
@alexr00 "comments/commentThread/title/context": [
{
"command": "pr.resolveReviewThread",
"group": "inline@3",
"when": "commentController =~ /^github-(browse|review)/ && commentThread == canResolve"
},
{
"command": "pr.unresolveReviewThread",
"group": "inline@3",
"when": "commentController =~ /^github-(browse|review)/ && commentThread == canUnresolve"
}
],
"comments/commentThread/comment/context": [
{
"command": "pr.resolveReviewThread",
"group": "inline@3",
"when": "commentController =~ /^github-(browse|review)/ && commentThread == canResolve"
},
{
"command": "pr.unresolveReviewThread",
"group": "inline@3",
"when": "commentController =~ /^github-(browse|review)/ && commentThread == canUnresolve"
}
], However when I look at comment thread in vscode, I only see Using VScode |
@sergei-dyshel thanks for trying this out! It's a right click context menu, so there's no UI for it in the comment widget itself. You can access the menu by right clicking in the title part of the widget and the body part of the widget, respectively. |
Ohh, missed that somehow. I was looking for some "big blue button " in the title section. Thanks for clarification :) |
If anyone wants to use this API in an extension please comment so that I can gauge whether this is worth finalizing. |
From @alexr00 (in #150824):
I think that's a simple feature to add:
The combination of 3-dot + right-click already exists in other parts of vscode and would improve the experience on wide screens.
This would also help us rely less on icons. New users are often confused with all the icons. Plus, there are multiple features we didn't expose precisely because they cannot be explained with an icon.
cc @hermannloose
The text was updated successfully, but these errors were encountered: