Hide ToggleMoreAction for inactive cell (#3235)

* Hide ToggleMoreAction for inactive cell

* Revert wrong merge

* Undo bad merge

* Enable markdown to hide ToggleMoreAction

* Resolve PR comments

* Fixed the name

* Change name

* Fix toggleMoreActions by passing in CellContext instead of just nb model

* Fixed the warning by removing notificationService from the caller
This commit is contained in:
Yurong He
2018-11-27 12:54:27 -08:00
committed by GitHub
parent cb72865dcc
commit b3eb809550
8 changed files with 101 additions and 32 deletions

View File

@@ -54,6 +54,7 @@ export class NotebookComponent extends AngularDisposable implements OnInit {
private _modelRegisteredDeferred = new Deferred<NotebookModel>();
private profile: IConnectionProfile;
private _trustedAction: TrustedAction;
private _activeCellId: string;
constructor(
@@ -85,6 +86,10 @@ export class NotebookComponent extends AngularDisposable implements OnInit {
return this._model;
}
public get activeCellId(): string {
return this._activeCellId;
}
public get modelRegistered(): Promise<NotebookModel> {
return this._modelRegisteredDeferred.promise;
}
@@ -106,6 +111,7 @@ export class NotebookComponent extends AngularDisposable implements OnInit {
this._activeCell = cell;
this._activeCell.active = true;
this._model.activeCell = this._activeCell;
this._activeCellId = cell.id;
this._changeRef.detectChanges();
}
}