瀏覽代碼

Adds Collapse command to view nodes

main
Eric Amodio 1 年之前
父節點
當前提交
84e197baab
共有 3 個檔案被更改,包括 17 行新增1 行删除
  1. +15
    -1
      package.json
  2. +1
    -0
      src/constants.ts
  3. +1
    -0
      src/views/viewCommands.ts

+ 15
- 1
package.json 查看文件

@ -6525,6 +6525,11 @@
"icon": "$(close)"
},
{
"command": "gitlens.views.collapseNode",
"title": "Collapse",
"category": "GitLens"
},
{
"command": "gitlens.views.dismissNode",
"title": "Dismiss",
"category": "GitLens",
@ -9385,6 +9390,10 @@
"when": "false"
},
{
"command": "gitlens.views.collapseNode",
"when": "false"
},
{
"command": "gitlens.views.dismissNode",
"when": "false"
},
@ -13081,11 +13090,16 @@
"group": "8_gitlens_actions@98"
},
{
"command": "gitlens.views.expandNode",
"command": "gitlens.views.collapseNode",
"when": "viewItem =~ /gitlens:(branch|compare|folder|results|search|status)\\b/",
"group": "9_gitlens@1"
},
{
"command": "gitlens.views.expandNode",
"when": "viewItem =~ /gitlens:(branch|compare|folder|results|search|status)\\b/",
"group": "9_gitlens@2"
},
{
"command": "gitlens.views.refreshNode",
"when": "viewItem =~ /gitlens:(?!(file|message|date-marker)\\b)/",
"group": "9_gitlens@99"

+ 1
- 0
src/constants.ts 查看文件

@ -606,6 +606,7 @@ export type CoreCommands =
| 'editor.action.showReferences'
| 'editor.action.webvieweditor.showFind'
| 'editorScroll'
| 'list.collapseAllToFocus'
| 'openInTerminal'
| 'revealFileInOS'
| 'revealInExplorer'

+ 1
- 0
src/views/viewCommands.ts 查看文件

@ -136,6 +136,7 @@ export class ViewCommands {
},
this,
);
registerViewCommand('gitlens.views.collapseNode', () => executeCoreCommand('list.collapseAllToFocus'), this);
registerViewCommand(
'gitlens.views.dismissNode',
(n: ViewNode) => canViewDismissNode(n.view) && n.view.dismissNode(n),

Loading…
取消
儲存