From a8406155648f5d9630b9b4ebaa5571aa12969e03 Mon Sep 17 00:00:00 2001 From: Dmitriymush Date: Fri, 19 Aug 2022 13:57:49 +0300 Subject: [PATCH] UI: layout preview improvements --- ...ge-dashboard-layouts-dialog.component.html | 66 ++++++++++--------- ...ge-dashboard-layouts-dialog.component.scss | 18 +++-- ...nage-dashboard-layouts-dialog.component.ts | 26 ++++++-- 3 files changed, 68 insertions(+), 42 deletions(-) diff --git a/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.html b/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.html index fa61d49b66..442c584402 100644 --- a/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.html +++ b/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.html @@ -56,7 +56,8 @@ matTooltipPosition="above" (click)="openLayoutSettings('main')" class="tb-layout-preview-element" - aria-label="Layout settings"> + aria-label="Layout settings" + [ngClass]="layoutButtonTextAndClass('main', false)"> settings
+ aria-label="Layout settings" + [ngClass]="layoutButtonTextAndClass('right', false)"> settings
-
-
- - - - -
- - -
+
+ + + + +
+ +
diff --git a/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.scss b/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.scss index 0c4a8da175..cf6a3813c4 100644 --- a/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.scss +++ b/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.scss @@ -37,11 +37,15 @@ button.tb-fixed-layout-button { background-color: transparent; - color: black; + color: #000000; cursor: pointer; + .mat-icon { + color: rgba(0, 0, 0, 0.38); + } + &:hover { - background-color: lightgrey; + background-color: #d3d3d3; } } @@ -64,7 +68,7 @@ width: 20px; height: 20px; line-height: 20px; - color: rgba(0, 0, 0, 0.38); + color: rgba(255, 255, 255, 0.76); &:hover { transform: rotate(180deg); @@ -94,7 +98,7 @@ color: white; input { - border: 1px solid lightslategray; + border: 1px solid #778899; background-color: transparent; color: white; border-radius: 4px; @@ -105,7 +109,7 @@ font-size: 14px; &:invalid { - outline: 2px solid red; + outline: 2px solid #b71c1c; border: 1px solid transparent; background-color: rgba(255, 5, 5, 0.2); } @@ -169,4 +173,8 @@ width: 160px; text-align: center; } + + .tb-layout-button-tooltip { + margin: 30px 40px -35px -50px; + } } diff --git a/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.ts b/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.ts index 51b1338f95..96d4bfa20c 100644 --- a/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.ts +++ b/ui-ngx/src/app/modules/home/components/dashboard-page/layout/manage-dashboard-layouts-dialog.component.ts @@ -14,7 +14,7 @@ /// limitations under the License. /// -import { Component, Inject, SkipSelf, ViewChild } from '@angular/core'; +import { Component, ElementRef, Inject, SkipSelf, ViewChild } from '@angular/core'; import { ErrorStateMatcher } from '@angular/material/core'; import { MAT_DIALOG_DATA, MatDialog, MatDialogRef } from '@angular/material/dialog'; import { Store } from '@ngrx/store'; @@ -77,7 +77,8 @@ export class ManageDashboardLayoutsDialogComponent extends DialogComponent { + elementToDisable.disabled = false; + }, 250); + } + if (this.layoutsFormGroup.get('type').value === LayoutWidthType.FIXED) { this.layoutsFormGroup.get('fixedLayout').setValue(layout); } @@ -321,14 +337,14 @@ export class ManageDashboardLayoutsDialogComponent extends DialogComponent