Skip to content
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

Adding command descriptions for TF-IDF search #209612

Merged
merged 1 commit into from
Apr 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export class ShowOrFocusStandaloneColorPicker extends EditorAction2 {
super({
id: 'editor.action.showOrFocusStandaloneColorPicker',
title: {
...localize2('showOrFocusStandaloneColorPicker', "Show or Focus Standalone Color Picker"),
...localize2('showOrFocusStandaloneColorPicker', "Show or focus a standalone color picker which uses the default color provider. It displays hex/rgb/hsl colors."),
mnemonicTitle: localize({ key: 'mishowOrFocusStandaloneColorPicker', comment: ['&& denotes a mnemonic'] }, "&&Show or Focus Standalone Color Picker"),
},
precondition: undefined,
Expand Down Expand Up @@ -47,6 +47,9 @@ class HideStandaloneColorPicker extends EditorAction {
kbOpts: {
primary: KeyCode.Escape,
weight: KeybindingWeight.EditorContrib
},
metadata: {
description: localize2('hideColorPickerDescription', "Hide the standalone color picker."),
}
});
}
Expand All @@ -70,6 +73,9 @@ class InsertColorWithStandaloneColorPicker extends EditorAction {
kbOpts: {
primary: KeyCode.Enter,
weight: KeybindingWeight.EditorContrib
},
metadata: {
description: localize2('insertColorWithStandaloneColorPickerDescription', "Insert hex/rgb/hsl colors with the focused standalone color picker."),
}
});
}
Expand Down
47 changes: 37 additions & 10 deletions src/vs/editor/contrib/hover/browser/hover.ts
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,7 @@ class ShowOrFocusHoverAction extends EditorAction {
]
}, "Show or Focus Hover"),
metadata: {
description: `Show or Focus Hover`,
description: nls.localize2('showOrFocusHoverDescription', 'Show or focus the editor hover which shows documentation, references, and other content for a symbol at the current cursor position.'),
args: [{
name: 'args',
schema: {
Expand Down Expand Up @@ -551,7 +551,10 @@ class ShowDefinitionPreviewHoverAction extends EditorAction {
]
}, "Show Definition Preview Hover"),
alias: 'Show Definition Preview Hover',
precondition: undefined
precondition: undefined,
metadata: {
description: nls.localize2('showDefinitionPreviewHoverDescription', 'Show the definition preview hover in the editor.'),
},
});
}

Expand Down Expand Up @@ -596,7 +599,10 @@ class ScrollUpHoverAction extends EditorAction {
kbExpr: EditorContextKeys.hoverFocused,
primary: KeyCode.UpArrow,
weight: KeybindingWeight.EditorContrib
}
},
metadata: {
description: nls.localize2('scrollUpHoverDescription', 'Scroll up the editor hover.')
},
});
}

Expand Down Expand Up @@ -626,7 +632,10 @@ class ScrollDownHoverAction extends EditorAction {
kbExpr: EditorContextKeys.hoverFocused,
primary: KeyCode.DownArrow,
weight: KeybindingWeight.EditorContrib
}
},
metadata: {
description: nls.localize2('scrollDownHoverDescription', 'Scroll down the editor hover.'),
},
});
}

Expand Down Expand Up @@ -656,7 +665,10 @@ class ScrollLeftHoverAction extends EditorAction {
kbExpr: EditorContextKeys.hoverFocused,
primary: KeyCode.LeftArrow,
weight: KeybindingWeight.EditorContrib
}
},
metadata: {
description: nls.localize2('scrollLeftHoverDescription', 'Scroll left the editor hover.'),
},
});
}

Expand Down Expand Up @@ -686,7 +698,10 @@ class ScrollRightHoverAction extends EditorAction {
kbExpr: EditorContextKeys.hoverFocused,
primary: KeyCode.RightArrow,
weight: KeybindingWeight.EditorContrib
}
},
metadata: {
description: nls.localize2('scrollRightHoverDescription', 'Scroll right the editor hover.')
},
});
}

Expand Down Expand Up @@ -717,7 +732,10 @@ class PageUpHoverAction extends EditorAction {
primary: KeyCode.PageUp,
secondary: [KeyMod.Alt | KeyCode.UpArrow],
weight: KeybindingWeight.EditorContrib
}
},
metadata: {
description: nls.localize2('pageUpHoverDescription', 'Page up the editor hover.'),
},
});
}

