diff --git a/src/main/context-menu.ts b/src/main/context-menu.ts index 858754a0ef..5d89b28a1f 100644 --- a/src/main/context-menu.ts +++ b/src/main/context-menu.ts @@ -69,15 +69,6 @@ export function getMonacoItems({ }, }, { type: 'separator' }, - { - id: 'palette', - label: 'Command Palette', - click() { - const cmd = ['editor.action.quickCommand']; - ipcMainManager.send(IpcEvents.MONACO_EXECUTE_COMMAND, cmd); - }, - }, - { type: 'separator' }, { id: 'format_document', label: 'Format Document', diff --git a/tests/main/context-menu-spec.ts b/tests/main/context-menu-spec.ts index 094db446ac..8ceaedd2a2 100644 --- a/tests/main/context-menu-spec.ts +++ b/tests/main/context-menu-spec.ts @@ -203,7 +203,7 @@ describe('context-menu', () => { editFlags: { canPaste: true }, pageURL: 'index.html', } as any); - expect(result).toHaveLength(10); + expect(result).toHaveLength(8); }); it('executes an IPC send() for each element', () => { diff --git a/tools/webpack/webpack.renderer.config.ts b/tools/webpack/webpack.renderer.config.ts index f5f933a000..578da938ce 100644 --- a/tools/webpack/webpack.renderer.config.ts +++ b/tools/webpack/webpack.renderer.config.ts @@ -63,6 +63,15 @@ export const rendererConfig: Configuration = { ...plugins, new MonacoWebpackPlugin({ languages: ['typescript', 'javascript', 'html', 'css'], + // This array maps to specific entries in the Monaco metadata + // To see a full list and where they map to in VSCode, see 'monaco-editor/esm/metadata' + features: [ + '!contextmenu', + '!iPadShowKeyboard', + '!snippets', + '!quickCommand', + '!quickOutline', + ], }), new MiniCssExtractPlugin({ filename: './css/[name].css',