Jelajahi Sumber

Fix enabling of commands in last cell

Steven Silvester 7 tahun lalu
induk
melakukan
a43a2b34e5
1 mengubah file dengan 0 tambahan dan 2 penghapusan
  1. 0 2
      packages/notebook-extension/src/index.ts

+ 0 - 2
packages/notebook-extension/src/index.ts

@@ -708,8 +708,6 @@ function addCommands(app: JupyterLab, services: ServiceManager, tracker: Noteboo
     if (!isEnabled()) { return false; }
     const { notebook } = tracker.currentWidget;
     const index = notebook.activeCellIndex;
-    // Can't run above if we are at the top of a notebook.
-    if (index === notebook.widgets.length - 1) { return false; }
     // If there are selections that are not the active cell,
     // this command is confusing, so disable it.
     for (let i = 0; i < notebook.widgets.length; ++i) {