cropper & imageservice

This commit is contained in:
2024-03-23 22:35:47 +01:00
parent d5210d3df4
commit a2c613c38f
11 changed files with 651 additions and 49 deletions

View File

@@ -12,15 +12,15 @@ export class LoadingService {
public isLoading$ = this.loading$.asObservable().pipe(
map((loading) => loading.length > 0),
debounceTime(200),
debounceTime(100),
distinctUntilChanged(),
shareReplay(1)
);
public startLoading(type: string,request:string): void {
public startLoading(type: string,request?:string): void {
if (!this.loading$.value.includes(type)) {
this.loading$.next(this.loading$.value.concat(type));
if (request.includes('uploadPropertyPicture')) {
if (type==='uploadImage' || request?.includes('uploadPropertyPicture')) {
this.loadingTextSubject.next("Please wait - we're processing your image...");
} else {
this.loadingTextSubject.next(null);