@campxdev/shared 0.6.8 → 0.6.10
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 +1 -1
- package/src/components/Input/RadioGroup.tsx +12 -6
- package/src/components/Layout/Header/AppHeader.tsx +4 -1
- package/src/components/Layout/Header/applications.ts +13 -17
- package/src/components/Layout/Header/assets/index.ts +19 -10
- package/src/components/Layout/Header/assets/{campx_square_small.svg → newAssets/campx_square_small.svg} +0 -0
- package/src/components/Layout/Header/assets/newAssets/commutex.svg +14 -0
- package/src/components/Layout/Header/assets/newAssets/commutexSmall.svg +11 -0
- package/src/components/Layout/Header/assets/newAssets/enroll.svg +14 -0
- package/src/components/Layout/Header/assets/newAssets/enrollx.svg +14 -0
- package/src/components/Layout/Header/assets/{exams_small.svg → newAssets/exams_small.svg} +0 -0
- package/src/components/Layout/Header/assets/newAssets/examsx.svg +14 -0
- package/src/components/Layout/Header/assets/{hostel_small.svg → newAssets/hostel_small.svg} +0 -0
- package/src/components/Layout/Header/assets/newAssets/hostelx.svg +13 -0
- package/src/components/Layout/Header/assets/newAssets/libraryx.svg +12 -0
- package/src/components/Layout/Header/assets/{pay_small.svg → newAssets/pay_small.svg} +0 -0
- package/src/components/Layout/Header/assets/newAssets/payx.svg +19 -0
- package/src/components/Layout/Header/assets/{people_small.svg → newAssets/people_small.svg} +0 -0
- package/src/components/Layout/Header/assets/newAssets/peoplex.svg +12 -0
- package/src/components/Layout/Header/assets/newAssets/squarex.svg +12 -0
- package/src/components/SideNav.tsx +26 -8
- package/src/components/UploadButton/UploadButton.tsx +42 -41
- package/src/config/axiosXTenant.ts +1 -2
package/package.json
CHANGED
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
import { ReactNode } from 'react'
|
|
12
12
|
|
|
13
13
|
interface Props extends RadioGroupProps {
|
|
14
|
-
label: string
|
|
14
|
+
label: string | ReactNode
|
|
15
15
|
name?: string
|
|
16
16
|
control?: any
|
|
17
17
|
sx?: any
|
|
@@ -33,11 +33,17 @@ export default function RadioGroup(props: Props) {
|
|
|
33
33
|
return (
|
|
34
34
|
<Box>
|
|
35
35
|
<Box sx={{ display: 'flex' }}>
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
{
|
|
40
|
-
|
|
36
|
+
{typeof label === 'string' ? (
|
|
37
|
+
<>
|
|
38
|
+
<Typography variant="subtitle2">{label}</Typography>
|
|
39
|
+
{required && (
|
|
40
|
+
<Typography fontSize={14} component={'span'} color="error">
|
|
41
|
+
{' *'}
|
|
42
|
+
</Typography>
|
|
43
|
+
)}
|
|
44
|
+
</>
|
|
45
|
+
) : (
|
|
46
|
+
<>{label}</>
|
|
41
47
|
)}
|
|
42
48
|
</Box>
|
|
43
49
|
<MuiRadioGroup value={value} onChange={onChange} row={row} name={name}>
|
|
@@ -4,7 +4,8 @@ import { Link } from 'react-router-dom'
|
|
|
4
4
|
import { isDevelopment } from '../../../constants/isDevelopment'
|
|
5
5
|
import { applications } from './applications'
|
|
6
6
|
import AppsMenu from './AppsMenu'
|
|
7
|
-
import { collegex, enrollx, examx, payx, peoplex
|
|
7
|
+
import { collegex, commutex, enrollx, examx, hostelx, payx, peoplex,} from './assets'
|
|
8
|
+
|
|
8
9
|
import CogWheelMenu from './CogWheelMenu'
|
|
9
10
|
import FreshDeskHelpButton from './FreshDeskHelpButton'
|
|
10
11
|
import Notification from './Notification'
|
|
@@ -34,6 +35,8 @@ const imageMap = {
|
|
|
34
35
|
payments: payx,
|
|
35
36
|
peoplex: peoplex,
|
|
36
37
|
campx: collegex,
|
|
38
|
+
commutex:commutex,
|
|
39
|
+
hostelx:hostelx
|
|
37
40
|
}
|
|
38
41
|
|
|
39
42
|
interface AppHeaderProps {
|
|
@@ -5,6 +5,7 @@ import {
|
|
|
5
5
|
hostelSmall,
|
|
6
6
|
paySmall,
|
|
7
7
|
peopleSmall,
|
|
8
|
+
commuteSmall
|
|
8
9
|
} from './assets'
|
|
9
10
|
|
|
10
11
|
const origins = {
|
|
@@ -50,11 +51,18 @@ export const applications = [
|
|
|
50
51
|
description: 'Manage all Examinations in the Campus',
|
|
51
52
|
},
|
|
52
53
|
{
|
|
53
|
-
title: '
|
|
54
|
-
key: '
|
|
55
|
-
path: isDevelopment ? origins.
|
|
56
|
-
icon:
|
|
57
|
-
description: 'Manage
|
|
54
|
+
title: 'HostelX',
|
|
55
|
+
key: 'hostel',
|
|
56
|
+
path: isDevelopment ? origins.hostel.dev : origins.hostel.prod,
|
|
57
|
+
icon: hostelSmall,
|
|
58
|
+
description: 'Manage Hostels in the Campus',
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
title: 'CommuteX',
|
|
62
|
+
key: 'commute',
|
|
63
|
+
path: isDevelopment ? origins.commute.dev : origins.commute.prod,
|
|
64
|
+
icon: commuteSmall,
|
|
65
|
+
description: 'Manage Commute in the Campus',
|
|
58
66
|
},
|
|
59
67
|
...(isDevelopment
|
|
60
68
|
? [
|
|
@@ -64,18 +72,6 @@ export const applications = [
|
|
|
64
72
|
icon: peopleSmall,
|
|
65
73
|
description: 'Manage People in the Campus',
|
|
66
74
|
},
|
|
67
|
-
{
|
|
68
|
-
title: 'HostelX',
|
|
69
|
-
path: isDevelopment ? origins.hostel.dev : origins.hostel.prod,
|
|
70
|
-
icon: hostelSmall,
|
|
71
|
-
description: 'Manage Hostels in the Campus',
|
|
72
|
-
},
|
|
73
|
-
{
|
|
74
|
-
title: 'CommuteX',
|
|
75
|
-
path: isDevelopment ? origins.commute.dev : origins.commute.prod,
|
|
76
|
-
icon: hostelSmall,
|
|
77
|
-
description: 'Manage Commute in the Campus',
|
|
78
|
-
},
|
|
79
75
|
]
|
|
80
76
|
: []),
|
|
81
77
|
// {
|
|
@@ -1,23 +1,32 @@
|
|
|
1
|
-
import collegex from './
|
|
2
|
-
|
|
3
|
-
import examx from './
|
|
4
|
-
import payx from './
|
|
5
|
-
|
|
6
|
-
import campxSquareSmall from './campx_square_small.svg'
|
|
7
|
-
import examsSmall from './exams_small.svg'
|
|
8
|
-
import paySmall from './pay_small.svg'
|
|
9
|
-
import peopleSmall from './people_small.svg'
|
|
10
|
-
import hostelSmall from './hostel_small.svg'
|
|
1
|
+
import collegex from './newAssets/squarex.svg'
|
|
2
|
+
import enrollx from './newAssets/enrollx.svg'
|
|
3
|
+
import examx from './newAssets/examsx.svg'
|
|
4
|
+
import payx from './newAssets/payx.svg'
|
|
5
|
+
import peoplex from './newAssets/peoplex.svg'
|
|
6
|
+
import campxSquareSmall from './newAssets/campx_square_small.svg'
|
|
7
|
+
import examsSmall from './newAssets/exams_small.svg'
|
|
8
|
+
import paySmall from './newAssets/pay_small.svg'
|
|
9
|
+
import peopleSmall from './newAssets/people_small.svg'
|
|
10
|
+
import hostelSmall from './newAssets/hostel_small.svg'
|
|
11
|
+
import commuteSmall from './newAssets/commutexSmall.svg'
|
|
12
|
+
import commutex from './newAssets/commutex.svg'
|
|
13
|
+
import hostelx from './newAssets/hostelx.svg'
|
|
14
|
+
|
|
11
15
|
|
|
12
16
|
export {
|
|
13
17
|
collegex,
|
|
14
18
|
enrollx,
|
|
15
19
|
examx,
|
|
16
20
|
payx,
|
|
21
|
+
hostelx,
|
|
17
22
|
peoplex,
|
|
18
23
|
campxSquareSmall,
|
|
19
24
|
examsSmall,
|
|
20
25
|
paySmall,
|
|
21
26
|
peopleSmall,
|
|
22
27
|
hostelSmall,
|
|
28
|
+
commutex,
|
|
29
|
+
|
|
30
|
+
commuteSmall
|
|
31
|
+
|
|
23
32
|
}
|
|
File without changes
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="164.636" height="30" viewBox="0 0 164.636 30">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.5" x2="0.5" y2="1" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#6a2886"/>
|
|
5
|
+
<stop offset="1" stop-color="#8234a4"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4626" data-name="Group 4626" transform="translate(-154.491 -25)">
|
|
9
|
+
<text id="COMMUTEX" transform="translate(186.127 47.5)" font-size="22" font-family="Nexa-XBold, Nexa" font-weight="700"><tspan x="0" y="0">COMMUTEX</tspan></text>
|
|
10
|
+
<g id="Group_4542" data-name="Group 4542" transform="translate(1.791 -224.981)">
|
|
11
|
+
<path id="Union_49" data-name="Union 49" d="M14.451,30l-3.59-4.941L7.271,30H.073L0,29.947,10.177,15.939H.007V14.064H10.226L3.657,5.031v0L0,0V0H7.312L10.9,4.941,14.492,0h7.2l.073.053L11.584,14.064H21.757v1.875H11.54l6.566,9.03v0L21.763,30v0Z" transform="translate(152.7 249.981)" fill="url(#linear-gradient)"/>
|
|
12
|
+
</g>
|
|
13
|
+
</g>
|
|
14
|
+
</svg>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="232.146" height="320.001" viewBox="0 0 232.146 320.001">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.5" x2="0.5" y2="1" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#6a2886"/>
|
|
5
|
+
<stop offset="1" stop-color="#8234a4"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4542" data-name="Group 4542" transform="translate(-152.7 -249.981)">
|
|
9
|
+
<path id="Union_49" data-name="Union 49" d="M-15618.083,8500l-38.289-52.705-38.293,52.705h-76.783l-.779-.57,108.556-149.414h-108.484v-20h109.009l-70.071-96.354-.016.02-38.993-53.663.016-.023h77.982l38.293,52.7,38.288-52.7h76.784l.783.566-108.588,149.454h108.513v20h-108.977l70.039,96.317.016-.02,38.993,53.663-.016.023Z" transform="translate(15924.928 -7930.02)" fill="url(#linear-gradient)"/>
|
|
10
|
+
</g>
|
|
11
|
+
</svg>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="144.563" height="30" viewBox="0 0 144.563 30">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.5" x2="0.5" y2="1" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#007ab1"/>
|
|
5
|
+
<stop offset="1" stop-color="#149ecd"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4627" data-name="Group 4627" transform="translate(-142.219 -25)">
|
|
9
|
+
<g id="Group_4626" data-name="Group 4626" transform="translate(-6.346)">
|
|
10
|
+
<text id="ENROLLX" transform="translate(186.127 47.5)" font-size="22" font-family="Nexa-XBold, Nexa" font-weight="700"><tspan x="0" y="0">ENROLLX</tspan></text>
|
|
11
|
+
</g>
|
|
12
|
+
<path id="Union_6" data-name="Union 6" d="M-1754-2151h0v0l3.636-5v0l7.262-10h7.161l.073.053-10.86,14.947Zm13.437-6.012,6.53-8.988h7.161l.073.053-6.491,8.935Zm13.691-8.988Zm0,0h-7.161l-6.54-9h7.272l6.5,8.948Zm-16.228,0-7.262-10v0l-3.636-5v0h7.273l10.86,14.947-.073.053Zm5.443-15h0ZM-1737.657-2181Zm-7.275,0h0v0h7.273l0,0h-7.275Zm-9.068,0h0Z" transform="translate(1896.219 2206)" fill="url(#linear-gradient)"/>
|
|
13
|
+
</g>
|
|
14
|
+
</svg>
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="144.563" height="30" viewBox="0 0 144.563 30">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.5" x2="0.5" y2="1" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#007ab1"/>
|
|
5
|
+
<stop offset="1" stop-color="#149ecd"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4627" data-name="Group 4627" transform="translate(-142.219 -25)">
|
|
9
|
+
<g id="Group_4626" data-name="Group 4626" transform="translate(-6.346)">
|
|
10
|
+
<text id="ENROLLX" transform="translate(186.127 47.5)" font-size="22" font-family="Nexa-XBold, Nexa" font-weight="700"><tspan x="0" y="0">ENROLLX</tspan></text>
|
|
11
|
+
</g>
|
|
12
|
+
<path id="Union_6" data-name="Union 6" d="M-1754-2151h0v0l3.636-5v0l7.262-10h7.161l.073.053-10.86,14.947Zm13.437-6.012,6.53-8.988h7.161l.073.053-6.491,8.935Zm13.691-8.988Zm0,0h-7.161l-6.54-9h7.272l6.5,8.948Zm-16.228,0-7.262-10v0l-3.636-5v0h7.273l10.86,14.947-.073.053Zm5.443-15h0ZM-1737.657-2181Zm-7.275,0h0v0h7.273l0,0h-7.275Zm-9.068,0h0Z" transform="translate(1896.219 2206)" fill="url(#linear-gradient)"/>
|
|
13
|
+
</g>
|
|
14
|
+
</svg>
|
|
File without changes
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="121.121" height="30" viewBox="0 0 121.121 30">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.5" x2="0.5" y2="1" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#d86b00"/>
|
|
5
|
+
<stop offset="1" stop-color="#ed9035"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4626" data-name="Group 4626" transform="translate(-145.007 -25)">
|
|
9
|
+
<text id="EXAMX" transform="translate(184.127 47.5)" font-size="22" font-family="Nexa-XBold, Nexa" font-weight="700"><tspan x="0" y="0">EXAMX</tspan></text>
|
|
10
|
+
<g id="Group_4477" data-name="Group 4477" transform="translate(-197.288 -238.509)">
|
|
11
|
+
<path id="Subtraction_66" data-name="Subtraction 66" d="M29.12,30H21.847l0,0L0,30v0l3.636-5v0L10.9,15,3.638,5v0L0,0V0H29.12V0l-3.636,5V5L18.221,15l7.263,10v0l3.636,5,0,0ZM11.511,5.827h0l2.876,3.96V20.208l-2.876,3.96,6.094,0-2.871-3.956V9.787l2.871-3.956-6.094,0Z" transform="translate(342.295 263.509)" fill="url(#linear-gradient)"/>
|
|
12
|
+
</g>
|
|
13
|
+
</g>
|
|
14
|
+
</svg>
|
|
File without changes
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="464.103" height="320" viewBox="0 0 464.103 320">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.5" x2="0.5" y2="1" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#573dab"/>
|
|
5
|
+
<stop offset="1" stop-color="#7251dd"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4511" data-name="Group 4511" transform="translate(-270.758 -251.98)">
|
|
9
|
+
<path id="Subtraction_9" data-name="Subtraction 9" d="M79.763,164.484H.016L0,164.46l39.875-54.878.015.021L118.681,1.165,157.727,54.9l.015-.021.827,1.138L79.763,164.483ZM198.442,1.137h0L197.615,0h.431l.8.58-.4.555Z" transform="translate(384.15 407.496)" fill="url(#linear-gradient)"/>
|
|
10
|
+
<path id="Union_40" data-name="Union 40" d="M79.765,320H.017L0,319.974,39.878,265.1l.013.019,78.793-108.439.185.253,34.4-47.349.016.022,78.79-108.44.389.534.239-.333L350.791,163.9l-.077.058,73.5,101.155.016-.019L464.1,319.974l-.017.023H384.339L305.533,211.531l.031-.042L265.677,156.63l-.014.019,0,0v0l-.4-.554.02-.014-7.844-10.789.1.016-25.226-34.717-39.155,53.891h-.379l-35.728,49.138L79.765,320v0ZM152.94,1.392l-1-1.367L151.96,0h1.991L152.94,1.392v0Zm158.893-.256L311.008,0h.431l.8.583-.4.554Z" transform="translate(270.757 251.98)" fill="url(#linear-gradient)"/>
|
|
11
|
+
<path id="Subtraction_10" data-name="Subtraction 10" d="M198.046,164.484h-78.52L40.883,56.246,80.756,1.366,198.845,163.9l-.8.58ZM1,1.393h0L0,.024.015,0H2.006L1,1.392Z" transform="translate(422.701 407.495)" fill="url(#linear-gradient)"/>
|
|
12
|
+
</g>
|
|
13
|
+
</svg>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="145.621" height="30" viewBox="0 0 145.621 30">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.5" x2="0.5" y2="1" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#cba100"/>
|
|
5
|
+
<stop offset="1" stop-color="#f8d759"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4626" data-name="Group 4626" transform="translate(-154.507 -25)">
|
|
9
|
+
<text id="LIBRARYX" transform="translate(186.127 47.5)" font-size="22" font-family="Nexa-XBold, Nexa" font-weight="700"><tspan x="0" y="0">LIBRARYX</tspan></text>
|
|
10
|
+
<path id="Union_4" data-name="Union 4" d="M-3281.868-5857h0Zm-7.273,0-.073-.1-.073.1h-7.273v0l2.106-2.9,1.53-2.106v0l.073-.1-7.15-9.842.073-.053h7.16l3.553,4.89,3.553-4.89-3.553-4.89-3.553,4.89h-7.16l-.073-.053,7.15-9.842-.073-.1v0l-3.636-5v0h7.272l.073.1.073-.1h7.273v0l-3.636,5v0l-.073.1,7.15,9.842-.073.053.073.053-7.15,9.842.073.1v0l3.636,5v0Zm-7.42-30h0Z" transform="translate(3454.507 5912)" fill="url(#linear-gradient)"/>
|
|
11
|
+
</g>
|
|
12
|
+
</svg>
|
|
File without changes
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="93.064" height="30" viewBox="0 0 93.064 30">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.222" y1="1" x2="0.787" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#88b053"/>
|
|
5
|
+
<stop offset="1" stop-color="#50840b"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4626" data-name="Group 4626" transform="translate(-157.064 -25)">
|
|
9
|
+
<text id="PAYX" transform="translate(190.127 47.5)" font-size="22" font-family="Nexa-XBold, Nexa" font-weight="700"><tspan x="0" y="0">PAYX</tspan></text>
|
|
10
|
+
<g id="Group_4464" data-name="Group 4464" transform="translate(-1440.537 -756.55)">
|
|
11
|
+
<g id="Group_4461" data-name="Group 4461" transform="translate(1597.6 781.55)">
|
|
12
|
+
<g id="Group_4460" data-name="Group 4460" transform="translate(0 0)">
|
|
13
|
+
<path id="Subtraction_8" data-name="Subtraction 8" d="M7.5,15.42,18.668.054,18.593,0H11.232L3.766,10.275v0L.026,15.418v0H7.5Z" transform="translate(2.447 14.58)" fill="url(#linear-gradient)"/>
|
|
14
|
+
<path id="Subtraction_8-2" data-name="Subtraction 8" d="M11.19,0,.026,15.366.1,15.42H7.462L14.928,5.145v0L18.668,0V0H11.19Z" transform="translate(-0.026 0)" fill="url(#linear-gradient)"/>
|
|
15
|
+
</g>
|
|
16
|
+
</g>
|
|
17
|
+
</g>
|
|
18
|
+
</g>
|
|
19
|
+
</svg>
|
|
File without changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="155.964" height="30.002" viewBox="0 0 155.964 30.002">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.5" x2="0.5" y2="1" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#d0002b"/>
|
|
5
|
+
<stop offset="1" stop-color="#ea4a6b"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4626" data-name="Group 4626" transform="translate(-136.164 -24.999)">
|
|
9
|
+
<text id="PEOPLEX" transform="translate(186.127 47.5)" font-size="22" font-family="Nexa-XBold, Nexa" font-weight="700"><tspan x="0" y="0">PEOPLEX</tspan></text>
|
|
10
|
+
<path id="Union_42" data-name="Union 42" d="M-1723.591-7464l-4.718-6.494-.884,1.217,3.8,5.2-.1.072h-17.139l0,0,3.84-5.284-.875-1.206-4.717,6.494H-1754l0,0,4.8-6.611,0,0,9.494-13.066.047.064h0l5.664,7.765,5.7-7.765h0l.029-.04,14.226,19.582-.1.072Zm-8.653-26.22a3.782,3.782,0,0,1,3.78-3.782,3.784,3.784,0,0,1,3.782,3.782,3.784,3.784,0,0,1-3.782,3.782A3.782,3.782,0,0,1-1732.245-7490.219Zm-11.241,0a3.782,3.782,0,0,1,3.78-3.782,3.783,3.783,0,0,1,3.782,3.782,3.783,3.783,0,0,1-3.782,3.782A3.782,3.782,0,0,1-1743.486-7490.219Z" transform="translate(1890.163 7519)" fill="url(#linear-gradient)"/>
|
|
11
|
+
</g>
|
|
12
|
+
</svg>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="226.128" height="30" viewBox="0 0 226.128 30">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="linear-gradient" x1="0.5" x2="0.5" y2="1" gradientUnits="objectBoundingBox">
|
|
4
|
+
<stop offset="0" stop-color="#596e79"/>
|
|
5
|
+
<stop offset="1" stop-color="#7c909b"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
</defs>
|
|
8
|
+
<g id="Group_4626" data-name="Group 4626" transform="translate(-148 -25)">
|
|
9
|
+
<text id="CAMPX_SQUARE" data-name="CAMPX SQUARE" transform="translate(190.127 47.5)" font-size="22" font-family="Nexa-XBold, Nexa" font-weight="700"><tspan x="0" y="0">CAMPX SQUARE</tspan></text>
|
|
10
|
+
<path id="Subtraction_57" data-name="Subtraction 57" d="M-5680.2,8259.99h-11.3v-11.343h5.625v5.718h5.672v5.625Zm18.7,0h-11.3v-5.625h5.671v-5.718h5.625v11.343Zm0-18.749h-5.625v-5.626h-5.671v-5.625h11.3v11.251Zm-24.375,0h-5.625V8229.99h11.3v5.625h-5.672v5.626Z" transform="translate(5839.5 -8204.99)" fill="url(#linear-gradient)"/>
|
|
11
|
+
</g>
|
|
12
|
+
</svg>
|
|
@@ -74,14 +74,24 @@ const RenderMenuItem = ({ menuItem }) => {
|
|
|
74
74
|
return (
|
|
75
75
|
<>
|
|
76
76
|
{hasAccess ? (
|
|
77
|
-
|
|
78
|
-
<
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
77
|
+
<>
|
|
78
|
+
<StyledLink to={path}>
|
|
79
|
+
<ListItemButton
|
|
80
|
+
hasChildren={false}
|
|
81
|
+
label={title}
|
|
82
|
+
isActive={!!match}
|
|
83
|
+
icon={icon}
|
|
84
|
+
/>
|
|
85
|
+
</StyledLink>
|
|
86
|
+
{menuItem?.sectionEnd && (
|
|
87
|
+
<Box
|
|
88
|
+
sx={{
|
|
89
|
+
backgroundColor: '#1D1D1D',
|
|
90
|
+
height: '5px',
|
|
91
|
+
}}
|
|
92
|
+
></Box>
|
|
93
|
+
)}
|
|
94
|
+
</>
|
|
85
95
|
) : null}
|
|
86
96
|
</>
|
|
87
97
|
)
|
|
@@ -125,6 +135,14 @@ const DropDownMenu = ({ path, title, icon, menuItems }) => {
|
|
|
125
135
|
))}
|
|
126
136
|
</List>
|
|
127
137
|
</Collapse>
|
|
138
|
+
{menuItems?.sectionEnd && (
|
|
139
|
+
<Box
|
|
140
|
+
sx={{
|
|
141
|
+
backgroundColor: '#1D1D1D',
|
|
142
|
+
height: '5px',
|
|
143
|
+
}}
|
|
144
|
+
></Box>
|
|
145
|
+
)}
|
|
128
146
|
</Box>
|
|
129
147
|
)
|
|
130
148
|
}
|
|
@@ -36,7 +36,7 @@ export default function UploadButton({
|
|
|
36
36
|
const formData = new FormData()
|
|
37
37
|
formData.append('file', e.target.files[0])
|
|
38
38
|
setLoading(true)
|
|
39
|
-
loadingState &&
|
|
39
|
+
loadingState && loadingState(true)
|
|
40
40
|
axios
|
|
41
41
|
.post(uploadUrl, formData)
|
|
42
42
|
.then((res) => {
|
|
@@ -49,62 +49,63 @@ export default function UploadButton({
|
|
|
49
49
|
})
|
|
50
50
|
refetchFn()
|
|
51
51
|
setLoading(false)
|
|
52
|
-
loadingState &&
|
|
52
|
+
loadingState && loadingState(false)
|
|
53
53
|
if (onSuccess) onSuccess()
|
|
54
54
|
formRef?.current.reset()
|
|
55
55
|
})
|
|
56
56
|
.catch((err) => {
|
|
57
57
|
setLoading(false)
|
|
58
|
-
loadingState &&
|
|
58
|
+
loadingState && loadingState(false)
|
|
59
59
|
toast.error(
|
|
60
60
|
err?.response?.data?.message ?? 'Server Error While Uploading File',
|
|
61
61
|
)
|
|
62
|
-
formRef?.current.reset()
|
|
62
|
+
!styledUpload && formRef?.current.reset()
|
|
63
63
|
})
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
66
|
|
|
67
67
|
return (
|
|
68
68
|
<>
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
69
|
+
{styledUpload ? (
|
|
70
|
+
<>
|
|
71
|
+
<div
|
|
72
|
+
onClick={() => {
|
|
73
|
+
ref.current.click()
|
|
74
|
+
}}
|
|
75
|
+
>
|
|
76
|
+
{styledUpload}
|
|
77
|
+
</div>
|
|
78
|
+
<input
|
|
79
|
+
accept={getAccept(type)}
|
|
80
|
+
type="file"
|
|
81
|
+
hidden
|
|
82
|
+
ref={ref}
|
|
83
|
+
onChange={handleChange}
|
|
84
|
+
/>
|
|
85
85
|
</>
|
|
86
86
|
) : (
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
87
|
+
<>
|
|
88
|
+
<form ref={formRef}>
|
|
89
|
+
<input
|
|
90
|
+
ref={fileInputRef}
|
|
91
|
+
type="file"
|
|
92
|
+
style={{ display: 'none' }}
|
|
93
|
+
accept={getAccept(type)}
|
|
94
|
+
onChange={handleChange}
|
|
95
|
+
/>
|
|
96
|
+
<StyledButton
|
|
97
|
+
fullWidth
|
|
98
|
+
endIcon={loading ? <CircularProgress size={16} /> : null}
|
|
99
|
+
variant="outlined"
|
|
100
|
+
disabled={loading}
|
|
101
|
+
size={'large'}
|
|
102
|
+
onClick={() => fileInputRef.current.click()}
|
|
103
|
+
>
|
|
104
|
+
{getLabel(type)}
|
|
105
|
+
</StyledButton>
|
|
106
|
+
</form>
|
|
107
|
+
</>
|
|
108
|
+
)}
|
|
108
109
|
</>
|
|
109
110
|
)
|
|
110
111
|
}
|
|
@@ -2,7 +2,6 @@ import Axios from 'axios'
|
|
|
2
2
|
import Cookies from 'js-cookie'
|
|
3
3
|
import { NetworkStore } from '../components/ErrorBoundary/GlobalNetworkLoadingIndicator'
|
|
4
4
|
import { isDevelopment } from '../constants'
|
|
5
|
-
import { campxTenantKey } from '../contexts/Providers'
|
|
6
5
|
import { formatParams } from './axios'
|
|
7
6
|
|
|
8
7
|
const sessionKey = Cookies.get('campx_session_key')
|
|
@@ -13,7 +12,7 @@ const axiosTenant = Axios.create({
|
|
|
13
12
|
baseURL: process.env.REACT_APP_API_HOST,
|
|
14
13
|
withCredentials: true,
|
|
15
14
|
headers: {
|
|
16
|
-
'x-tenant-id': isDevelopment ? 'campx_dev' :
|
|
15
|
+
'x-tenant-id': isDevelopment ? 'campx_dev' : clientId,
|
|
17
16
|
...(isDevelopment &&
|
|
18
17
|
sessionKey && {
|
|
19
18
|
campx_session_key: sessionKey,
|