@@ -14,8 +14,6 @@ import { Text, Time } from '@jupyterlab/coreutils';
1414
1515import { IDocumentManager } from '@jupyterlab/docmanager' ;
1616
17- import { IMainMenu } from '@jupyterlab/mainmenu' ;
18-
1917import { NotebookPanel , INotebookTracker } from '@jupyterlab/notebook' ;
2018
2119import { ISettingRegistry } from '@jupyterlab/settingregistry' ;
@@ -26,7 +24,7 @@ import { INotebookShell } from '@jupyter-notebook/application';
2624
2725import { Poll } from '@lumino/polling' ;
2826
29- import { Menu , Widget } from '@lumino/widgets' ;
27+ import { Widget } from '@lumino/widgets' ;
3028
3129/**
3230 * The class for kernel status errors.
@@ -225,43 +223,6 @@ const kernelStatus: JupyterFrontEndPlugin<void> = {
225223 }
226224} ;
227225
228- /**
229- * A plugin to customize notebook related menu entries
230- * TODO: switch to settings define menus when fixed upstream: https://github.com/jupyterlab/jupyterlab/issues/11754
231- */
232- const menuPlugin : JupyterFrontEndPlugin < void > = {
233- id : '@jupyter-notebook/notebook-extension:menu-plugin' ,
234- autoStart : true ,
235- requires : [ IMainMenu , ITranslator ] ,
236- activate : (
237- app : JupyterFrontEnd ,
238- mainMenu : IMainMenu ,
239- translator : ITranslator
240- ) => {
241- const { commands } = app ;
242- const trans = translator . load ( 'notebook' ) ;
243-
244- const cellTypeSubmenu = new Menu ( { commands } ) ;
245- cellTypeSubmenu . title . label = trans . _p ( 'menu' , 'Cell Type' ) ;
246- [
247- 'notebook:change-cell-to-code' ,
248- 'notebook:change-cell-to-markdown' ,
249- 'notebook:change-cell-to-raw'
250- ] . forEach ( command => {
251- cellTypeSubmenu . addItem ( {
252- command
253- } ) ;
254- } ) ;
255-
256- mainMenu . runMenu . addItem ( { type : 'separator' , rank : 1000 } ) ;
257- mainMenu . runMenu . addItem ( {
258- type : 'submenu' ,
259- submenu : cellTypeSubmenu ,
260- rank : 1010
261- } ) ;
262- }
263- } ;
264-
265226/**
266227 * A plugin to enable scrolling for outputs by default.
267228 * Mimic the logic from the classic notebook, as found here:
@@ -358,7 +319,6 @@ const plugins: JupyterFrontEndPlugin<any>[] = [
358319 checkpoints ,
359320 kernelLogo ,
360321 kernelStatus ,
361- menuPlugin ,
362322 scrollOutput
363323] ;
364324
0 commit comments