@campxdev/campx-web-utils 0.4.5 → 0.4.7-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -3
- package/src/layout/AppLayout.tsx +18 -9
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@campxdev/campx-web-utils",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.7-alpha.1",
|
|
4
4
|
"main": "./export.ts",
|
|
5
5
|
"private": false,
|
|
6
6
|
"peerDependencies": {
|
|
7
|
-
"@campxdev/react-blueprint": ">=1.7.
|
|
7
|
+
"@campxdev/react-blueprint": ">=1.7.15-alpha.1",
|
|
8
8
|
"@emotion/react": ">=^11.13.3",
|
|
9
9
|
"@emotion/styled": ">=^11.13.0",
|
|
10
10
|
"@mui/icons-material": ">=6.1.5",
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"react-redux": "=>9.1.2"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@campxdev/react-blueprint": "1.7.
|
|
17
|
+
"@campxdev/react-blueprint": "1.7.11",
|
|
18
18
|
"@hookform/resolvers": "^3.9.0",
|
|
19
19
|
"@mui/x-date-pickers": "^7.22.1",
|
|
20
20
|
"axios": "^1.7.2",
|
package/src/layout/AppLayout.tsx
CHANGED
|
@@ -7,6 +7,7 @@ import { Suspense, useState } from 'react';
|
|
|
7
7
|
import { axios } from '../config/axios';
|
|
8
8
|
import { ErrorBoundary } from '../context/export';
|
|
9
9
|
import { Margin } from '@mui/icons-material';
|
|
10
|
+
import { ChangePasswordDialog } from '../components/ChangePassword';
|
|
10
11
|
|
|
11
12
|
interface Props {
|
|
12
13
|
children?: React.ReactNode;
|
|
@@ -16,16 +17,18 @@ interface Props {
|
|
|
16
17
|
userName?: string;
|
|
17
18
|
designation?: string;
|
|
18
19
|
clientName?: string;
|
|
20
|
+
institutionData?: any[];
|
|
19
21
|
}
|
|
20
22
|
|
|
21
23
|
export const AppLayout: React.FC<Props> = ({
|
|
22
24
|
children,
|
|
25
|
+
institutionData = [],
|
|
23
26
|
menu,
|
|
24
27
|
mainContainerSx,
|
|
25
28
|
handleLogout,
|
|
26
29
|
userName = '',
|
|
27
30
|
designation = '',
|
|
28
|
-
clientName = '
|
|
31
|
+
clientName = '',
|
|
29
32
|
}) => {
|
|
30
33
|
const [collapsed, setCollapsed] = useState(true);
|
|
31
34
|
const theme = useTheme();
|
|
@@ -60,13 +63,14 @@ export const AppLayout: React.FC<Props> = ({
|
|
|
60
63
|
}}
|
|
61
64
|
>
|
|
62
65
|
<AppHeader
|
|
63
|
-
|
|
66
|
+
clientName={clientName}
|
|
67
|
+
userFullName={userName}
|
|
68
|
+
designation={designation}
|
|
69
|
+
actions={[<ChangePasswordDialog />]}
|
|
64
70
|
collapsed={collapsed}
|
|
65
71
|
showActiveDevices={false}
|
|
66
72
|
onLogoutClick={handleLogout ?? logout}
|
|
67
|
-
|
|
68
|
-
userFullName={userName}
|
|
69
|
-
designation={designation}
|
|
73
|
+
institutionsData={institutionData}
|
|
70
74
|
{...(isSmallScreen && {
|
|
71
75
|
profileSx: { width: 32, height: 32, fontSize: '12px' },
|
|
72
76
|
})}
|
|
@@ -105,10 +109,6 @@ const OuletContainer = styled(Box)(({ theme }: { theme?: any }) => ({
|
|
|
105
109
|
overflowY: 'scroll',
|
|
106
110
|
width: '100%',
|
|
107
111
|
|
|
108
|
-
[theme.breakpoints.down('md')]: {
|
|
109
|
-
margin: '0px 12px 12px 12px',
|
|
110
|
-
},
|
|
111
|
-
|
|
112
112
|
'&::-webkit-scrollbar': {
|
|
113
113
|
width: '0.5em',
|
|
114
114
|
height: '0.2em',
|
|
@@ -122,4 +122,13 @@ const OuletContainer = styled(Box)(({ theme }: { theme?: any }) => ({
|
|
|
122
122
|
backgroundColor: theme.palette.primary.main,
|
|
123
123
|
},
|
|
124
124
|
},
|
|
125
|
+
|
|
126
|
+
[theme.breakpoints.down('md')]: {
|
|
127
|
+
margin: '0px 12px 12px 12px',
|
|
128
|
+
height: 'calc(100vh - 118px)',
|
|
129
|
+
|
|
130
|
+
'&::-webkit-scrollbar': {
|
|
131
|
+
display: 'none',
|
|
132
|
+
},
|
|
133
|
+
},
|
|
125
134
|
}));
|