UNPKG

@c10t/nice-component-library

Version:

nice-component-library

21 lines (20 loc) 864 B
import { OnDestroy, PipeTransform } from '@angular/core'; import { HttpClient } from '@angular/common/http'; import { DomSanitizer, SafeUrl } from '@angular/platform-browser'; import { Observable } from 'rxjs'; import * as i0 from "@angular/core"; export declare class SecureImgPipe implements PipeTransform, OnDestroy { private http; private sanitizer; /** * Tracks blob URLs created by this pipe instance so they can be revoked * when replaced or when the pipe is destroyed. * Key: source image URL, Value: blob URL string */ private blobUrlCache; constructor(http: HttpClient, sanitizer: DomSanitizer); transform(url: string): Observable<SafeUrl>; ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<SecureImgPipe, never>; static ɵpipe: i0.ɵɵPipeDeclaration<SecureImgPipe, "secure", false>; }