Expand Down Expand Up @@ -749,7 +767,10 @@ class PageDownHoverAction extends EditorAction {
primary: KeyCode.PageDown,
secondary: [KeyMod.Alt | KeyCode.DownArrow],
weight: KeybindingWeight.EditorContrib
}
},
metadata: {
description: nls.localize2('pageDownHoverDescription', 'Page down the editor hover.'),
},
});
}

Expand Down Expand Up @@ -780,7 +801,10 @@ class GoToTopHoverAction extends EditorAction {
primary: KeyCode.Home,
secondary: [KeyMod.CtrlCmd | KeyCode.UpArrow],
weight: KeybindingWeight.EditorContrib
}
},
metadata: {
description: nls.localize2('goToTopHoverDescription', 'Go to the top of the editor hover.'),
},
});
}

Expand Down Expand Up @@ -812,7 +836,10 @@ class GoToBottomHoverAction extends EditorAction {
primary: KeyCode.End,
secondary: [KeyMod.CtrlCmd | KeyCode.DownArrow],
weight: KeybindingWeight.EditorContrib
}
},
metadata: {
description: nls.localize2('goToBottomHoverDescription', 'Go to the bottom of the editor hover.')
},
});
}

Expand Down
40 changes: 32 additions & 8 deletions src/vs/editor/contrib/indentation/browser/indentation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,10 @@ export class IndentationToSpacesAction extends EditorAction {
id: IndentationToSpacesAction.ID,
label: nls.localize('indentationToSpaces', "Convert Indentation to Spaces"),
alias: 'Convert Indentation to Spaces',
precondition: EditorContextKeys.writable
precondition: EditorContextKeys.writable,
metadata: {
description: nls.localize2('indentationToSpacesDescription', "Conver the tab indentation to spaces."),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Conver => Convert

}
});
}

Expand Down Expand Up @@ -68,7 +71,10 @@ export class IndentationToTabsAction extends EditorAction {
id: IndentationToTabsAction.ID,
label: nls.localize('indentationToTabs', "Convert Indentation to Tabs"),
alias: 'Convert Indentation to Tabs',
precondition: EditorContextKeys.writable
precondition: EditorContextKeys.writable,
metadata: {
description: nls.localize2('indentationToTabsDescription', "Conver the spaces indentation to tabs."),
}
});
}

Expand Down Expand Up @@ -161,7 +167,10 @@ export class IndentUsingTabs extends ChangeIndentationSizeAction {
id: IndentUsingTabs.ID,
label: nls.localize('indentUsingTabs', "Indent Using Tabs"),
alias: 'Indent Using Tabs',
precondition: undefined
precondition: undefined,
metadata: {
description: nls.localize2('indentUsingTabsDescription', "Use indentation with tabs."),
}
});
}
}
Expand All @@ -175,7 +184,10 @@ export class IndentUsingSpaces extends ChangeIndentationSizeAction {
id: IndentUsingSpaces.ID,
label: nls.localize('indentUsingSpaces', "Indent Using Spaces"),
alias: 'Indent Using Spaces',
precondition: undefined
precondition: undefined,
metadata: {
description: nls.localize2('indentUsingSpacesDescription', "Use indentation with spaces."),
}
});
}
}
Expand All @@ -189,7 +201,10 @@ export class ChangeTabDisplaySize extends ChangeIndentationSizeAction {
id: ChangeTabDisplaySize.ID,
label: nls.localize('changeTabDisplaySize', "Change Tab Display Size"),
alias: 'Change Tab Display Size',
precondition: undefined
precondition: undefined,
metadata: {
description: nls.localize2('changeTabDisplaySizeDescription', "Change the space size equivalent of the tab."),
}
});
}
}
Expand All @@ -203,7 +218,10 @@ export class DetectIndentation extends EditorAction {
id: DetectIndentation.ID,
label: nls.localize('detectIndentation', "Detect Indentation from Content"),
alias: 'Detect Indentation from Content',
precondition: undefined
precondition: undefined,
metadata: {
description: nls.localize2('detectIndentationDescription', "Detect the indentation from content."),
}
});
}

