From 5178f8784358791db9edee2994c5398199276a4b Mon Sep 17 00:00:00 2001 From: Andrewakiv Date: Mon, 16 Dec 2024 11:09:26 +0200 Subject: [PATCH] added a loader to the profiles statistics --- .../AdminPage/UserProfilesTable/ProfilesStatistics.jsx | 3 ++- .../UserProfilesTable/ProfilesStatistics.module.css | 5 +++++ FrontEnd/src/pages/CustomThemes/customAdminTheme.js | 7 +++++++ 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/FrontEnd/src/pages/AdminPage/UserProfilesTable/ProfilesStatistics.jsx b/FrontEnd/src/pages/AdminPage/UserProfilesTable/ProfilesStatistics.jsx index 569308b35..7354b456a 100644 --- a/FrontEnd/src/pages/AdminPage/UserProfilesTable/ProfilesStatistics.jsx +++ b/FrontEnd/src/pages/AdminPage/UserProfilesTable/ProfilesStatistics.jsx @@ -1,6 +1,7 @@ import axios from 'axios'; import useSWR from 'swr'; import { Descriptions } from 'antd'; +import Loader from '../../../components/Loader/Loader'; import css from './ProfilesStatistics.module.css'; async function fetcher(url) { @@ -40,7 +41,7 @@ function ProfilesStatistics() { return isLoading ? (
- Loading... +
) : error ? (
Не вдалося отримати статистику компаній
diff --git a/FrontEnd/src/pages/AdminPage/UserProfilesTable/ProfilesStatistics.module.css b/FrontEnd/src/pages/AdminPage/UserProfilesTable/ProfilesStatistics.module.css index c65cdf3f6..4e2dcbb6e 100644 --- a/FrontEnd/src/pages/AdminPage/UserProfilesTable/ProfilesStatistics.module.css +++ b/FrontEnd/src/pages/AdminPage/UserProfilesTable/ProfilesStatistics.module.css @@ -16,4 +16,9 @@ padding: 10px; border-radius: 4px; margin-top: 10px; +} + +.loader-container { + width: 200px; + height: 300px; } \ No newline at end of file diff --git a/FrontEnd/src/pages/CustomThemes/customAdminTheme.js b/FrontEnd/src/pages/CustomThemes/customAdminTheme.js index 1d661b3e9..abcee78b5 100644 --- a/FrontEnd/src/pages/CustomThemes/customAdminTheme.js +++ b/FrontEnd/src/pages/CustomThemes/customAdminTheme.js @@ -21,6 +21,13 @@ const customAdminTheme = { Table: { lineWidth: 3, colorPrimary: '#1f9a7c' + }, + Carousel: { + colorBgContainer: '#B4D27A', + dotActiveWidth: 32, + dotWidth: 32, + dotHeight: 6, + lineHeight: 1, } }, };