From ae13911f3647ba78afc638b3b0a46433793dc41d Mon Sep 17 00:00:00 2001 From: Maksym Tsymbarov Date: Tue, 23 Sep 2025 18:01:45 +0300 Subject: [PATCH 1/4] added ability to access logout button when hide toolbar option is enabled on dashboard --- .../components/dashboard-page/dashboard-page.component.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts b/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts index a839e98c13..4a08ead0ec 100644 --- a/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts +++ b/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts @@ -203,7 +203,13 @@ export class DashboardPageComponent extends PageComponent implements IDashboardC } get hideToolbar(): boolean { - return ((this.hideToolbarValue || this.hideToolbarSetting()) && !this.isEdit) || (this.isEditingWidget || this.isAddingWidget); + const showToolbarInSpecialCase = this.forceFullscreen && this.hideToolbarSetting() && !this.isMobile; + + if (showToolbarInSpecialCase) { + return this.isEditingWidget || this.isAddingWidget; + } + + return ((this.hideToolbarValue || this.hideToolbarSetting()) && !this.isEdit) || (this.isEditingWidget || this.isAddingWidget) || !(this.isMobile || !this.forceFullscreen); } @Input() From afa368a856902f46c426cf3bf03fbe58f663c520 Mon Sep 17 00:00:00 2001 From: Maksym Tsymbarov Date: Thu, 25 Sep 2025 09:24:05 +0300 Subject: [PATCH 2/4] optimize logic --- .../dashboard-page/dashboard-page.component.ts | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts b/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts index 4a08ead0ec..566fa65d12 100644 --- a/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts +++ b/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts @@ -203,13 +203,7 @@ export class DashboardPageComponent extends PageComponent implements IDashboardC } get hideToolbar(): boolean { - const showToolbarInSpecialCase = this.forceFullscreen && this.hideToolbarSetting() && !this.isMobile; - - if (showToolbarInSpecialCase) { - return this.isEditingWidget || this.isAddingWidget; - } - - return ((this.hideToolbarValue || this.hideToolbarSetting()) && !this.isEdit) || (this.isEditingWidget || this.isAddingWidget) || !(this.isMobile || !this.forceFullscreen); + return ((this.hideToolbarValue || this.hideToolbarSetting()) && !this.isEdit) || (this.isEditingWidget || this.isAddingWidget); } @Input() @@ -655,9 +649,9 @@ export class DashboardPageComponent extends PageComponent implements IDashboardC } private hideToolbarSetting(): boolean { - if (this.dashboard.configuration.settings && - isDefined(this.dashboard.configuration.settings.hideToolbar)) { - return this.dashboard.configuration.settings.hideToolbar; + if (isDefined(this.dashboard.configuration?.settings?.hideToolbar)) { + const check = !this.forceFullscreen || this.isMobileApp; + return this.dashboard.configuration.settings.hideToolbar && check; } else { return false; } From b53c77467c196a083d9d0e3d122f86981c8b72bf Mon Sep 17 00:00:00 2001 From: Maksym Tsymbarov Date: Thu, 25 Sep 2025 15:59:14 +0300 Subject: [PATCH 3/4] change variable name to understandable --- .../components/dashboard-page/dashboard-page.component.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts b/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts index 566fa65d12..5983206560 100644 --- a/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts +++ b/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts @@ -650,8 +650,8 @@ export class DashboardPageComponent extends PageComponent implements IDashboardC private hideToolbarSetting(): boolean { if (isDefined(this.dashboard.configuration?.settings?.hideToolbar)) { - const check = !this.forceFullscreen || this.isMobileApp; - return this.dashboard.configuration.settings.hideToolbar && check; + const isForcedToDisplayToolbar = !this.forceFullscreen || this.isMobileApp; + return this.dashboard.configuration.settings.hideToolbar && isForcedToDisplayToolbar; } else { return false; } From 575cf960c972d1ecfab64b35016722be051c1e33 Mon Sep 17 00:00:00 2001 From: Maksym Tsymbarov Date: Mon, 6 Oct 2025 16:09:13 +0300 Subject: [PATCH 4/4] change naming --- .../components/dashboard-page/dashboard-page.component.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts b/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts index 5983206560..680c96df7b 100644 --- a/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts +++ b/ui-ngx/src/app/modules/home/components/dashboard-page/dashboard-page.component.ts @@ -650,8 +650,8 @@ export class DashboardPageComponent extends PageComponent implements IDashboardC private hideToolbarSetting(): boolean { if (isDefined(this.dashboard.configuration?.settings?.hideToolbar)) { - const isForcedToDisplayToolbar = !this.forceFullscreen || this.isMobileApp; - return this.dashboard.configuration.settings.hideToolbar && isForcedToDisplayToolbar; + const canApplyHideSetting = !this.forceFullscreen || this.isMobileApp; + return this.dashboard.configuration.settings.hideToolbar && canApplyHideSetting; } else { return false; }