@campxdev/shared 1.8.14 → 1.8.15

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.
Files changed (267) hide show
  1. package/antd.customize.less +73 -0
  2. package/exports.ts +19 -0
  3. package/package.json +4 -20
  4. package/src/assets/fonts/avenir/Avenir-Book.ttf +0 -0
  5. package/src/assets/fonts/avenir/Avenir-Heavy.ttf +0 -0
  6. package/src/assets/fonts/avenir/Avenir-HeavyOblique.ttf +0 -0
  7. package/src/assets/fonts/avenir/Avenir-Medium.ttf +0 -0
  8. package/src/assets/fonts/avenir/Avenir-MediumOblique.ttf +0 -0
  9. package/src/assets/fonts/avenir/index.ts +13 -0
  10. package/src/assets/fonts/poppins/Poppins-Bold.ttf +0 -0
  11. package/src/assets/fonts/poppins/Poppins-Italic.ttf +0 -0
  12. package/src/assets/fonts/poppins/Poppins-Light.ttf +0 -0
  13. package/src/assets/fonts/poppins/Poppins-LightItalic.ttf +0 -0
  14. package/src/assets/fonts/poppins/Poppins-Medium.ttf +0 -0
  15. package/src/assets/fonts/poppins/Poppins-MediumItalic.ttf +0 -0
  16. package/src/assets/fonts/poppins/Poppins-Regular.ttf +0 -0
  17. package/src/assets/fonts/poppins/Poppins-SemiBold.ttf +0 -0
  18. package/src/assets/fonts/poppins/Poppins-SemiBoldItalic.ttf +0 -0
  19. package/src/assets/fonts/poppins/index.ts +18 -0
  20. package/src/assets/images/401.png +0 -0
  21. package/src/assets/images/403.png +0 -0
  22. package/src/assets/images/404.png +0 -0
  23. package/src/assets/images/404notfound.svg +1 -0
  24. package/src/assets/images/500.png +0 -0
  25. package/src/assets/images/avatar.png +0 -0
  26. package/src/assets/images/campx_logo__full_primary.png +0 -0
  27. package/src/assets/images/index.ts +17 -0
  28. package/src/assets/images/internalservererror.svg +1 -0
  29. package/src/assets/images/noInternet.svg +1 -0
  30. package/src/assets/images/nointernet.png +0 -0
  31. package/src/assets/images/notfound.png +0 -0
  32. package/src/assets/images/pagenotfound.svg +1 -0
  33. package/src/assets/images/permissiondenied.svg +1 -0
  34. package/src/assets/images/unauth.svg +92 -0
  35. package/src/components/ActionButton.tsx +20 -0
  36. package/src/components/Attachment.tsx +26 -0
  37. package/src/components/AutocompleteSearch/AutocompleteSearch.tsx +57 -0
  38. package/src/components/AutocompleteSearch/index.tsx +1 -0
  39. package/src/components/Breadcrumbs.tsx +72 -0
  40. package/src/components/Card.tsx +98 -0
  41. package/src/components/CardsGrid.tsx +28 -0
  42. package/src/components/ChangePassword.tsx +123 -0
  43. package/src/components/Chips.tsx +81 -0
  44. package/src/components/Detail.tsx +15 -0
  45. package/src/components/DetailsGrid.tsx +52 -0
  46. package/src/components/DividerHeading.tsx +41 -0
  47. package/src/components/DrawerWrapper/DialogWrapper.tsx +67 -0
  48. package/src/components/DrawerWrapper/DrawerTemplate.tsx +53 -0
  49. package/src/components/DrawerWrapper/DrawerWrapper.tsx +53 -0
  50. package/src/components/DropDownButton/AnchorElement.tsx +44 -0
  51. package/src/components/DropDownButton/DropDownButton.tsx +184 -0
  52. package/src/components/DropDownButton/DropdownMenuItem.tsx +110 -0
  53. package/src/components/DropDownButton/index.tsx +1 -0
  54. package/src/components/DropDownButton/styles.tsx +59 -0
  55. package/src/components/ErrorBoundary/ErrorBoundary.tsx +33 -0
  56. package/src/components/ErrorBoundary/ErrorFallback.tsx +241 -0
  57. package/src/components/ErrorBoundary/GlobalNetworkLoadingIndicator.tsx +13 -0
  58. package/src/components/ErrorBoundary/index.tsx +1 -0
  59. package/src/components/ErrorBox.tsx +42 -0
  60. package/src/components/ExcelToJsonInput/ExcelJsonUpload.tsx +50 -0
  61. package/src/components/ExcelToJsonInput/ExcelToJsonInput.tsx +57 -0
  62. package/src/components/ExcelToJsonInput/index.tsx +1 -0
  63. package/src/components/FilterComponents/FilterButton.tsx +56 -0
  64. package/src/components/FilterComponents/SearchBar.tsx +45 -0
  65. package/src/components/FloatingContainer.tsx +33 -0
  66. package/src/components/Form/Form.tsx +147 -0
  67. package/src/components/Form/RenderForm.tsx +189 -0
  68. package/src/components/FullScreenLoader.tsx +19 -0
  69. package/src/components/HookForm/AutoCompleteSearch.tsx +113 -0
  70. package/src/components/HookForm/DatePicker.tsx +40 -0
  71. package/src/components/HookForm/DateTimePicker.tsx +47 -0
  72. package/src/components/HookForm/FormLabel.tsx +14 -0
  73. package/src/components/HookForm/MultiCheckbox.tsx +69 -0
  74. package/src/components/HookForm/MultiSelect.tsx +53 -0
  75. package/src/components/HookForm/RadioGroup.tsx +47 -0
  76. package/src/components/HookForm/SingleCheckbox.tsx +34 -0
  77. package/src/components/HookForm/SingleSelect.tsx +46 -0
  78. package/src/components/HookForm/TextField.tsx +40 -0
  79. package/src/components/HookForm/TimePicker.tsx +40 -0
  80. package/src/components/HookForm/index.ts +23 -0
  81. package/src/components/IconButtons/IconButtons.tsx +137 -0
  82. package/src/components/IconButtons/Icons.tsx +268 -0
  83. package/src/components/IconButtons/assets/edit.svg +4 -0
  84. package/src/components/IconButtons/assets/eye.svg +6 -0
  85. package/src/components/IconButtons/assets/trash.svg +7 -0
  86. package/src/components/IconButtons/index.tsx +8 -0
  87. package/src/components/IconLabel.tsx +37 -0
  88. package/src/components/Image/Image.tsx +45 -0
  89. package/src/components/Image/broken-image.png +0 -0
  90. package/src/components/Image/index.tsx +1 -0
  91. package/src/components/ImageUpload.tsx +98 -0
  92. package/src/components/Input/AsyncSearchSelect/AsyncSearchSelect.tsx +216 -0
  93. package/src/components/Input/AsyncSearchSelect/index.tsx +1 -0
  94. package/src/components/Input/AsyncSearchSelect/styles.tsx +105 -0
  95. package/src/components/Input/AutoCompleteSearch.tsx +121 -0
  96. package/src/components/Input/DatePicker.tsx +87 -0
  97. package/src/components/Input/DateRangePicker.tsx +105 -0
  98. package/src/components/Input/DateTimePicker.tsx +84 -0
  99. package/src/components/Input/FormLabel.tsx +21 -0
  100. package/src/components/Input/MultiCheckbox.tsx +64 -0
  101. package/src/components/Input/MultiSelect.tsx +150 -0
  102. package/src/components/Input/RadioGroup.tsx +104 -0
  103. package/src/components/Input/SingleCheckbox.tsx +78 -0
  104. package/src/components/Input/SingleSelect.tsx +104 -0
  105. package/src/components/Input/TextField.tsx +46 -0
  106. package/src/components/Input/TimePicker.tsx +77 -0
  107. package/src/components/Input/index.ts +26 -0
  108. package/src/components/Input/types.ts +3 -0
  109. package/src/components/JsonPreview.tsx +7 -0
  110. package/src/components/LabelValue.tsx +21 -0
  111. package/src/components/Layout/ChangePassword.tsx +49 -0
  112. package/src/components/Layout/Header/AppHeader.tsx +112 -0
  113. package/src/components/Layout/Header/AppsMenu.tsx +105 -0
  114. package/src/components/Layout/Header/HeaderActions/CogWheelMenu.tsx +33 -0
  115. package/src/components/Layout/Header/HeaderActions/FreshDeskHelpButton.tsx +24 -0
  116. package/src/components/Layout/Header/HeaderActions/HeaderActions.tsx +18 -0
  117. package/src/components/Layout/Header/HeaderActions/UserBox.tsx +56 -0
  118. package/src/components/Layout/Header/Notification.tsx +13 -0
  119. package/src/components/Layout/Header/applications.ts +103 -0
  120. package/src/components/Layout/Header/assets/background.png +0 -0
  121. package/src/components/Layout/Header/assets/campx.png +0 -0
  122. package/src/components/Layout/Header/assets/campx_square_small.svg +9 -0
  123. package/src/components/Layout/Header/assets/commuteX.png +0 -0
  124. package/src/components/Layout/Header/assets/commutex.png +0 -0
  125. package/src/components/Layout/Header/assets/commutex.svg +14 -0
  126. package/src/components/Layout/Header/assets/commutexSmall.svg +11 -0
  127. package/src/components/Layout/Header/assets/contactBg.png +0 -0
  128. package/src/components/Layout/Header/assets/enroll.svg +14 -0
  129. package/src/components/Layout/Header/assets/enroll_logo.svg +9 -0
  130. package/src/components/Layout/Header/assets/enrollx.svg +14 -0
  131. package/src/components/Layout/Header/assets/entrollx.png +0 -0
  132. package/src/components/Layout/Header/assets/exams_small.svg +12 -0
  133. package/src/components/Layout/Header/assets/examsx.svg +14 -0
  134. package/src/components/Layout/Header/assets/examx.png +0 -0
  135. package/src/components/Layout/Header/assets/hostel_small.svg +13 -0
  136. package/src/components/Layout/Header/assets/hostelx.png +0 -0
  137. package/src/components/Layout/Header/assets/hostelx.svg +13 -0
  138. package/src/components/Layout/Header/assets/index.ts +35 -0
  139. package/src/components/Layout/Header/assets/libraryx.svg +12 -0
  140. package/src/components/Layout/Header/assets/libreryx.png +0 -0
  141. package/src/components/Layout/Header/assets/pay_small.svg +16 -0
  142. package/src/components/Layout/Header/assets/payx.png +0 -0
  143. package/src/components/Layout/Header/assets/payx.svg +19 -0
  144. package/src/components/Layout/Header/assets/people_small.svg +9 -0
  145. package/src/components/Layout/Header/assets/peoplex.svg +12 -0
  146. package/src/components/Layout/Header/assets/pepolex.png +0 -0
  147. package/src/components/Layout/Header/assets/squarex.svg +12 -0
  148. package/src/components/Layout/Header/icons.tsx +57 -0
  149. package/src/components/Layout/Header/index.tsx +1 -0
  150. package/src/components/Layout/Header/styles.tsx +133 -0
  151. package/src/components/Layout/Helmet.tsx +49 -0
  152. package/src/components/Layout/LayoutWrapper.tsx +28 -0
  153. package/src/components/Layout/SideMenuHeader.tsx +29 -0
  154. package/src/components/Layout/SideNav.tsx +168 -0
  155. package/src/components/Layout/Tickets/HelpWidget/HelpWidget.tsx +273 -0
  156. package/src/components/Layout/Tickets/HelpWidget/styles.tsx +94 -0
  157. package/src/components/Layout/Tickets/MyTickets.tsx +72 -0
  158. package/src/components/Layout/Tickets/TicketDetails.tsx +65 -0
  159. package/src/components/Layout/Tickets/TimeLine.tsx +64 -0
  160. package/src/components/Layout/Tickets/index.tsx +1 -0
  161. package/src/components/Layout/Tickets/services.ts +11 -0
  162. package/src/components/Layout/Tickets/styles.tsx +136 -0
  163. package/src/components/LinearProgress.tsx +19 -0
  164. package/src/components/ListItemButton.tsx +95 -0
  165. package/src/components/LoginForm.tsx +279 -0
  166. package/src/components/MediaRow/MediaRow.tsx +67 -0
  167. package/src/components/MediaRow/index.tsx +1 -0
  168. package/src/components/ModalButtons/DialogButton.tsx +126 -0
  169. package/src/components/ModalButtons/DrawerButton.tsx +115 -0
  170. package/src/components/ModalButtons/index.tsx +4 -0
  171. package/src/components/NoDataIllustration.tsx +32 -0
  172. package/src/components/PageContent.tsx +12 -0
  173. package/src/components/PageHeader.tsx +55 -0
  174. package/src/components/PageNotFound.tsx +26 -0
  175. package/src/components/PopupConfirm/ConfirmContextProvider.tsx +40 -0
  176. package/src/components/PopupConfirm/PopupConfirm.tsx +67 -0
  177. package/src/components/PopupConfirm/animation.gif +0 -0
  178. package/src/components/PopupConfirm/index.tsx +1 -0
  179. package/src/components/PopupConfirm/useConfirm.ts +47 -0
  180. package/src/components/ResetPassword.tsx +107 -0
  181. package/src/components/Row.tsx +24 -0
  182. package/src/components/Spinner.tsx +18 -0
  183. package/src/components/StepsHeader/StepsHeader.tsx +115 -0
  184. package/src/components/StepsHeader/index.tsx +1 -0
  185. package/src/components/StyledTableContainer.tsx +33 -0
  186. package/src/components/SwitchButton.tsx +41 -0
  187. package/src/components/Table.tsx +42 -0
  188. package/src/components/Tables/BasicTable/Table.tsx +198 -0
  189. package/src/components/Tables/BasicTable/TableFooter.tsx +86 -0
  190. package/src/components/Tables/BasicTable/index.tsx +1 -0
  191. package/src/components/Tables/ReactTable/BatchActionsHeader.tsx +58 -0
  192. package/src/components/Tables/ReactTable/ReactTable.tsx +295 -0
  193. package/src/components/Tables/ReactTable/RenderTableBody.tsx +49 -0
  194. package/src/components/Tables/ReactTable/index.tsx +1 -0
  195. package/src/components/Tables/ReactTable/react-table-config.d.ts +128 -0
  196. package/src/components/Tables/common/NoRecordsFound.tsx +27 -0
  197. package/src/components/Tables/common/TableStats.tsx +22 -0
  198. package/src/components/Tables/common/icons.tsx +50 -0
  199. package/src/components/Tables/common/no-data-illu.svg +1 -0
  200. package/src/components/Tables/common/styles.tsx +170 -0
  201. package/src/components/Tables/common/types.ts +57 -0
  202. package/src/components/Tabs/NavigationTabs.tsx +80 -0
  203. package/src/components/Tabs/Tabs.tsx +53 -0
  204. package/src/components/Tabs/TabsContainer.tsx +53 -0
  205. package/src/components/Tabs/index.tsx +1 -0
  206. package/src/components/Tabs/styles.tsx +55 -0
  207. package/src/components/ToastContainer/ToastContainer.tsx +57 -0
  208. package/src/components/ToastContainer/index.tsx +1 -0
  209. package/src/components/UploadButton/UploadButton.tsx +126 -0
  210. package/src/components/UploadButton/index.tsx +1 -0
  211. package/src/components/UploadButton/types.ts +19 -0
  212. package/src/components/UploadDocument.tsx +108 -0
  213. package/src/components/UploadFileDialog/AnimatedUploadFile.gif +0 -0
  214. package/src/components/UploadFileDialog/UploadFileDialog.tsx +238 -0
  215. package/src/components/UploadFileDialog/index.tsx +1 -0
  216. package/src/components/index.ts +106 -0
  217. package/src/config/axios.ts +73 -0
  218. package/src/config/axiosEvaluator.ts +53 -0
  219. package/src/config/axiosXTenant.ts +57 -0
  220. package/src/constants/UIConstants.ts +97 -0
  221. package/src/constants/formValidations.ts +6 -0
  222. package/src/constants/index.ts +5 -0
  223. package/src/constants/isDevelopment.ts +4 -0
  224. package/src/constants/permissions.ts +67 -0
  225. package/src/constants/validateMessages.ts +12 -0
  226. package/src/contexts/LoginFormProvider.tsx +44 -0
  227. package/src/contexts/Providers.tsx +50 -0
  228. package/src/contexts/PublicProviders.tsx +30 -0
  229. package/src/contexts/QueryClientProvider.tsx +22 -0
  230. package/src/hooks/index.ts +5 -0
  231. package/src/hooks/useAuth.ts +96 -0
  232. package/src/hooks/useExternalScript.ts +37 -0
  233. package/src/hooks/useFetch.ts +53 -0
  234. package/src/hooks/useFilters.ts +83 -0
  235. package/src/hooks/useRouter.ts +31 -0
  236. package/src/layouts/Components/DashBoardMenu.tsx +232 -0
  237. package/src/layouts/Components/icons/index.tsx +403 -0
  238. package/src/layouts/Components/styles.tsx +74 -0
  239. package/src/layouts/ComponentsLayout.tsx +3 -0
  240. package/src/permissions/PageWithPermission.tsx +18 -0
  241. package/src/permissions/PermissionDeniedPage.tsx +16 -0
  242. package/src/permissions/ValidateAccess.tsx +18 -0
  243. package/src/permissions/index.ts +2 -0
  244. package/src/react-app-env.d.ts +1 -0
  245. package/src/shared-state/AssetsStore.ts +15 -0
  246. package/src/shared-state/PermissionsStore.ts +392 -0
  247. package/src/shared-state/UserStore.ts +13 -0
  248. package/src/shared-state/index.ts +4 -0
  249. package/src/theme/App.less +3 -0
  250. package/src/theme/MuiThemeProvider.tsx +18 -0
  251. package/src/theme/customCssBaseline.ts +135 -0
  252. package/src/theme/index.css +28 -0
  253. package/src/theme/muiTheme.ts +595 -0
  254. package/src/theme/theme.d.ts +75 -0
  255. package/src/utils/adminAxios.ts +15 -0
  256. package/src/utils/alphabet.ts +23 -0
  257. package/src/utils/arrayPadEnd.ts +3 -0
  258. package/src/utils/formatCurrency.ts +9 -0
  259. package/src/utils/getUrlParams.ts +5 -0
  260. package/src/utils/index.ts +7 -0
  261. package/src/utils/logout.ts +25 -0
  262. package/src/utils/ordinalSuffixOf.ts +14 -0
  263. package/src/utils/romanize.ts +40 -0
  264. package/src/utils/withRouteWrapper.tsx +25 -0
  265. package/src/utils/withSuspense.tsx +6 -0
  266. package/styled-components.tsx +60 -0
  267. package/tsconfig.json +21 -0
