diff --git a/src/vs/workbench/contrib/codeEditor/browser/untitledTextEditorHint.ts b/src/vs/workbench/contrib/codeEditor/browser/untitledTextEditorHint.ts index c5e1a0cba174d..353965fd9fa8c 100644 --- a/src/vs/workbench/contrib/codeEditor/browser/untitledTextEditorHint.ts +++ b/src/vs/workbench/contrib/codeEditor/browser/untitledTextEditorHint.ts @@ -106,6 +106,20 @@ class UntitledTextEditorHintContentWidget implements IContentWidget { if (!this.domNode) { this.domNode = $('.untitled-hint'); this.domNode.style.width = 'max-content'; + + const editorType = $('a.editor-type'); + editorType.style.cursor = 'pointer'; + editorType.innerText = localize('notLookingForTextEditor', "Not looking for a text editor?"); + const selectEditorTypeKeyBinding = this.keybindingService.lookupKeybinding('welcome.showNewFileEntries'); + const selectEditorTypeKeybindingLabel = selectEditorTypeKeyBinding?.getLabel(); + if (selectEditorTypeKeybindingLabel) { + editorType.title = localize('keyboardBindingTooltip', "{0}", selectEditorTypeKeybindingLabel); + } + this.domNode.appendChild(editorType); + + this.domNode.appendChild($('br')); + this.domNode.appendChild($('br')); + const language = $('a.language-mode'); language.style.cursor = 'pointer'; language.innerText = localize('selectAlanguage2', "Select a language"); @@ -116,20 +130,6 @@ class UntitledTextEditorHintContentWidget implements IContentWidget { } this.domNode.appendChild(language); - const or = $('span'); - or.innerText = localize('or', " or ",); - this.domNode.appendChild(or); - - const chooseEditor = $('a.choose-editor'); - chooseEditor.style.cursor = 'pointer'; - chooseEditor.innerText = localize('chooseEditor', "select a different editor"); - const chooseEditorKeyBinding = this.keybindingService.lookupKeybinding('welcome.showNewFileEntries'); - const chooseEditorKeybindingLabel = chooseEditorKeyBinding?.getLabel(); - if (chooseEditorKeybindingLabel) { - chooseEditor.title = localize('chooseEditorBindingTooltip', "{0}", chooseEditorKeybindingLabel); - } - this.domNode.appendChild(chooseEditor); - const toGetStarted = $('span'); toGetStarted.innerText = localize('toGetStarted', " to get started. Start typing to dismiss, or ",); this.domNode.appendChild(toGetStarted); @@ -165,9 +165,9 @@ class UntitledTextEditorHintContentWidget implements IContentWidget { this.editorGroupsService.activeGroup.closeEditor(activeEditorInput, { preserveFocus: true }); } }; - this.toDispose.push(dom.addDisposableListener(chooseEditor, 'click', chooseEditorOnClickOrTap)); - this.toDispose.push(dom.addDisposableListener(chooseEditor, GestureEventType.Tap, chooseEditorOnClickOrTap)); - this.toDispose.push(Gesture.addTarget(chooseEditor)); + this.toDispose.push(dom.addDisposableListener(editorType, 'click', chooseEditorOnClickOrTap)); + this.toDispose.push(dom.addDisposableListener(editorType, GestureEventType.Tap, chooseEditorOnClickOrTap)); + this.toDispose.push(Gesture.addTarget(editorType)); const dontShowOnClickOrTap = () => { this.configurationService.updateValue(untitledTextEditorHintSetting, 'hidden'); diff --git a/src/vs/workbench/contrib/files/browser/views/explorerView.ts b/src/vs/workbench/contrib/files/browser/views/explorerView.ts index a7885058f6a00..c82cc35150a23 100644 --- a/src/vs/workbench/contrib/files/browser/views/explorerView.ts +++ b/src/vs/workbench/contrib/files/browser/views/explorerView.ts @@ -891,7 +891,7 @@ registerAction2(class extends Action2 { constructor() { super({ id: 'workbench.files.action.createFileFromExplorer', - title: nls.localize('createNewEditor', "New Editor"), + title: nls.localize('createNewFile', "New File"), f1: false, icon: Codicon.newFile, precondition: ExplorerResourceNotReadonlyContext, diff --git a/src/vs/workbench/contrib/welcomeGettingStarted/common/gettingStartedContent.ts b/src/vs/workbench/contrib/welcomeGettingStarted/common/gettingStartedContent.ts index ac4305b3e3def..a091be87b19f3 100644 --- a/src/vs/workbench/contrib/welcomeGettingStarted/common/gettingStartedContent.ts +++ b/src/vs/workbench/contrib/welcomeGettingStarted/common/gettingStartedContent.ts @@ -57,8 +57,8 @@ type GettingStartedStartEntryContent = BuiltinGettingStartedStartEntry[]; export const startEntries: GettingStartedStartEntryContent = [ { id: 'welcome.showNewFileEntries', - title: localize('gettingStarted.newEditor.title', "New Editor..."), - description: localize('gettingStarted.newEditor.description', "Open a new untitled file, notebook, or custom editor."), + title: localize('gettingStarted.newFile.title', "New File..."), + description: localize('gettingStarted.newFile.description', "Open a new untitled file, notebook, or custom editor."), icon: Codicon.newFile, content: { type: 'startEntry', diff --git a/src/vs/workbench/contrib/welcomeViews/common/newFile.contribution.ts b/src/vs/workbench/contrib/welcomeViews/common/newFile.contribution.ts index 3c20b55f28a11..8b87c52e229f9 100644 --- a/src/vs/workbench/contrib/welcomeViews/common/newFile.contribution.ts +++ b/src/vs/workbench/contrib/welcomeViews/common/newFile.contribution.ts @@ -25,7 +25,7 @@ registerAction2(class extends Action2 { constructor() { super({ id: 'welcome.showNewFileEntries', - title: { value: localize('welcome.newEditor', "New Editor..."), original: 'New Editor...' }, + title: { value: localize('welcome.newFile', "New File..."), original: 'New File...' }, category, f1: true, keybinding: { diff --git a/src/vs/workbench/services/actions/common/menusExtensionPoint.ts b/src/vs/workbench/services/actions/common/menusExtensionPoint.ts index 3aa9a03609064..7e06c120f9562 100644 --- a/src/vs/workbench/services/actions/common/menusExtensionPoint.ts +++ b/src/vs/workbench/services/actions/common/menusExtensionPoint.ts @@ -242,7 +242,7 @@ const apiMenus: IAPIMenu[] = [ { key: 'file/newFile', id: MenuId.NewFile, - description: localize('file.newEditor', "The 'New Editor...' quick pick, shown on welcome page and File menu."), + description: localize('file.newFile', "The 'New File...' quick pick, shown on welcome page and File menu."), supportsSubmenus: false, }, {