[ACA-1548][ACA-1802] add actions to viewer toolbar via extensions (#637)

* [ACA-1548] rename viewer toolbar extension of More menu

* [ACA-1548][ACA-1802] add actions to the viewer toolbar via extensions
This commit is contained in:
Suzana Dirla
2018-09-17 15:14:27 +03:00
committed by Denys Vuika
parent 2f4048a859
commit e373064fd1
6 changed files with 52 additions and 7 deletions

View File

@@ -59,6 +59,7 @@ export abstract class PageComponent implements OnInit, OnDestroy {
sharedPreviewUrl$: Observable<string>;
actions: Array<ContentActionRef> = [];
viewerToolbarActions: Array<ContentActionRef> = [];
viewerToolbarMoreActions: Array<ContentActionRef> = [];
canUpdateNode = false;
canUpload = false;
@@ -89,6 +90,7 @@ export abstract class PageComponent implements OnInit, OnDestroy {
this.selection = selection;
this.actions = this.extensions.getAllowedToolbarActions();
this.viewerToolbarActions = this.extensions.getViewerToolbarActions();
this.viewerToolbarMoreActions = this.extensions.getViewerToolbarMoreActions();
this.canUpdateNode =
this.selection.count === 1 &&
this.content.canUpdateNode(selection.first);