Browse Source

resolve render linenumbers issue of notebook

Borys Palka 5 năm trước cách đây
mục cha
commit
8be69e7534
1 tập tin đã thay đổi với 3 bổ sung1 xóa
  1. 3 1
      src/handlers/notebook.ts

+ 3 - 1
src/handlers/notebook.ts

@@ -57,7 +57,9 @@ export class NotebookHandler implements IDisposable {
     notebookTracker: NotebookTracker,
     codeCell: CodeCell
   ) {
-    this.cellManager.activeCell = codeCell;
+    requestAnimationFrame(() => {
+      this.cellManager.activeCell = codeCell;
+    });
   }
 
   private notebookTracker: INotebookTracker;