From aa3a52b4b28a2bb7bf8665149c534b0dfad69ce0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adina=20=C8=9Aeudan?= Date: Tue, 29 Nov 2022 04:17:10 +0200 Subject: [PATCH] RED-5085: Done skeleton loading on dashboard --- apps/red-ui/src/app/app.module.ts | 2 +- .../dashboard-skeleton.component.html | 17 ------------ .../dashboard-skeleton.component.html | 27 +++++++++++++++++++ .../dashboard-skeleton.component.scss | 22 +++++++-------- .../dashboard-skeleton.component.ts | 0 .../src/app/modules/icons/icons.module.ts | 1 + .../icons/general/skeleton-template-stats.svg | 6 +++++ 7 files changed, 45 insertions(+), 30 deletions(-) delete mode 100644 apps/red-ui/src/app/components/dashboard-skeleton/dashboard-skeleton.component.html create mode 100644 apps/red-ui/src/app/components/skeleton/dashboard-skeleton/dashboard-skeleton.component.html rename apps/red-ui/src/app/components/{ => skeleton}/dashboard-skeleton/dashboard-skeleton.component.scss (82%) rename apps/red-ui/src/app/components/{ => skeleton}/dashboard-skeleton/dashboard-skeleton.component.ts (100%) create mode 100644 apps/red-ui/src/assets/icons/general/skeleton-template-stats.svg diff --git a/apps/red-ui/src/app/app.module.ts b/apps/red-ui/src/app/app.module.ts index 399d01523..040277809 100644 --- a/apps/red-ui/src/app/app.module.ts +++ b/apps/red-ui/src/app/app.module.ts @@ -28,7 +28,7 @@ import { ServiceWorkerModule } from '@angular/service-worker'; import { environment } from '@environments/environment'; import { AuthErrorComponent } from '@components/auth-error/auth-error.component'; import { NotificationsComponent } from '@components/notifications/notifications.component'; -import { DashboardSkeletonComponent } from '@components/dashboard-skeleton/dashboard-skeleton.component'; +import { DashboardSkeletonComponent } from '@components/skeleton/dashboard-skeleton/dashboard-skeleton.component'; import { DownloadsListScreenComponent } from '@components/downloads-list-screen/downloads-list-screen.component'; import { AppRoutingModule } from './app-routing.module'; import { SharedModule } from '@shared/shared.module'; diff --git a/apps/red-ui/src/app/components/dashboard-skeleton/dashboard-skeleton.component.html b/apps/red-ui/src/app/components/dashboard-skeleton/dashboard-skeleton.component.html deleted file mode 100644 index 2f89e274d..000000000 --- a/apps/red-ui/src/app/components/dashboard-skeleton/dashboard-skeleton.component.html +++ /dev/null @@ -1,17 +0,0 @@ - - -
- -
-
-
- -
-
-
-
-
-
-
-
-
diff --git a/apps/red-ui/src/app/components/skeleton/dashboard-skeleton/dashboard-skeleton.component.html b/apps/red-ui/src/app/components/skeleton/dashboard-skeleton/dashboard-skeleton.component.html new file mode 100644 index 000000000..b7fd59ae4 --- /dev/null +++ b/apps/red-ui/src/app/components/skeleton/dashboard-skeleton/dashboard-skeleton.component.html @@ -0,0 +1,27 @@ + + +
+ +
+
+
+ +
+
+
+
+
+
+
+ +
+ +
+
+
+
+
+
+
+
+
diff --git a/apps/red-ui/src/app/components/dashboard-skeleton/dashboard-skeleton.component.scss b/apps/red-ui/src/app/components/skeleton/dashboard-skeleton/dashboard-skeleton.component.scss similarity index 82% rename from apps/red-ui/src/app/components/dashboard-skeleton/dashboard-skeleton.component.scss rename to apps/red-ui/src/app/components/skeleton/dashboard-skeleton/dashboard-skeleton.component.scss index 50f65e0b7..25ba98779 100644 --- a/apps/red-ui/src/app/components/dashboard-skeleton/dashboard-skeleton.component.scss +++ b/apps/red-ui/src/app/components/skeleton/dashboard-skeleton/dashboard-skeleton.component.scss @@ -15,12 +15,14 @@ } } -.skeleton { +.skeleton-line { background-color: var(--iqser-grey-4); + border-radius: 12px; +} - &.line { - border-radius: 12px; - } +mat-icon { + width: unset; + height: unset; } .dialog { @@ -39,13 +41,9 @@ justify-content: center; border-left: 1px solid var(--iqser-separator); } - } -} - -.stats-subtitle { - flex-direction: column; - - > div { - margin-top: 10px; + + &.row { + flex-direction: row; + } } } diff --git a/apps/red-ui/src/app/components/dashboard-skeleton/dashboard-skeleton.component.ts b/apps/red-ui/src/app/components/skeleton/dashboard-skeleton/dashboard-skeleton.component.ts similarity index 100% rename from apps/red-ui/src/app/components/dashboard-skeleton/dashboard-skeleton.component.ts rename to apps/red-ui/src/app/components/skeleton/dashboard-skeleton/dashboard-skeleton.component.ts diff --git a/apps/red-ui/src/app/modules/icons/icons.module.ts b/apps/red-ui/src/app/modules/icons/icons.module.ts index 9b1eeb327..c62acabbc 100644 --- a/apps/red-ui/src/app/modules/icons/icons.module.ts +++ b/apps/red-ui/src/app/modules/icons/icons.module.ts @@ -68,6 +68,7 @@ export class IconsModule { 'rss', 'rule', 'secret', + 'skeleton-template-stats', 'status', 'status-info', 'template', diff --git a/apps/red-ui/src/assets/icons/general/skeleton-template-stats.svg b/apps/red-ui/src/assets/icons/general/skeleton-template-stats.svg new file mode 100644 index 000000000..7ef7ac10b --- /dev/null +++ b/apps/red-ui/src/assets/icons/general/skeleton-template-stats.svg @@ -0,0 +1,6 @@ + + + + + +