diff --git a/CHANGELOG.md b/CHANGELOG.md
index 7af2902..ef6ab92 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,6 @@
+## 0.10.1
+- В index.html добавлен config.js
+- Добавлены динамические стили для админок
## 0.10.0
- - Добавлена страница 'Модули'
## 0.9.0
diff --git a/index.html b/index.html
index 11c6825..e6b7b28 100644
--- a/index.html
+++ b/index.html
@@ -8,7 +8,9 @@
-
+
+
Панель администратора
+
diff --git a/package.json b/package.json
index a74eb1a..cfe918c 100644
--- a/package.json
+++ b/package.json
@@ -1,7 +1,7 @@
{
"name": "isp-admin-ui",
"private": true,
- "version": "0.10.0",
+ "version": "0.10.1",
"type": "module",
"scripts": {
"start": "vite",
diff --git a/public/config.js b/public/config.js
new file mode 100644
index 0000000..e69de29
diff --git a/src/components/Connections/connections.scss b/src/components/Connections/connections.scss
index f9484c8..67f6a98 100644
--- a/src/components/Connections/connections.scss
+++ b/src/components/Connections/connections.scss
@@ -7,7 +7,7 @@
&__wrap-table {
overflow-x: scroll;
- height: calc(100vh - 30px);
+ height: calc(100vh - 100px);
}
}
diff --git a/src/components/Layout/index.tsx b/src/components/Layout/index.tsx
index 41f8b12..b32fc0e 100644
--- a/src/components/Layout/index.tsx
+++ b/src/components/Layout/index.tsx
@@ -13,6 +13,7 @@ import { localStorageKeys } from '@constants/localStorageKeys.ts'
import DefaultUser from '@components/Icons/DefaultUser.tsx'
import {
MenuItemKeysType,
+ MenuItemLabelsType,
MenuItemType,
menuKeys
} from '@components/Layout/layout.type.ts'
@@ -23,13 +24,15 @@ import { useAppDispatch, useAppSelector } from '@hooks/redux.ts'
import useLogout from '@hooks/useLogout.tsx'
import useRole from '@hooks/useRole.tsx'
-import { fetchProfile } from '@stores/redusers/ActionCreators.ts'
+import { fetchProfile, fetchUI } from '@stores/redusers/ActionCreators.ts'
import { StateProfileStatus } from '@stores/redusers/ProfileSlice.ts'
import { routePaths } from '@routes/routePaths.ts'
import { PermissionKeysType } from '@type/roles.type.ts'
+import Header from 'src/widgets/Header'
+
import './layout.scss'
const { Content, Sider } = Layout
@@ -39,6 +42,7 @@ const LayoutComponent = () => {
const [selectedMenuKeys, setSelectedMenuKeys] = useState(
[]
)
+ const [title, setTitle] = useState('')
const [openKeys, setOpenKeys] = useState([])
const dispatch = useAppDispatch()
const {
@@ -143,6 +147,7 @@ const LayoutComponent = () => {
useEffect(() => {
if (userToken) {
dispatch(fetchProfile())
+ dispatch(fetchUI())
}
}, [])
@@ -152,6 +157,7 @@ const LayoutComponent = () => {
const menuItem = menuKeys[menuKey]
if (menuItem) {
+ setTitle(MenuItemLabelsType[menuItem.key])
setSelectedMenuKeys([menuItem.key])
setOpenKeys(menuItem.parent)
}
@@ -197,37 +203,40 @@ const LayoutComponent = () => {
}
return (
-
- {status === StateProfileStatus.pending ? (
-
- ) : (
- <>
- setCollapsed(value)}
- >
-
-
-
-
-
-
- >
- )}
-
+ collapsible
+ collapsed={collapsed}
+ onCollapse={(value) => setCollapsed(value)}
+ >
+