UNPKG

@alfresco/adf-content-services

Version:
32 lines (31 loc) 1.92 kB
import { MatDialog, MatDialogConfig } from '@angular/material/dialog'; import { AlfrescoApiService } from '../services/alfresco-api.service'; import { VersionsApi } from '@alfresco/js-api'; import { NewVersionUploaderData, NewVersionUploaderDialogData } from './models'; import { Observable } from 'rxjs'; import { OverlayContainer } from '@angular/cdk/overlay'; import * as i0 from "@angular/core"; export declare class NewVersionUploaderService { private apiService; private dialog; private overlayContainer; private _versionsApi; get versionsApi(): VersionsApi; constructor(apiService: AlfrescoApiService, dialog: MatDialog, overlayContainer: OverlayContainer); /** * Open a dialog NewVersionUploaderDialogComponent to display: * - a side by side comparison between the current target node (type, name, icon) and the new file that should update it's version * - the new version's minor/major changes and the optional comment of a node and the ability to upload a new file version * - if data.showVersionsOnly is set to true, displays the version history of a node, with the ability to restore, delete and view version of the current node * * @param data data to pass to MatDialog * @param config allow to override default MatDialogConfig * @param selectorAutoFocusedOnClose element's selector which should be autofocused after closing modal * @returns an Observable represents the triggered dialog action or an error in case of an error condition */ openUploadNewVersionDialog(data: NewVersionUploaderDialogData, config?: MatDialogConfig, selectorAutoFocusedOnClose?: string): Observable<NewVersionUploaderData>; private composePanelClass; private static focusOnClose; static ɵfac: i0.ɵɵFactoryDeclaration<NewVersionUploaderService, never>; static ɵprov: i0.ɵɵInjectableDeclaration<NewVersionUploaderService>; }