Skip to content

Commit

Permalink
remove "start with snippet" from new file hint until we have file tem…
Browse files Browse the repository at this point in the history
…plate snippets, (#155961)

#145929
  • Loading branch information
jrieken authored Jul 22, 2022
1 parent db13aa6 commit 3558758
Showing 1 changed file with 2 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ class UntitledTextEditorHintContentWidget implements IContentWidget {
this.domNode = $('.untitled-hint');
this.domNode.style.width = 'max-content';

const hintMsg = localize({ key: 'message', comment: ['Presereve double-square brackets and their order'] }, '[[Select a language]], [[start with a snippet]], or [[open a different editor]] to get started.\nStart typing to dismiss or [[don\'t show]] this again.');
const hintMsg = localize({ key: 'message', comment: ['Presereve double-square brackets and their order'] }, '[[Select a language]], or [[open a different editor]] to get started.\nStart typing to dismiss or [[don\'t show]] this again.');
const hintHandler: IContentActionHandler = {
disposables: this.toDispose,
callback: (index, event) => {
Expand All @@ -117,12 +117,9 @@ class UntitledTextEditorHintContentWidget implements IContentWidget {
languageOnClickOrTap(event.browserEvent);
break;
case '1':
snippetOnClickOrTab(event.browserEvent);
break;
case '2':
chooseEditorOnClickOrTap(event.browserEvent);
break;
case '3':
case '2':
dontShowOnClickOrTap();
break;
}
Expand Down Expand Up @@ -153,12 +150,6 @@ class UntitledTextEditorHintContentWidget implements IContentWidget {
this.editor.focus();
};

const snippetOnClickOrTab = async (e: MouseEvent) => {
e.stopPropagation();
this.editor.focus();
this.commandService.executeCommand(ApplyFileSnippetAction.Id, { from: 'hint' });
};

const chooseEditorOnClickOrTap = async (e: MouseEvent) => {
e.stopPropagation();

Expand Down

0 comments on commit 3558758

Please sign in to comment.