mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-06-30 18:15:11 +00:00
[ACS-8823] Viewer - do not show non responsive dialog if blobFile was provided (#10247)
This commit is contained in:
parent
e9bfcbd3fb
commit
602460c574
@ -611,6 +611,14 @@ describe('ViewerComponent', () => {
|
||||
expect(dialogOpenSpy).toHaveBeenCalled();
|
||||
}));
|
||||
|
||||
it('should not show non responsive dialog if blobFile was provided', fakeAsync(() => {
|
||||
component.blobFile = new Blob(['mock content'], { type: 'text/plain' });
|
||||
fixture.detectChanges();
|
||||
tick(3000);
|
||||
fixture.detectChanges();
|
||||
expect(dialogOpenSpy).not.toHaveBeenCalled();
|
||||
}));
|
||||
|
||||
it('should show reminder non responsive dialog after initial dialog', fakeAsync(() => {
|
||||
dialogOpenSpy.and.returnValue({ afterClosed: () => of(DownloadPromptActions.WAIT) } as any);
|
||||
fixture.detectChanges();
|
||||
|
@ -456,7 +456,7 @@ export class ViewerComponent<T> implements OnDestroy, OnInit, OnChanges {
|
||||
}
|
||||
|
||||
private showOrClearDownloadPrompt() {
|
||||
if (!this.urlFile) {
|
||||
if (!this.urlFile && !this.blobFile) {
|
||||
this.showDownloadPrompt();
|
||||
} else {
|
||||
this.clearDownloadPromptTimeouts();
|
||||
|
Loading…
x
Reference in New Issue
Block a user