From 3edf1d7bfec045042110add163c62d9ef3e10b06 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20G=C3=BCnther?= Date: Mon, 7 May 2018 13:46:45 +0200 Subject: [PATCH] Hide loading indicator for embedded query configuration when hidden avoids the quick white flash for the loading promise [ci skip] --- .../wp-table/embedded/wp-embedded-table.component.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/frontend/app/components/wp-table/embedded/wp-embedded-table.component.ts b/frontend/app/components/wp-table/embedded/wp-embedded-table.component.ts index 7db6fb19f4..3f84581f80 100644 --- a/frontend/app/components/wp-table/embedded/wp-embedded-table.component.ts +++ b/frontend/app/components/wp-table/embedded/wp-embedded-table.component.ts @@ -157,9 +157,11 @@ export class WorkPackageEmbeddedTableComponent implements OnInit, AfterViewInit, } public set loadingIndicator(promise:Promise) { - this.loadingIndicatorService - .indicator(this.uniqueEmbeddedTableName) - .promise = promise; + if (this.configuration.tableVisible) { + this.loadingIndicatorService + .indicator(this.uniqueEmbeddedTableName) + .promise = promise; + } } private async loadQuery() { @@ -178,7 +180,6 @@ export class WorkPackageEmbeddedTableComponent implements OnInit, AfterViewInit, ) .then((query:QueryResource) => this.initializeStates(query, query.results)); - this.loadingIndicator = promise; return promise; }