Nb/open book without reload (#6635)

* initial commit

* fix: added initialize method to fix the previous/next links rendering

* added checks

* open first markdown/ipynb in the book ans expand the view

* added launch book from command pallete, removed the pick folder and save option added launching the first notebook/markdown

* moved the open book command pallet action from mssql to notebooks

* open as untitled to true

* opening markdown files issue fix

* removed opening as untitled files

* open ipynb files as untitled and changes for previous&next links to work

* add books as seperate viewlet

* localize double quote issues and renamed treeCollapsibleState

* renames and added logic to conditionally show Preview command

* moved registerCommands from widget to extension contribution

* isEditorUntitled check

* async comment updates

* formatting issues.

* promisfying the async calls

* moved existsAsync to top
This commit is contained in:
Maddy
2019-08-23 11:19:35 -07:00
committed by GitHub
parent 1a39fdae24
commit 9274f223f0
9 changed files with 576 additions and 464 deletions

View File

@@ -22,6 +22,7 @@ export interface BookTreeItemFormat {
tableOfContents: any[];
page: any;
type: BookTreeItemType;
treeItemCollapsibleState: number;
}
export class BookTreeItem extends vscode.TreeItem {
@@ -32,10 +33,10 @@ export class BookTreeItem extends vscode.TreeItem {
public command: vscode.Command;
constructor(public book: BookTreeItemFormat, icons: any) {
super(book.title, vscode.TreeItemCollapsibleState.Collapsed);
super(book.title, book.treeItemCollapsibleState);
if (book.type === BookTreeItemType.Book) {
this.collapsibleState = vscode.TreeItemCollapsibleState.Collapsed;
this.collapsibleState = book.treeItemCollapsibleState;
this._sections = book.page;
} else {
this.setPageVariables();