From 51dfba02f711c0bd8ce69cd8ca698131582e41ad Mon Sep 17 00:00:00 2001 From: Vladyslav_Prykhodko Date: Wed, 7 Aug 2024 10:22:34 +0300 Subject: [PATCH] UI: Add support manage dashboard layout --- .../dashboard-page.component.ts | 1 + ...ge-dashboard-layouts-dialog.component.html | 173 +++++++++++++++- ...ge-dashboard-layouts-dialog.component.scss | 34 ++++ ...nage-dashboard-layouts-dialog.component.ts | 184 ++++++++++++++++-- .../src/app/shared/models/dashboard.models.ts | 6 +- .../assets/locale/locale.constant-en_US.json | 1 + 6 files changed, 368 insertions(+), 31 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 3eb29babb2..ba8da29c17 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 @@ -483,6 +483,7 @@ export class DashboardPageComponent extends PageComponent implements IDashboardC if (!this.widgetEditMode && !this.readonly && this.dashboardUtils.isEmptyDashboard(this.dashboard)) { this.setEditMode(true, false); } + this.setEditMode(true, false); } private init(data: DashboardPageInitData) { 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 0007147712..bc1387e923 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 @@ -26,15 +26,171 @@
-
- - {{ 'layout.divider' | translate }} - +
+
dashboard.layout
+ + + + {{ layoutTypeTranslations.get(type) | translate }} + + +
+ + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + + {{ breakpoint.icon }} + + + + + Breakpoints + + + {{ breakpoint.name }} + + + + + Size + + + {{ breakpoint.descriptionSize }} + + + + + + +
+ + +
+
+ + + + + +
+
+
+ + +
+
+ +
+
+
Add breakpoint
+ + + + {{ breakpoint }} + + + +
+
+
Copy from
+ + + + {{ breakpoint }} + + + +
+
+ + +
+
+
+
+ [fxShow]="isDividerLayout"> {{ 'layout.percentage-width' | translate }} @@ -72,7 +228,7 @@ - {{ (layoutsFormGroup.value.right ? 'layout.left' : 'layout.main') | translate }} + {{ (isDividerLayout ? 'layout.left' : 'layout.main') | translate }}
@@ -93,7 +249,7 @@ required>
-
+
-
+
+