Skip to content

Commit 94a48ba

Browse files
authored
Merge pull request microsoft#194328 from microsoft/merogge/tab-focus-mention
add mention of tab moves focus mode to comment widget help dialog
2 parents 4ffcc0d + 61587a2 commit 94a48ba

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/vs/workbench/contrib/comments/browser/comments.contribution.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ import { Disposable } from 'vs/base/common/lifecycle';
2020
import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey';
2121
import { CommentContextKeys } from 'vs/workbench/contrib/comments/common/commentContextKeys';
2222
import { CommentCommandId } from 'vs/workbench/contrib/comments/common/commentCommandIds';
23+
import { ToggleTabFocusModeAction } from 'vs/editor/contrib/toggleTabFocusMode/browser/toggleTabFocusMode';
2324

2425
Registry.as<IConfigurationRegistry>(ConfigurationExtensions.Configuration).registerConfiguration({
2526
id: 'comments',
@@ -69,7 +70,9 @@ registerSingleton(ICommentService, CommentService, InstantiationType.Delayed);
6970

7071
export namespace CommentAccessibilityHelpNLS {
7172
export const intro = nls.localize('intro', "The editor contains commentable range(s). Some useful commands include:");
72-
export const introWidget = nls.localize('introWidget', "Some useful comment commands include:");
73+
export const introWidget = nls.localize('introWidget', "This widget contains a text area, for composition of new comments, and actions, that can be tabbed to once tab moves focus mode has been enabled ({0}).");
74+
export const introWidgetNoKb = nls.localize('introWidgetNoKb', "This widget contains a text area, for composition of new comments, and actions, that can be tabbed to once tab moves focus mode has been enabled with the command Toggle Tab Key Moves Focus, which is currently not triggerable via keybinding.");
75+
export const commentCommands = nls.localize('commentCommands', "Some useful comment commands include:");
7376
export const escape = nls.localize('escape', "- Dismiss Comment (Escape)");
7477
export const nextRange = nls.localize('next', "- Navigate to the next commenting range ({0})");
7578
export const nextRangeNoKb = nls.localize('nextNoKb', "- Go to Next Commenting Range, which is currently not triggerable via keybinding.");
@@ -116,7 +119,8 @@ export class CommentsAccessibilityHelpProvider implements IAccessibleContentProv
116119
provideContent(): string {
117120
this._element = document.activeElement as HTMLElement;
118121
const content: string[] = [];
119-
content.push(CommentAccessibilityHelpNLS.introWidget);
122+
content.push(this._descriptionForCommand(ToggleTabFocusModeAction.ID, CommentAccessibilityHelpNLS.introWidget, CommentAccessibilityHelpNLS.introWidgetNoKb) + '\n');
123+
content.push(CommentAccessibilityHelpNLS.commentCommands);
120124
content.push(CommentAccessibilityHelpNLS.escape);
121125
content.push(this._descriptionForCommand(CommentCommandId.Add, CommentAccessibilityHelpNLS.addComment, CommentAccessibilityHelpNLS.addCommentNoKb));
122126
content.push(this._descriptionForCommand(CommentCommandId.Submit, CommentAccessibilityHelpNLS.submitComment, CommentAccessibilityHelpNLS.submitCommentNoKb));

0 commit comments

Comments
 (0)