Expand All @@ -226,7 +244,10 @@ export class ReindentLinesAction extends EditorAction {
id: 'editor.action.reindentlines',
label: nls.localize('editor.reindentlines', "Reindent Lines"),
alias: 'Reindent Lines',
precondition: EditorContextKeys.writable
precondition: EditorContextKeys.writable,
metadata: {
description: nls.localize2('editor.reindentlinesDescription', "Reindent the lines of the editor."),
}
});
}

Expand All @@ -252,7 +273,10 @@ export class ReindentSelectedLinesAction extends EditorAction {
id: 'editor.action.reindentselectedlines',
label: nls.localize('editor.reindentselectedlines', "Reindent Selected Lines"),
alias: 'Reindent Selected Lines',
precondition: EditorContextKeys.writable
precondition: EditorContextKeys.writable,
metadata: {
description: nls.localize2('editor.reindentselectedlinesDescription', "Reindent the selected lines of the editor."),
}
});
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export class ToggleStickyScroll extends Action2 {
super({
id: 'editor.action.toggleStickyScroll',
title: {
...localize2('toggleEditorStickyScroll', "Toggle Editor Sticky Scroll"),
...localize2('toggleEditorStickyScroll', "Toggle/enable the editor sticky scroll which shows the nested scopes at the top of the viewport."),
mnemonicTitle: localize({ key: 'mitoggleStickyScroll', comment: ['&& denotes a mnemonic'] }, "&&Toggle Editor Sticky Scroll"),
},
category: Categories.View,
Expand Down Expand Up @@ -53,7 +53,7 @@ export class FocusStickyScroll extends EditorAction2 {
super({
id: 'editor.action.focusStickyScroll',
title: {
...localize2('focusStickyScroll', "Focus Sticky Scroll"),
...localize2('focusStickyScroll', "Focus on the editor sticky scroll"),
mnemonicTitle: localize({ key: 'mifocusStickyScroll', comment: ['&& denotes a mnemonic'] }, "&&Focus Sticky Scroll"),
},
precondition: ContextKeyExpr.and(ContextKeyExpr.has('config.editor.stickyScroll.enabled'), EditorContextKeys.stickyScrollVisible),
Expand All @@ -72,7 +72,7 @@ export class SelectNextStickyScrollLine extends EditorAction2 {
constructor() {
super({
id: 'editor.action.selectNextStickyScrollLine',
title: localize2('selectNextStickyScrollLine.title', "Select next sticky scroll line"),
title: localize2('selectNextStickyScrollLine.title', "Select the next editor sticky scroll line"),
precondition: EditorContextKeys.stickyScrollFocused.isEqualTo(true),
keybinding: {
weight,
Expand All @@ -90,7 +90,7 @@ export class SelectPreviousStickyScrollLine extends EditorAction2 {
constructor() {
super({
id: 'editor.action.selectPreviousStickyScrollLine',
title: localize2('selectPreviousStickyScrollLine.title', "Select previous sticky scroll line"),
title: localize2('selectPreviousStickyScrollLine.title', "Select the previous sticky scroll line"),
precondition: EditorContextKeys.stickyScrollFocused.isEqualTo(true),
keybinding: {
weight,
Expand All @@ -108,7 +108,7 @@ export class GoToStickyScrollLine extends EditorAction2 {
constructor() {
super({
id: 'editor.action.goToFocusedStickyScrollLine',
title: localize2('goToFocusedStickyScrollLine.title', "Go to focused sticky scroll line"),
title: localize2('goToFocusedStickyScrollLine.title', "Go to the focused sticky scroll line"),
precondition: EditorContextKeys.stickyScrollFocused.isEqualTo(true),
keybinding: {
weight,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ export function registerMoveActions() {
constructor() {
super({
id: `workbench.action.chat.openInNewWindow`,
title: localize2('interactiveSession.openInNewWindow.label', "Open Chat in New Window"),
title: localize2('interactiveSession.openInNewWindow.label', "Open/move the panel chat to an undocked window."),
category: CHAT_CATEGORY,
precondition: CONTEXT_PROVIDER_EXISTS,
f1: true
Expand Down
Loading