@@ -0,0 +1,137 @@
1
+ import { Box, IconButton, IconButtonProps, styled } from '@mui/material'
2
+ import { ReactNode } from 'react'
3
+ import {
4
+ DeleteIcon,
5
+ DisabledDeleteIcon,
6
+ DisabledEditIcon,
7
+ EditIcon,
8
+ ViewIcon,
9
+ PrintIcon,
10
+ } from './Icons'
11
+
12
+ interface ButtonProps extends IconButtonProps {
13
+ disabledText?: string
14
+ actionType?: 'delete' | 'edit' | 'view' | 'print'
15
+ }
16
+
17
+ function Button({ ...props }: ButtonProps) {
18
+ const handleClick = (e) => {
19
+ e.stopPropagation()
20
+ if (!props.onClick) return
21
+ props.onClick(e)
22
+ }
23
+ return (
24
+ <StyledIconButton
25
+ {...props}
26
+ onClick={handleClick}
27
+ actionType={props.actionType ? props.actionType : 'view'}
28
+ >
29
+ {props.children}
30
+ </StyledIconButton>
31
+ )
32
+ }
33
+
34
+ function DisabledButton({
35
+ disabledText,
36
+ children,
37
+ }: {
38
+ disabledText?: string
39
+ children: ReactNode
40
+ }) {
41
+ return (
42
+ <Box
43
+ sx={{
44
+ maxHeight: '14px',
45
+ }}
46
+ title={disabledText ? disabledText : 'disabled'}
47
+ >
48
+ {children}
49
+ </Box>
50
+ )
51
+ }
52
+
53
+ export function ViewButton({ disabled, disabledText, ...props }: ButtonProps) {
54
+ if (disabled) {
55
+ return (
56
+ <DisabledButton {...props} disabledText={disabledText}>
57
+ <ViewIcon />
58
+ </DisabledButton>
59
+ )
60
+ }
61
+ return (
62
+ <Button {...props} actionType="view">
63
+ <ViewIcon />
64
+ </Button>
65
+ )
66
+ }
67
+
68
+ export function EditButton({ disabled, disabledText, ...props }: ButtonProps) {
69
+ if (disabled) {
70
+ return (
71
+ <DisabledButton
72
+ disabledText={disabledText ?? 'Default types can not be edited'}
73
+ >
74
+ <DisabledEditIcon />
75
+ </DisabledButton>
76
+ )
77
+ }
78
+ return (
79
+ <Button {...props} actionType="edit">
80
+ <EditIcon />
81
+ </Button>
82
+ )
83
+ }
84
+
85
+ export function PrintButton({ disabled, disabledText, ...props }: ButtonProps) {
86
+ if (disabled) {
87
+ return (
88
+ <DisabledButton
89
+ disabledText={disabledText ?? 'Default types can not be edited'}
90
+ >
91
+ <DisabledEditIcon />
92
+ </DisabledButton>
93
+ )
94
+ }
95
+ return (
96
+ <Button {...props} actionType="print">
97
+ <PrintIcon />
98
+ </Button>
99
+ )
100
+ }
101
+
102
+ export function DeleteButton({
103
+ disabled,
104
+ disabledText,
105
+ ...props
106
+ }: ButtonProps) {
107
+ if (disabled) {
108
+ return (
109
+ <DisabledButton
110
+ disabledText={disabledText ?? 'Default types can not be deleted'}
111
+ >
112
+ <DisabledDeleteIcon />
113
+ </DisabledButton>
114
+ )
115
+ }
116
+ return (
117
+ <Button {...props} actionType="delete">
118
+ <DeleteIcon />
119
+ </Button>
120
+ )
121
+ }
122
+
123
+ const StyledIconButton = styled(IconButton)<{
124
+ actionType: 'delete' | 'edit' | 'view' | 'print'
125
+ }>(({ theme, actionType }) => ({
126
+ padding: 0,
127
+ '&:hover': {
128
+ '& path': {
129
+ fill:
130
+ actionType === 'delete'
131
+ ? 'red'
132
+ : actionType === 'edit'
133
+ ? theme.palette.common.yellow
134
+ : theme.palette.error.main,
135
+ },
136
+ },
137
+ }))
@@ -0,0 +1,268 @@
1
+ import React from 'react'
2
+
3
+ export const ViewIcon = () => {
4
+ return (
5
+ <svg
6
+ xmlns="http://www.w3.org/2000/svg"
7
+ width="19.026"
8
+ height="14.775"
9
+ viewBox="0 0 19.026 14.775"
10
+ >
11
+ <g id="eye_9_" data-name="eye (9)" transform="translate(0.152 0.1)">
12
+ <path
13
+ id="Path_1389"
14
+ data-name="Path 1389"
15
+ d="M18.147,7.93a10.328,10.328,0,0,0-8.79-5.275A10.328,10.328,0,0,0,.568,7.93a3.827,3.827,0,0,0,0,4.026,10.328,10.328,0,0,0,8.79,5.275,10.328,10.328,0,0,0,8.79-5.275A3.827,3.827,0,0,0,18.147,7.93Zm-1.33,3.209a8.823,8.823,0,0,1-7.46,4.532A8.823,8.823,0,0,1,1.9,11.139a2.276,2.276,0,0,1,0-2.393,8.823,8.823,0,0,1,7.46-4.532,8.817,8.817,0,0,1,7.46,4.532A2.276,2.276,0,0,1,16.817,11.139Z"
16
+ transform="translate(0.004 -2.655)"
17
+ fill="#878787"
18
+ stroke="#fff"
19
+ strokeWidth="0.2"
20
+ />
21
+ <path
22
+ id="Path_1390"
23
+ data-name="Path 1390"
24
+ d="M10.9,7a3.9,3.9,0,1,0,3.9,3.9A3.9,3.9,0,0,0,10.9,7Zm0,6.239a2.34,2.34,0,1,1,2.34-2.34A2.34,2.34,0,0,1,10.9,13.239Z"
25
+ transform="translate(-1.538 -3.612)"
26
+ fill="#878787"
27
+ stroke="#fff"
28
+ strokeWidth="0.2"
29
+ />
30
+ </g>
31
+ </svg>
32
+ )
33
+ }
34
+
35
+ export const EditIcon = () => {
36
+ return (
37
+ <svg
38
+ id="edit_3_"
39
+ data-name="edit (3)"
40
+ xmlns="http://www.w3.org/2000/svg"
41
+ width="16.416"
42
+ height="16.416"
43
+ viewBox="0 0 16.416 16.416"
44
+ >
45
+ <path
46
+ id="Path_1387"
47
+ data-name="Path 1387"
48
+ d="M14.341.65,6,8.99a3.4,3.4,0,0,0-1,2.418v.919a.684.684,0,0,0,.684.684H6.6a3.4,3.4,0,0,0,2.418-1L17.36,3.669a2.138,2.138,0,0,0,0-3.019,2.185,2.185,0,0,0-3.019,0ZM16.393,2.7,8.053,11.042a2.066,2.066,0,0,1-1.451.6H6.368v-.235a2.066,2.066,0,0,1,.6-1.451l8.339-8.339a.785.785,0,0,1,1.085,0,.768.768,0,0,1,0,1.085Z"
49
+ transform="translate(-1.58 -0.014)"
50
+ fill="rgba(18,18,18,0.5)"
51
+ />
52
+ <path
53
+ id="Path_1388"
54
+ data-name="Path 1388"
55
+ d="M15.732,6.142a.684.684,0,0,0-.684.684V10.26H12.312a2.052,2.052,0,0,0-2.052,2.052v2.736H3.42A2.052,2.052,0,0,1,1.368,13V3.42A2.052,2.052,0,0,1,3.42,1.368H9.6A.684.684,0,0,0,9.6,0H3.42A3.424,3.424,0,0,0,0,3.42V13a3.424,3.424,0,0,0,3.42,3.42h7.759a3.4,3.4,0,0,0,2.419-1L15.414,13.6a3.4,3.4,0,0,0,1-2.418V6.826A.684.684,0,0,0,15.732,6.142Zm-3.1,8.306a2.035,2.035,0,0,1-1,.547V12.312a.684.684,0,0,1,.684-.684H15a2.063,2.063,0,0,1-.547,1Z"
56
+ fill="rgba(18,18,18,0.5)"
57
+ />
58
+ </svg>
59
+ )
60
+ }
61
+
62
+ export const DeleteIcon = () => {
63
+ return (
64
+ <svg
65
+ id="trash_4_"
66
+ data-name="trash (4)"
67
+ xmlns="http://www.w3.org/2000/svg"
68
+ width="15"
69
+ height="18"
70
+ viewBox="0 0 15 18"
71
+ >
72
+ <g
73
+ id="trash_4_2"
74
+ data-name="trash (4)"
75
+ transform="translate(-2)"
76
+ opacity="0.5"
77
+ >
78
+ <path
79
+ id="Path_1384"
80
+ data-name="Path 1384"
81
+ d="M16.25,3H13.925A3.757,3.757,0,0,0,10.25,0H8.75A3.757,3.757,0,0,0,5.075,3H2.75a.75.75,0,1,0,0,1.5H3.5v9.75A3.755,3.755,0,0,0,7.25,18h4.5a3.755,3.755,0,0,0,3.75-3.75V4.5h.75a.75.75,0,0,0,0-1.5ZM8.75,1.5h1.5A2.254,2.254,0,0,1,12.372,3H6.628A2.255,2.255,0,0,1,8.75,1.5ZM14,14.25a2.25,2.25,0,0,1-2.25,2.25H7.25A2.25,2.25,0,0,1,5,14.25V4.5h9Z"
82
+ fill="#121212"
83
+ />
84
+ <path
85
+ id="Path_1385"
86
+ data-name="Path 1385"
87
+ d="M9.75,16a.75.75,0,0,0,.75-.75v-4.5a.75.75,0,1,0-1.5,0v4.5A.75.75,0,0,0,9.75,16Z"
88
+ transform="translate(-1.75 -2.5)"
89
+ fill="#121212"
90
+ />
91
+ <path
92
+ id="Path_1386"
93
+ data-name="Path 1386"
94
+ d="M13.75,16a.75.75,0,0,0,.75-.75v-4.5a.75.75,0,1,0-1.5,0v4.5A.75.75,0,0,0,13.75,16Z"
95
+ transform="translate(-2.75 -2.5)"
96
+ fill="#121212"
97
+ />
98
+ </g>
99
+ </svg>
100
+ )
101
+ }
102
+
103
+ export const DisabledEditIcon = () => {
104
+ return (
105
+ <svg
106
+ id="Component_13_1"
107
+ data-name="Component 13 – 1"
108
+ xmlns="http://www.w3.org/2000/svg"
109
+ width="20"
110
+ height="20"
111
+ viewBox="0 0 20 20"
112
+ >
113
+ <g id="Group_77" data-name="Group 77" transform="translate(-1753 -331)">
114
+ <path
115
+ id="Path_1387"
116
+ data-name="Path 1387"
117
+ d="M14.341.65,6,8.99a3.4,3.4,0,0,0-1,2.418v.919a.684.684,0,0,0,.684.684H6.6a3.4,3.4,0,0,0,2.418-1L17.36,3.669a2.138,2.138,0,0,0,0-3.019,2.185,2.185,0,0,0-3.019,0ZM16.393,2.7,8.053,11.042a2.066,2.066,0,0,1-1.451.6H6.368v-.235a2.066,2.066,0,0,1,.6-1.451l8.339-8.339a.785.785,0,0,1,1.085,0,.768.768,0,0,1,0,1.085Z"
118
+ transform="translate(1751.42 330.986)"
119
+ fill="rgba(18,18,18,0.5)"
120
+ />
121
+ <path
122
+ id="Path_1388"
123
+ data-name="Path 1388"
124
+ d="M15.732,6.142a.684.684,0,0,0-.684.684V10.26H12.312a2.052,2.052,0,0,0-2.052,2.052v2.736H3.42A2.052,2.052,0,0,1,1.368,13V3.42A2.052,2.052,0,0,1,3.42,1.368H9.6A.684.684,0,0,0,9.6,0H3.42A3.424,3.424,0,0,0,0,3.42V13a3.424,3.424,0,0,0,3.42,3.42h7.759a3.4,3.4,0,0,0,2.419-1L15.414,13.6a3.4,3.4,0,0,0,1-2.418V6.826A.684.684,0,0,0,15.732,6.142Zm-3.1,8.306a2.035,2.035,0,0,1-1,.547V12.312a.684.684,0,0,1,.684-.684H15a2.063,2.063,0,0,1-.547,1Z"
125
+ transform="translate(1753 331)"
126
+ fill="rgba(18,18,18,0.5)"
127
+ />
128
+ </g>
129
+ <g id="Group_79" data-name="Group 79" transform="translate(-1753 -330)">
130
+ <circle
131
+ id="Ellipse_66"
132
+ data-name="Ellipse 66"
133
+ cx="5"
134
+ cy="5"
135
+ r="5"
136
+ transform="translate(1763 340)"
137
+ fill="#bc2c3d"
138
+ />
139
+ <path
140
+ id="cross-small_3_"
141
+ data-name="cross-small (3)"
142
+ d="M11.181,5.838h0a.445.445,0,0,0-.63,0L8.509,7.88,6.467,5.838a.445.445,0,0,0-.63,0h0a.445.445,0,0,0,0,.63L7.88,8.509,5.838,10.551a.445.445,0,0,0,0,.63h0a.445.445,0,0,0,.63,0L8.509,9.139l2.042,2.042a.445.445,0,0,0,.63,0h0a.445.445,0,0,0,0-.63L9.139,8.509l2.042-2.042A.445.445,0,0,0,11.181,5.838Z"
143
+ transform="translate(1759.491 336.491)"
144
+ fill="#fff"
145
+ />
146
+ </g>
147
+ </svg>
148
+ )
149
+ }
150
+
151
+ export const DisabledDeleteIcon = () => {
152
+ return (
153
+ <svg
154
+ id="Component_14_1"
155
+ data-name="Component 14 – 1"
156
+ xmlns="http://www.w3.org/2000/svg"
157
+ width="19.584"
158
+ height="21"
159
+ viewBox="0 0 19.584 21"
160
+ >
161
+ <g
162
+ id="Group_78"
163
+ data-name="Group 78"
164
+ transform="translate(-1789.416 -330)"
165
+ >
166
+ <g
167
+ id="trash_4_"
168
+ data-name="trash (4)"
169
+ transform="translate(1787.416 330)"
170
+ opacity="0.5"
171
+ >
172
+ <path
173
+ id="Path_1384"
174
+ data-name="Path 1384"
175
+ d="M16.25,3H13.925A3.757,3.757,0,0,0,10.25,0H8.75A3.757,3.757,0,0,0,5.075,3H2.75a.75.75,0,1,0,0,1.5H3.5v9.75A3.755,3.755,0,0,0,7.25,18h4.5a3.755,3.755,0,0,0,3.75-3.75V4.5h.75a.75.75,0,0,0,0-1.5ZM8.75,1.5h1.5A2.254,2.254,0,0,1,12.372,3H6.628A2.255,2.255,0,0,1,8.75,1.5ZM14,14.25a2.25,2.25,0,0,1-2.25,2.25H7.25A2.25,2.25,0,0,1,5,14.25V4.5h9Z"
176
+ fill="#121212"
177
+ />
178
+ <path
179
+ id="Path_1385"
180
+ data-name="Path 1385"
181
+ d="M9.75,16a.75.75,0,0,0,.75-.75v-4.5a.75.75,0,1,0-1.5,0v4.5A.75.75,0,0,0,9.75,16Z"
182
+ transform="translate(-1.75 -2.5)"
183
+ fill="#121212"
184
+ />
185
+ <path
186
+ id="Path_1386"
187
+ data-name="Path 1386"
188
+ d="M13.75,16a.75.75,0,0,0,.75-.75v-4.5a.75.75,0,1,0-1.5,0v4.5A.75.75,0,0,0,13.75,16Z"
189
+ transform="translate(-2.75 -2.5)"
190
+ fill="#121212"
191
+ />
192
+ </g>
193
+ </g>
194
+ <g
195
+ id="Group_80"
196
+ data-name="Group 80"
197
+ transform="translate(-1753.416 -329)"
198
+ >
199
+ <circle
200
+ id="Ellipse_66"
201
+ data-name="Ellipse 66"
202
+ cx="5"
203
+ cy="5"
204
+ r="5"
205
+ transform="translate(1763 340)"
206
+ fill="#bc2c3d"
207
+ />
208
+ <path
209
+ id="cross-small_3_"
210
+ data-name="cross-small (3)"
211
+ d="M11.181,5.838h0a.445.445,0,0,0-.63,0L8.509,7.88,6.467,5.838a.445.445,0,0,0-.63,0h0a.445.445,0,0,0,0,.63L7.88,8.509,5.838,10.551a.445.445,0,0,0,0,.63h0a.445.445,0,0,0,.63,0L8.509,9.139l2.042,2.042a.445.445,0,0,0,.63,0h0a.445.445,0,0,0,0-.63L9.139,8.509l2.042-2.042A.445.445,0,0,0,11.181,5.838Z"
212
+ transform="translate(1759.491 336.491)"
213
+ fill="#fff"
214
+ />
215
+ </g>
216
+ </svg>
217
+ )
218
+ }
219
+
220
+ export const PrintIcon = () => {
221
+ return (
222
+ <svg
223
+ id="print_1_"
224
+ data-name="print (1)"
225
+ xmlns="http://www.w3.org/2000/svg"
226
+ width="16"
227
+ height="16"
228
+ viewBox="0 0 16 16"
229
+ >
230
+ <g id="print_1_2" data-name="print (1)" opacity="0.5">
231
+ <path
232
+ id="Path_1768"
233
+ data-name="Path 1768"
234
+ d="M12.667,4V2.667A2.667,2.667,0,0,0,10,0H6A2.667,2.667,0,0,0,3.333,2.667V4A3.337,3.337,0,0,0,0,7.333v3.333A3.337,3.337,0,0,0,3.333,14a2,2,0,0,0,2,2h5.333a2,2,0,0,0,2-2A3.337,3.337,0,0,0,16,10.667V7.333A3.337,3.337,0,0,0,12.667,4Zm-8-1.333A1.333,1.333,0,0,1,6,1.333h4a1.333,1.333,0,0,1,1.333,1.333V4H4.667ZM11.333,14a.667.667,0,0,1-.667.667H5.333A.667.667,0,0,1,4.667,14V11.333a.667.667,0,0,1,.667-.667h5.333a.667.667,0,0,1,.667.667Zm3.333-3.333a2,2,0,0,1-2,2V11.333a2,2,0,0,0-2-2H5.333a2,2,0,0,0-2,2v1.333a2,2,0,0,1-2-2V7.333a2,2,0,0,1,2-2h9.333a2,2,0,0,1,2,2Z"
235
+ fill="#121212"
236
+ />
237
+ <path
238
+ id="Path_1769"
239
+ data-name="Path 1769"
240
+ d="M17,10H15.667a.667.667,0,1,0,0,1.333H17A.667.667,0,1,0,17,10Z"
241
+ transform="translate(-5 -3.333)"
242
+ />
243
+ </g>
244
+ </svg>
245
+ )
246
+ }
247
+
248
+ export const DateRangeIcon = () => {
249
+ return (
250
+ <svg
251
+ xmlns="http://www.w3.org/2000/svg"
252
+ width="20"
253
+ height="15"
254
+ viewBox="0 0 20 15"
255
+ >
256
+ <g id="transfer" transform="translate(0 -51.198)" opacity="0.501">
257
+ <g id="Group_807" data-name="Group 807" transform="translate(0 51.198)">
258
+ <path
259
+ id="Path_1400"
260
+ data-name="Path 1400"
261
+ d="M18.452,56.055,13.79,51.393a.666.666,0,0,0-1.137.471v2H7.991a.666.666,0,1,0,0,1.332h5.328a.666.666,0,0,0,.666-.666V53.472l3.054,3.054L13.985,59.58V58.524a.666.666,0,0,0-.666-.666H5.993v-2a.666.666,0,0,0-1.137-.471L.195,60.051a.666.666,0,0,0,0,.942l4.662,4.662a.666.666,0,0,0,.471.2.658.658,0,0,0,.255-.051.666.666,0,0,0,.411-.615v-2h4.662a.666.666,0,0,0,0-1.332H5.327a.666.666,0,0,0-.666.666v1.056L1.607,60.522l3.054-3.054v1.056a.666.666,0,0,0,.666.666h7.326v2a.666.666,0,0,0,1.137.471L18.452,57A.666.666,0,0,0,18.452,56.055Z"
262
+ transform="translate(0 -51.198)"
263
+ />
264
+ </g>
265
+ </g>
266
+ </svg>
267
+ )
268
+ }
@@ -0,0 +1,4 @@
1
+ <svg id="edit_3_" data-name="edit (3)" xmlns="http://www.w3.org/2000/svg" width="16.416" height="16.416" viewBox="0 0 16.416 16.416">
2
+ <path id="Path_1387" data-name="Path 1387" d="M14.341.65,6,8.99a3.4,3.4,0,0,0-1,2.418v.919a.684.684,0,0,0,.684.684H6.6a3.4,3.4,0,0,0,2.418-1L17.36,3.669a2.138,2.138,0,0,0,0-3.019,2.185,2.185,0,0,0-3.019,0ZM16.393,2.7,8.053,11.042a2.066,2.066,0,0,1-1.451.6H6.368v-.235a2.066,2.066,0,0,1,.6-1.451l8.339-8.339a.785.785,0,0,1,1.085,0,.768.768,0,0,1,0,1.085Z" transform="translate(-1.58 -0.014)" fill="rgba(18,18,18,0.5)"/>
3
+ <path id="Path_1388" data-name="Path 1388" d="M15.732,6.142a.684.684,0,0,0-.684.684V10.26H12.312a2.052,2.052,0,0,0-2.052,2.052v2.736H3.42A2.052,2.052,0,0,1,1.368,13V3.42A2.052,2.052,0,0,1,3.42,1.368H9.6A.684.684,0,0,0,9.6,0H3.42A3.424,3.424,0,0,0,0,3.42V13a3.424,3.424,0,0,0,3.42,3.42h7.759a3.4,3.4,0,0,0,2.419-1L15.414,13.6a3.4,3.4,0,0,0,1-2.418V6.826A.684.684,0,0,0,15.732,6.142Zm-3.1,8.306a2.035,2.035,0,0,1-1,.547V12.312a.684.684,0,0,1,.684-.684H15a2.063,2.063,0,0,1-.547,1Z" fill="rgba(18,18,18,0.5)"/>
4
+ </svg>
@@ -0,0 +1,6 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="19.026" height="14.775" viewBox="0 0 19.026 14.775">
2
+ <g id="eye_9_" data-name="eye (9)" transform="translate(0.152 0.1)">
3
+ <path id="Path_1389" data-name="Path 1389" d="M18.147,7.93a10.328,10.328,0,0,0-8.79-5.275A10.328,10.328,0,0,0,.568,7.93a3.827,3.827,0,0,0,0,4.026,10.328,10.328,0,0,0,8.79,5.275,10.328,10.328,0,0,0,8.79-5.275A3.827,3.827,0,0,0,18.147,7.93Zm-1.33,3.209a8.823,8.823,0,0,1-7.46,4.532A8.823,8.823,0,0,1,1.9,11.139a2.276,2.276,0,0,1,0-2.393,8.823,8.823,0,0,1,7.46-4.532,8.817,8.817,0,0,1,7.46,4.532A2.276,2.276,0,0,1,16.817,11.139Z" transform="translate(0.004 -2.655)" fill="#878787" stroke="#fff" strokeWidth="0.2"/>
4
+ <path id="Path_1390" data-name="Path 1390" d="M10.9,7a3.9,3.9,0,1,0,3.9,3.9A3.9,3.9,0,0,0,10.9,7Zm0,6.239a2.34,2.34,0,1,1,2.34-2.34A2.34,2.34,0,0,1,10.9,13.239Z" transform="translate(-1.538 -3.612)" fill="#878787" stroke="#fff" strokeWidth="0.2"/>
5
+ </g>
6
+ </svg>
@@ -0,0 +1,7 @@
1
+ <svg id="trash_4_" data-name="trash (4)" xmlns="http://www.w3.org/2000/svg" width="15" height="18" viewBox="0 0 15 18">
2
+ <g id="trash_4_2" data-name="trash (4)" transform="translate(-2)" opacity="0.5">
3
+ <path id="Path_1384" data-name="Path 1384" d="M16.25,3H13.925A3.757,3.757,0,0,0,10.25,0H8.75A3.757,3.757,0,0,0,5.075,3H2.75a.75.75,0,1,0,0,1.5H3.5v9.75A3.755,3.755,0,0,0,7.25,18h4.5a3.755,3.755,0,0,0,3.75-3.75V4.5h.75a.75.75,0,0,0,0-1.5ZM8.75,1.5h1.5A2.254,2.254,0,0,1,12.372,3H6.628A2.255,2.255,0,0,1,8.75,1.5ZM14,14.25a2.25,2.25,0,0,1-2.25,2.25H7.25A2.25,2.25,0,0,1,5,14.25V4.5h9Z" fill="#121212"/>
4
+ <path id="Path_1385" data-name="Path 1385" d="M9.75,16a.75.75,0,0,0,.75-.75v-4.5a.75.75,0,1,0-1.5,0v4.5A.75.75,0,0,0,9.75,16Z" transform="translate(-1.75 -2.5)" fill="#121212"/>
5
+ <path id="Path_1386" data-name="Path 1386" d="M13.75,16a.75.75,0,0,0,.75-.75v-4.5a.75.75,0,1,0-1.5,0v4.5A.75.75,0,0,0,13.75,16Z" transform="translate(-2.75 -2.5)" fill="#121212"/>
6
+ </g>
7
+ </svg>
@@ -0,0 +1,8 @@
1
+ export {
2
+ ViewButton,
3
+ DeleteButton,
4
+ EditButton,
5
+ PrintButton,
6
+ } from './IconButtons'
7
+
8
+ export { DateRangeIcon } from './Icons'
@@ -0,0 +1,37 @@
1
+ import { Box, styled, Typography } from '@mui/material'
2
+ import { ReactNode } from 'react'
3
+
4
+ const StyledStack = styled(Box)(({ theme }) => ({
5
+ display: 'flex',
6
+ alignItems: 'center',
7
+ gap: '8px',
8
+ '& .MuiSvgIcon-root': {
9
+ fontSize: '1rem',
10
+ color: theme.palette.text.secondary,
11
+ },
12
+ }))
13
+
14
+ export default function IconLabel({
15
+ label,
16
+ icon,
17
+ onClick,
18
+ }: {
19
+ label: string
20
+ icon: ReactNode
21
+ onClick?: () => void
22
+ }) {
23
+ return (
24
+ <StyledStack
25
+ onClick={onClick ?? onClick}
26
+ sx={{
27
+ ...(onClick && {
28
+ cursor: 'pointer',
29
+ '&:hover': { borderBottom: '1px solid gray' },
30
+ }),
31
+ }}
32
+ >
33
+ {icon}
34
+ <Typography variant="subtitle2">{label}</Typography>
35
+ </StyledStack>
36
+ )
37
+ }
@@ -0,0 +1,45 @@
1
+ import { Box } from '@mui/material'
2
+ const brokenImage = require('./broken-image.png')
3
+
4
+ interface ImageProps {
5
+ src: string
6
+ alt: string
7
+ height: string | number
8
+ width: string | number
9
+ fit?: 'cover' | 'contain' | 'fill'
10
+ radius?: string | number
11
+ defaultImage?: any
12
+ }
13
+
14
+ export default function Image({
15
+ src,
16
+ alt,
17
+ height,
18
+ width,
19
+ fit = 'contain',
20
+ radius = '10px',
21
+ defaultImage = null,
22
+ }: ImageProps) {
23
+ return (
24
+ <Box
25
+ sx={{
26
+ height: height,
27
+ width: width,
28
+ '& > img': {
29
+ borderRadius: radius,
30
+ width: '100%',
31
+ height: '100%',
32
+ objectFit: fit,
33
+ },
34
+ }}
35
+ >
36
+ <img
37
+ src={src || defaultImage}
38
+ alt={alt}
39
+ onError={(e: any) => {
40
+ e.target.src = defaultImage ? defaultImage : brokenImage
41
+ }}
42
+ />
43
+ </Box>
44
+ )
45
+ }
@@ -0,0 +1 @@
1
+ export { default } from './Image'
@@ -0,0 +1,98 @@
1
+ import { InsertPhotoOutlined } from '@mui/icons-material'
2
+ import { Box, CircularProgress, styled, Typography } from '@mui/material'
3
+ import { ReactNode, useRef, useState } from 'react'
4
+ import { toast } from 'react-toastify'
5
+ import axios, { axiosErrorToast } from '../config/axios'
6
+
7
+ interface ImageUploadProps {
8
+ onFileUploaded: (v) => void
9
+ postUrl: string
10
+ StyledUpload?: ReactNode
11
+ loadingState?: (v) => void
12
+ }
13
+ export default function ImageUpload({
14
+ onFileUploaded,
15
+ postUrl,
16
+ StyledUpload,
17
+ loadingState,
18
+ }: ImageUploadProps) {
19
+ const [loading, setLoading] = useState(false)
20
+ const ref = useRef<HTMLInputElement>(null)
21
+
22
+ const handleChange = (e) => {
23
+ if (e.target.files[0]) {
24
+ const formData = new FormData()
25
+ formData.append('file', e.target.files[0])
26
+ setLoading(true)
27
+ loadingState && setLoading(true)
28
+ axios
29
+ .post(postUrl, formData)
30
+ .then((res) => {
31
+ onFileUploaded({
32
+ url: res.data.url,
33
+ key: res.data.key,
34
+ fileName: res.data?.mediaObject?.originalFileName ?? '',
35
+ id: res.data?.mediaObject?.id ?? '',
36
+ })
37
+ setLoading(false)
38
+ loadingState && setLoading(false)
39
+ })
40
+ .catch((err) => {
41
+ setLoading(false)
42
+ loadingState && setLoading(false)
43
+ axiosErrorToast(err)
44
+ })
45
+ }
46
+ }
47
+
48
+ return (
49
+ <>
50
+ {StyledUpload ? (
51
+ <div
52
+ onClick={() => {
53
+ ref.current.click()
54
+ }}
55
+ >
56
+ {StyledUpload}
57
+ </div>
58
+ ) : (
59
+ <StyledImageLabel
60
+ onClick={() => {
61
+ ref.current.click()
62
+ }}
63
+ >
64
+ <InsertPhotoOutlined />
65
+ <Typography sx={{ opacity: '0.6' }}>
66
+ {loading ? 'Uploading...' : `Upload Photo`}
67
+ </Typography>
68
+ </StyledImageLabel>
69
+ )}
70
+
71
+ <input
72
+ accept="image/*"
73
+ type="file"
74
+ hidden
75
+ ref={ref}
76
+ onChange={handleChange}
77
+ />
78
+ </>
79
+ )
80
+ }
81
+
82
+ export const StyledImageLabel = styled('div')(({ theme }) => ({
83
+ cursor: 'pointer',
84
+ borderRadius: '10px',
85
+ width: '100%',
86
+ height: '150px',
87
+ border: '1px dashed #0000001A',
88
+ display: 'flex',
89
+ flexDirection: 'column',
90
+ justifyContent: 'center',
91
+ alignItems: 'center',
92
+ '&:hover': {
93
+ backgroundColor: '#EFEFEF',
94
+ },
95
+ '& > *': {
96
+ color: theme.palette.text.disabled,
97
+ },
98
+ }))