@digitaldefiance/express-suite-react-components 5.0.1 → 5.0.2

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 (311) hide show
  1. package/LICENSE +21 -0
  2. package/package.json +3 -4
  3. package/src/auth/AdminRoute.tsx +54 -0
  4. package/src/auth/Private.tsx +17 -0
  5. package/src/auth/PrivateRoute.tsx +28 -0
  6. package/src/auth/UnAuth.tsx +16 -0
  7. package/src/auth/UnAuthRoute.tsx +30 -0
  8. package/src/auth/{index.d.ts → index.ts} +2 -3
  9. package/src/components/ApiAccess.tsx +175 -0
  10. package/src/components/BackupCodeLoginForm.tsx +489 -0
  11. package/src/components/BackupCodesForm.tsx +287 -0
  12. package/src/components/CategoryMenu.tsx +155 -0
  13. package/src/components/ChangePasswordForm.tsx +273 -0
  14. package/src/components/ConfirmationDialog.tsx +48 -0
  15. package/src/components/CurrencyCodeSelector.tsx +60 -0
  16. package/src/components/CurrencyInput.tsx +80 -0
  17. package/src/components/DashboardPage.tsx +24 -0
  18. package/src/components/DropdownMenu.tsx +105 -0
  19. package/src/components/ExpirationSecondsSelector.tsx +60 -0
  20. package/src/components/FakeEmailAdminPanel.tsx +374 -0
  21. package/src/components/Flag.tsx +52 -0
  22. package/src/components/ForgotPasswordForm.tsx +174 -0
  23. package/src/components/LoginForm.tsx +468 -0
  24. package/src/components/LogoutPage.tsx +21 -0
  25. package/src/components/RegisterForm.tsx +1169 -0
  26. package/src/components/ResetPasswordForm.tsx +247 -0
  27. package/src/components/SideMenu.tsx +46 -0
  28. package/src/components/SideMenuListItem.tsx +75 -0
  29. package/src/components/T.tsx +24 -0
  30. package/src/components/TDiv.tsx +26 -0
  31. package/src/components/TImgAlt.tsx +28 -0
  32. package/src/components/TopMenu.tsx +252 -0
  33. package/src/components/TotpSetupForm.tsx +188 -0
  34. package/src/components/TotpVerificationForm.tsx +148 -0
  35. package/src/components/TranslatedTitle.tsx +31 -0
  36. package/src/components/UserLanguageSelector.tsx +45 -0
  37. package/src/components/UserMenu.tsx +15 -0
  38. package/src/components/UserSettingsForm.tsx +904 -0
  39. package/src/components/VerifyEmailPage.tsx +222 -0
  40. package/src/components/__tests__/RegisterForm.totp.spec.tsx +377 -0
  41. package/src/components/__tests__/TotpSetupForm.spec.tsx +258 -0
  42. package/src/components/__tests__/TotpVerificationForm.spec.tsx +259 -0
  43. package/src/components/__tests__/UserSettingsForm.totp.spec.tsx +396 -0
  44. package/src/components/{index.d.ts → index.ts} +1 -1
  45. package/src/contexts/AuthProvider.spec.tsx +1284 -0
  46. package/src/contexts/AuthProvider.tsx +977 -0
  47. package/src/contexts/I18nProvider.tsx +164 -0
  48. package/src/contexts/MenuContext.tsx +426 -0
  49. package/src/contexts/SuiteConfigProvider.tsx +93 -0
  50. package/src/contexts/ThemeProvider.tsx +67 -0
  51. package/src/contexts/{index.d.ts → index.ts} +0 -1
  52. package/src/hooks/{index.d.ts → index.ts} +0 -1
  53. package/src/hooks/useAuthenticatedApi.tsx +67 -0
  54. package/src/hooks/useBackupCodes.ts +105 -0
  55. package/src/hooks/useEmailVerification.ts +54 -0
  56. package/src/hooks/useExpiringValue.ts +78 -0
  57. package/src/hooks/useLocalStorage.ts +18 -0
  58. package/src/hooks/useUserSettings.ts +271 -0
  59. package/src/{index.d.ts → index.ts} +1 -1
  60. package/src/interfaces/IAppConfig.ts +7 -0
  61. package/src/interfaces/ICategoryConfig.ts +41 -0
  62. package/src/interfaces/IMenuConfig.ts +28 -0
  63. package/src/interfaces/IMenuOption.ts +79 -0
  64. package/src/interfaces/{index.d.ts → index.ts} +0 -1
  65. package/src/services/__mocks__/authService.ts +14 -0
  66. package/src/services/__tests__/authService.totp.property.spec.ts +360 -0
  67. package/src/services/__tests__/authService.totp.spec.ts +439 -0
  68. package/src/services/api.ts +13 -0
  69. package/src/services/authService.ts +692 -0
  70. package/src/services/authenticatedApi.ts +17 -0
  71. package/src/services/index.ts +3 -0
  72. package/src/types/MenuType.ts +15 -0
  73. package/src/types/expirationSeconds.ts +18 -0
  74. package/src/types/index.ts +1 -0
  75. package/src/types/translation.ts +20 -0
  76. package/src/wrappers/BackupCodeLoginWrapper.tsx +34 -0
  77. package/src/wrappers/BackupCodesWrapper.tsx +28 -0
  78. package/src/wrappers/ChangePasswordFormWrapper.tsx +34 -0
  79. package/src/wrappers/ForgotPasswordFormWrapper.tsx +45 -0
  80. package/src/wrappers/LoginFormWrapper.tsx +108 -0
  81. package/src/wrappers/LogoutPageWrapper.tsx +30 -0
  82. package/src/wrappers/RegisterFormWrapper.tsx +109 -0
  83. package/src/wrappers/ResetPasswordFormWrapper.tsx +57 -0
  84. package/src/wrappers/UserSettingsFormWrapper.tsx +140 -0
  85. package/src/wrappers/VerifyEmailPageWrapper.tsx +27 -0
  86. package/src/wrappers/__tests__/LoginFormWrapper.totp.spec.tsx +339 -0
  87. package/src/wrappers/{index.d.ts → index.tsx} +10 -1
  88. package/src/auth/AdminRoute.d.ts +0 -8
  89. package/src/auth/AdminRoute.d.ts.map +0 -1
  90. package/src/auth/AdminRoute.js +0 -28
  91. package/src/auth/Private.d.ts +0 -6
  92. package/src/auth/Private.d.ts.map +0 -1
  93. package/src/auth/Private.js +0 -14
  94. package/src/auth/PrivateRoute.d.ts +0 -8
  95. package/src/auth/PrivateRoute.d.ts.map +0 -1
  96. package/src/auth/PrivateRoute.js +0 -23
  97. package/src/auth/UnAuth.d.ts +0 -6
  98. package/src/auth/UnAuth.d.ts.map +0 -1
  99. package/src/auth/UnAuth.js +0 -14
  100. package/src/auth/UnAuthRoute.d.ts +0 -8
  101. package/src/auth/UnAuthRoute.d.ts.map +0 -1
  102. package/src/auth/UnAuthRoute.js +0 -22
  103. package/src/auth/index.d.ts.map +0 -1
  104. package/src/auth/index.js +0 -12
  105. package/src/components/ApiAccess.d.ts +0 -16
  106. package/src/components/ApiAccess.d.ts.map +0 -1
  107. package/src/components/ApiAccess.js +0 -77
  108. package/src/components/BackupCodeLoginForm.d.ts +0 -43
  109. package/src/components/BackupCodeLoginForm.d.ts.map +0 -1
  110. package/src/components/BackupCodeLoginForm.js +0 -139
  111. package/src/components/BackupCodesForm.d.ts +0 -26
  112. package/src/components/BackupCodesForm.d.ts.map +0 -1
  113. package/src/components/BackupCodesForm.js +0 -120
  114. package/src/components/CategoryMenu.d.ts +0 -17
  115. package/src/components/CategoryMenu.d.ts.map +0 -1
  116. package/src/components/CategoryMenu.js +0 -65
  117. package/src/components/ChangePasswordForm.d.ts +0 -26
  118. package/src/components/ChangePasswordForm.d.ts.map +0 -1
  119. package/src/components/ChangePasswordForm.js +0 -78
  120. package/src/components/ConfirmationDialog.d.ts +0 -13
  121. package/src/components/ConfirmationDialog.d.ts.map +0 -1
  122. package/src/components/ConfirmationDialog.js +0 -10
  123. package/src/components/CurrencyCodeSelector.d.ts +0 -9
  124. package/src/components/CurrencyCodeSelector.d.ts.map +0 -1
  125. package/src/components/CurrencyCodeSelector.js +0 -31
  126. package/src/components/CurrencyInput.d.ts +0 -13
  127. package/src/components/CurrencyInput.d.ts.map +0 -1
  128. package/src/components/CurrencyInput.js +0 -22
  129. package/src/components/DashboardPage.d.ts +0 -8
  130. package/src/components/DashboardPage.d.ts.map +0 -1
  131. package/src/components/DashboardPage.js +0 -10
  132. package/src/components/DropdownMenu.d.ts +0 -13
  133. package/src/components/DropdownMenu.d.ts.map +0 -1
  134. package/src/components/DropdownMenu.js +0 -63
  135. package/src/components/ExpirationSecondsSelector.d.ts +0 -13
  136. package/src/components/ExpirationSecondsSelector.d.ts.map +0 -1
  137. package/src/components/ExpirationSecondsSelector.js +0 -32
  138. package/src/components/FakeEmailAdminPanel.d.ts +0 -23
  139. package/src/components/FakeEmailAdminPanel.d.ts.map +0 -1
  140. package/src/components/FakeEmailAdminPanel.js +0 -147
  141. package/src/components/Flag.d.ts +0 -20
  142. package/src/components/Flag.d.ts.map +0 -1
  143. package/src/components/Flag.js +0 -43
  144. package/src/components/ForgotPasswordForm.d.ts +0 -18
  145. package/src/components/ForgotPasswordForm.d.ts.map +0 -1
  146. package/src/components/ForgotPasswordForm.js +0 -61
  147. package/src/components/LoginForm.d.ts +0 -44
  148. package/src/components/LoginForm.d.ts.map +0 -1
  149. package/src/components/LoginForm.js +0 -123
  150. package/src/components/LogoutPage.d.ts +0 -8
  151. package/src/components/LogoutPage.d.ts.map +0 -1
  152. package/src/components/LogoutPage.js +0 -16
  153. package/src/components/RegisterForm.d.ts +0 -100
  154. package/src/components/RegisterForm.d.ts.map +0 -1
  155. package/src/components/RegisterForm.js +0 -306
  156. package/src/components/ResetPasswordForm.d.ts +0 -23
  157. package/src/components/ResetPasswordForm.d.ts.map +0 -1
  158. package/src/components/ResetPasswordForm.js +0 -78
  159. package/src/components/SideMenu.d.ts +0 -8
  160. package/src/components/SideMenu.d.ts.map +0 -1
  161. package/src/components/SideMenu.js +0 -25
  162. package/src/components/SideMenuListItem.d.ts +0 -13
  163. package/src/components/SideMenuListItem.d.ts.map +0 -1
  164. package/src/components/SideMenuListItem.js +0 -44
  165. package/src/components/T.d.ts +0 -7
  166. package/src/components/T.d.ts.map +0 -1
  167. package/src/components/T.js +0 -13
  168. package/src/components/TDiv.d.ts +0 -9
  169. package/src/components/TDiv.d.ts.map +0 -1
  170. package/src/components/TDiv.js +0 -14
  171. package/src/components/TImgAlt.d.ts +0 -10
  172. package/src/components/TImgAlt.d.ts.map +0 -1
  173. package/src/components/TImgAlt.js +0 -14
  174. package/src/components/TopMenu.d.ts +0 -50
  175. package/src/components/TopMenu.d.ts.map +0 -1
  176. package/src/components/TopMenu.js +0 -79
  177. package/src/components/TotpSetupForm.d.ts +0 -24
  178. package/src/components/TotpSetupForm.d.ts.map +0 -1
  179. package/src/components/TotpSetupForm.js +0 -82
  180. package/src/components/TotpVerificationForm.d.ts +0 -23
  181. package/src/components/TotpVerificationForm.d.ts.map +0 -1
  182. package/src/components/TotpVerificationForm.js +0 -66
  183. package/src/components/TranslatedTitle.d.ts +0 -8
  184. package/src/components/TranslatedTitle.d.ts.map +0 -1
  185. package/src/components/TranslatedTitle.js +0 -15
  186. package/src/components/UserLanguageSelector.d.ts +0 -4
  187. package/src/components/UserLanguageSelector.d.ts.map +0 -1
  188. package/src/components/UserLanguageSelector.js +0 -31
  189. package/src/components/UserMenu.d.ts +0 -4
  190. package/src/components/UserMenu.d.ts.map +0 -1
  191. package/src/components/UserMenu.js +0 -12
  192. package/src/components/UserSettingsForm.d.ts +0 -113
  193. package/src/components/UserSettingsForm.d.ts.map +0 -1
  194. package/src/components/UserSettingsForm.js +0 -269
  195. package/src/components/VerifyEmailPage.d.ts +0 -24
  196. package/src/components/VerifyEmailPage.d.ts.map +0 -1
  197. package/src/components/VerifyEmailPage.js +0 -81
  198. package/src/components/index.d.ts.map +0 -1
  199. package/src/components/index.js +0 -35
  200. package/src/contexts/AuthProvider.d.ts +0 -186
  201. package/src/contexts/AuthProvider.d.ts.map +0 -1
  202. package/src/contexts/AuthProvider.js +0 -515
  203. package/src/contexts/I18nProvider.d.ts +0 -27
  204. package/src/contexts/I18nProvider.d.ts.map +0 -1
  205. package/src/contexts/I18nProvider.js +0 -60
  206. package/src/contexts/MenuContext.d.ts +0 -20
  207. package/src/contexts/MenuContext.d.ts.map +0 -1
  208. package/src/contexts/MenuContext.js +0 -275
  209. package/src/contexts/SuiteConfigProvider.d.ts +0 -44
  210. package/src/contexts/SuiteConfigProvider.d.ts.map +0 -1
  211. package/src/contexts/SuiteConfigProvider.js +0 -43
  212. package/src/contexts/ThemeProvider.d.ts +0 -15
  213. package/src/contexts/ThemeProvider.d.ts.map +0 -1
  214. package/src/contexts/ThemeProvider.js +0 -36
  215. package/src/contexts/index.d.ts.map +0 -1
  216. package/src/contexts/index.js +0 -8
  217. package/src/hooks/index.d.ts.map +0 -1
  218. package/src/hooks/index.js +0 -9
  219. package/src/hooks/useAuthenticatedApi.d.ts +0 -34
  220. package/src/hooks/useAuthenticatedApi.d.ts.map +0 -1
  221. package/src/hooks/useAuthenticatedApi.js +0 -46
  222. package/src/hooks/useBackupCodes.d.ts +0 -15
  223. package/src/hooks/useBackupCodes.d.ts.map +0 -1
  224. package/src/hooks/useBackupCodes.js +0 -74
  225. package/src/hooks/useEmailVerification.d.ts +0 -10
  226. package/src/hooks/useEmailVerification.d.ts.map +0 -1
  227. package/src/hooks/useEmailVerification.js +0 -40
  228. package/src/hooks/useExpiringValue.d.ts +0 -14
  229. package/src/hooks/useExpiringValue.d.ts.map +0 -1
  230. package/src/hooks/useExpiringValue.js +0 -53
  231. package/src/hooks/useLocalStorage.d.ts +0 -2
  232. package/src/hooks/useLocalStorage.d.ts.map +0 -1
  233. package/src/hooks/useLocalStorage.js +0 -15
  234. package/src/hooks/useUserSettings.d.ts +0 -48
  235. package/src/hooks/useUserSettings.d.ts.map +0 -1
  236. package/src/hooks/useUserSettings.js +0 -171
  237. package/src/index.d.ts.map +0 -1
  238. package/src/index.js +0 -12
  239. package/src/interfaces/IAppConfig.d.ts +0 -8
  240. package/src/interfaces/IAppConfig.d.ts.map +0 -1
  241. package/src/interfaces/IAppConfig.js +0 -2
  242. package/src/interfaces/ICategoryConfig.d.ts +0 -41
  243. package/src/interfaces/ICategoryConfig.d.ts.map +0 -1
  244. package/src/interfaces/ICategoryConfig.js +0 -2
  245. package/src/interfaces/IMenuConfig.d.ts +0 -28
  246. package/src/interfaces/IMenuConfig.d.ts.map +0 -1
  247. package/src/interfaces/IMenuConfig.js +0 -2
  248. package/src/interfaces/IMenuOption.d.ts +0 -82
  249. package/src/interfaces/IMenuOption.d.ts.map +0 -1
  250. package/src/interfaces/IMenuOption.js +0 -2
  251. package/src/interfaces/index.d.ts.map +0 -1
  252. package/src/interfaces/index.js +0 -7
  253. package/src/services/__mocks__/authService.d.ts +0 -21
  254. package/src/services/__mocks__/authService.d.ts.map +0 -1
  255. package/src/services/__mocks__/authService.js +0 -15
  256. package/src/services/api.d.ts +0 -3
  257. package/src/services/api.d.ts.map +0 -1
  258. package/src/services/api.js +0 -14
  259. package/src/services/authService.d.ts +0 -126
  260. package/src/services/authService.d.ts.map +0 -1
  261. package/src/services/authService.js +0 -471
  262. package/src/services/authenticatedApi.d.ts +0 -3
  263. package/src/services/authenticatedApi.d.ts.map +0 -1
  264. package/src/services/authenticatedApi.js +0 -18
  265. package/src/services/index.d.ts +0 -4
  266. package/src/services/index.d.ts.map +0 -1
  267. package/src/services/index.js +0 -6
  268. package/src/types/MenuType.d.ts +0 -11
  269. package/src/types/MenuType.d.ts.map +0 -1
  270. package/src/types/MenuType.js +0 -12
  271. package/src/types/expirationSeconds.d.ts +0 -3
  272. package/src/types/expirationSeconds.d.ts.map +0 -1
  273. package/src/types/expirationSeconds.js +0 -17
  274. package/src/types/index.d.ts +0 -2
  275. package/src/types/index.d.ts.map +0 -1
  276. package/src/types/index.js +0 -4
  277. package/src/types/translation.d.ts +0 -10
  278. package/src/types/translation.d.ts.map +0 -1
  279. package/src/types/translation.js +0 -9
  280. package/src/wrappers/BackupCodeLoginWrapper.d.ts +0 -8
  281. package/src/wrappers/BackupCodeLoginWrapper.d.ts.map +0 -1
  282. package/src/wrappers/BackupCodeLoginWrapper.js +0 -20
  283. package/src/wrappers/BackupCodesWrapper.d.ts +0 -7
  284. package/src/wrappers/BackupCodesWrapper.d.ts.map +0 -1
  285. package/src/wrappers/BackupCodesWrapper.js +0 -17
  286. package/src/wrappers/ChangePasswordFormWrapper.d.ts +0 -8
  287. package/src/wrappers/ChangePasswordFormWrapper.d.ts.map +0 -1
  288. package/src/wrappers/ChangePasswordFormWrapper.js +0 -21
  289. package/src/wrappers/ForgotPasswordFormWrapper.d.ts +0 -8
  290. package/src/wrappers/ForgotPasswordFormWrapper.d.ts.map +0 -1
  291. package/src/wrappers/ForgotPasswordFormWrapper.js +0 -29
  292. package/src/wrappers/LoginFormWrapper.d.ts +0 -21
  293. package/src/wrappers/LoginFormWrapper.d.ts.map +0 -1
  294. package/src/wrappers/LoginFormWrapper.js +0 -72
  295. package/src/wrappers/LogoutPageWrapper.d.ts +0 -9
  296. package/src/wrappers/LogoutPageWrapper.d.ts.map +0 -1
  297. package/src/wrappers/LogoutPageWrapper.js +0 -21
  298. package/src/wrappers/RegisterFormWrapper.d.ts +0 -20
  299. package/src/wrappers/RegisterFormWrapper.d.ts.map +0 -1
  300. package/src/wrappers/RegisterFormWrapper.js +0 -51
  301. package/src/wrappers/ResetPasswordFormWrapper.d.ts +0 -9
  302. package/src/wrappers/ResetPasswordFormWrapper.d.ts.map +0 -1
  303. package/src/wrappers/ResetPasswordFormWrapper.js +0 -34
  304. package/src/wrappers/UserSettingsFormWrapper.d.ts +0 -29
  305. package/src/wrappers/UserSettingsFormWrapper.d.ts.map +0 -1
  306. package/src/wrappers/UserSettingsFormWrapper.js +0 -95
  307. package/src/wrappers/VerifyEmailPageWrapper.d.ts +0 -8
  308. package/src/wrappers/VerifyEmailPageWrapper.d.ts.map +0 -1
  309. package/src/wrappers/VerifyEmailPageWrapper.js +0 -21
  310. package/src/wrappers/index.d.ts.map +0 -1
  311. package/src/wrappers/index.js +0 -24
@@ -1,15 +0,0 @@
1
- "use strict";
2
- // src/app/components/TranslatedTitle.tsx
3
- Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.TranslatedTitle = void 0;
5
- const react_1 = require("react");
6
- const contexts_1 = require("../contexts");
7
- const TranslatedTitle = ({ componentId, stringKey, vars, }) => {
8
- const { tComponent, currentLanguage } = (0, contexts_1.useI18n)();
9
- (0, react_1.useEffect)(() => {
10
- document.title = tComponent(componentId, stringKey, vars, currentLanguage);
11
- }, [tComponent, componentId, stringKey, vars, currentLanguage]);
12
- return null;
13
- };
14
- exports.TranslatedTitle = TranslatedTitle;
15
- exports.default = exports.TranslatedTitle;
@@ -1,4 +0,0 @@
1
- import { FC } from 'react';
2
- export declare const UserLanguageSelector: FC;
3
- export default UserLanguageSelector;
4
- //# sourceMappingURL=UserLanguageSelector.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"UserLanguageSelector.d.ts","sourceRoot":"","sources":["../../../../../packages/digitaldefiance-express-suite-react-components/src/components/UserLanguageSelector.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,EAAE,EAAiC,MAAM,OAAO,CAAC;AAM1D,eAAO,MAAM,oBAAoB,EAAE,EAkClC,CAAC;AAEF,eAAe,oBAAoB,CAAC"}
@@ -1,31 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.UserLanguageSelector = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const i18n_lib_1 = require("@digitaldefiance/i18n-lib");
6
- const material_1 = require("@mui/material");
7
- const react_1 = require("react");
8
- const Flag_1 = require("./Flag");
9
- const hooks_1 = require("../hooks");
10
- const services_1 = require("../services");
11
- const contexts_1 = require("../contexts");
12
- const UserLanguageSelector = () => {
13
- const { baseUrl } = (0, contexts_1.useSuiteConfig)();
14
- const authenticatedApi = (0, react_1.useMemo)(() => (0, services_1.createAuthenticatedApiClient)(baseUrl), [baseUrl]);
15
- const { isAuthenticated } = (0, contexts_1.useAuth)();
16
- const { currentLanguage, changeLanguage } = (0, hooks_1.useUserSettings)({ authenticatedApi, isAuthenticated });
17
- const [anchorEl, setAnchorEl] = (0, react_1.useState)(null);
18
- const handleClick = (event) => {
19
- setAnchorEl(event.currentTarget);
20
- };
21
- const handleClose = () => {
22
- setAnchorEl(null);
23
- };
24
- const handleLanguageChange = (newLanguage) => {
25
- changeLanguage(newLanguage);
26
- handleClose();
27
- };
28
- return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, { onClick: handleClick, children: (0, jsx_runtime_1.jsx)(Flag_1.Flag, { language: currentLanguage }) }), (0, jsx_runtime_1.jsx)(material_1.Menu, { anchorEl: anchorEl, open: Boolean(anchorEl), onClose: handleClose, children: Object.values(i18n_lib_1.LanguageRegistry.getAllLanguages()).map((lang) => ((0, jsx_runtime_1.jsxs)(material_1.MenuItem, { onClick: () => handleLanguageChange(lang.code), children: [(0, jsx_runtime_1.jsx)(Flag_1.Flag, { language: lang.code, sx: { mr: 1 } }), " ", lang.name] }, lang.code))) })] }));
29
- };
30
- exports.UserLanguageSelector = UserLanguageSelector;
31
- exports.default = exports.UserLanguageSelector;
@@ -1,4 +0,0 @@
1
- import { FC } from 'react';
2
- export declare const UserMenu: FC;
3
- export default UserMenu;
4
- //# sourceMappingURL=UserMenu.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"UserMenu.d.ts","sourceRoot":"","sources":["../../../../../packages/digitaldefiance-express-suite-react-components/src/components/UserMenu.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAK3B,eAAO,MAAM,QAAQ,EAAE,EAOtB,CAAC;AAEF,eAAe,QAAQ,CAAC"}
@@ -1,12 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.UserMenu = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const icons_material_1 = require("@mui/icons-material");
6
- const MenuType_1 = require("../types/MenuType");
7
- const DropdownMenu_1 = require("./DropdownMenu");
8
- const UserMenu = () => {
9
- return ((0, jsx_runtime_1.jsx)(DropdownMenu_1.DropdownMenu, { menuType: MenuType_1.MenuTypes.UserMenu, menuIcon: (0, jsx_runtime_1.jsx)(icons_material_1.AccountCircle, {}) }));
10
- };
11
- exports.UserMenu = UserMenu;
12
- exports.default = exports.UserMenu;
@@ -1,113 +0,0 @@
1
- import { useFormik } from 'formik';
2
- import { FC } from 'react';
3
- import * as Yup from 'yup';
4
- export interface UserSettingsFormValues {
5
- email: string;
6
- timezone: string;
7
- siteLanguage: string;
8
- currency: string;
9
- darkMode: boolean;
10
- directChallenge: boolean;
11
- displayName?: string;
12
- [key: string]: string | boolean | undefined;
13
- }
14
- export interface UserSettingsFormProps {
15
- initialValues: UserSettingsFormValues;
16
- onSubmit: (values: UserSettingsFormValues) => Promise<{
17
- success: boolean;
18
- message: string;
19
- } | {
20
- error: string;
21
- errorType?: string;
22
- field?: string;
23
- errors?: Array<{
24
- path: string;
25
- msg: string;
26
- }>;
27
- }>;
28
- languages: Array<{
29
- code: string;
30
- label: string;
31
- }>;
32
- emailValidation?: Yup.StringSchema;
33
- timezoneValidation?: Yup.StringSchema;
34
- siteLanguageValidation?: Yup.StringSchema;
35
- currencyValidation?: Yup.StringSchema;
36
- darkModeValidation?: Yup.BooleanSchema;
37
- directChallengeValidation?: Yup.BooleanSchema;
38
- displayNameValidation?: Yup.StringSchema;
39
- additionalFields?: (formik: ReturnType<typeof useFormik<UserSettingsFormValues>>) => React.ReactNode;
40
- additionalInitialValues?: Record<string, string | boolean>;
41
- additionalValidation?: Record<string, Yup.Schema>;
42
- /**
43
- * Current TOTP 2FA status. When undefined (not passed), no TOTP controls are rendered.
44
- * When false, an "Enable 2FA" button is shown. When true, "Disable 2FA" and "Reset 2FA" buttons are shown.
45
- */
46
- totpEnabled?: boolean;
47
- /**
48
- * Called to initiate TOTP setup (e.g. AuthService.setupTotp()).
49
- * Must return provisioning URI and secret on success, or an error.
50
- */
51
- onTotpSetup?: () => Promise<{
52
- provisioningUri: string;
53
- secret: string;
54
- } | {
55
- error: string;
56
- }>;
57
- /**
58
- * Called to confirm TOTP setup with a 6-digit code (e.g. AuthService.confirmTotp()).
59
- */
60
- onTotpConfirm?: (code: string) => Promise<{
61
- success: boolean;
62
- } | {
63
- error: string;
64
- }>;
65
- /**
66
- * Called to disable TOTP with a 6-digit code (e.g. AuthService.disableTotp()).
67
- */
68
- onTotpDisable?: (code: string) => Promise<{
69
- success: boolean;
70
- } | {
71
- error: string;
72
- }>;
73
- /**
74
- * Called to reset TOTP with a 6-digit code (e.g. AuthService.resetTotp()).
75
- * Returns new provisioning URI and secret on success.
76
- */
77
- onTotpReset?: (code: string) => Promise<{
78
- provisioningUri: string;
79
- secret: string;
80
- } | {
81
- error: string;
82
- }>;
83
- labels?: {
84
- title?: string;
85
- email?: string;
86
- emailHelper?: string;
87
- timezone?: string;
88
- siteLanguage?: string;
89
- currency?: string;
90
- darkMode?: string;
91
- directChallenge?: string;
92
- directChallengeHelper?: string;
93
- displayName?: string;
94
- saving?: string;
95
- save?: string;
96
- successMessage?: string;
97
- totpSectionTitle?: string;
98
- totpStatusEnabled?: string;
99
- totpStatusDisabled?: string;
100
- totpEnableButton?: string;
101
- totpDisableButton?: string;
102
- totpResetButton?: string;
103
- totpDisableCodeLabel?: string;
104
- totpDisableSubmitButton?: string;
105
- totpResetCodeLabel?: string;
106
- totpResetSubmitButton?: string;
107
- totpCancelButton?: string;
108
- totpError?: string;
109
- };
110
- }
111
- export declare const UserSettingsForm: FC<UserSettingsFormProps>;
112
- export default UserSettingsForm;
113
- //# sourceMappingURL=UserSettingsForm.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"UserSettingsForm.d.ts","sourceRoot":"","sources":["../../../../../packages/digitaldefiance-express-suite-react-components/src/components/UserSettingsForm.tsx"],"names":[],"mappings":"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"}
@@ -1,269 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.UserSettingsForm = void 0;
4
- const tslib_1 = require("tslib");
5
- const jsx_runtime_1 = require("react/jsx-runtime");
6
- const i18n_lib_1 = require("@digitaldefiance/i18n-lib");
7
- const suite_core_lib_1 = require("@digitaldefiance/suite-core-lib");
8
- const material_1 = require("@mui/material");
9
- const formik_1 = require("formik");
10
- const moment_timezone_1 = tslib_1.__importDefault(require("moment-timezone"));
11
- const react_1 = require("react");
12
- const Yup = tslib_1.__importStar(require("yup"));
13
- const contexts_1 = require("../contexts");
14
- const suite_core_lib_2 = require("@digitaldefiance/suite-core-lib");
15
- const TotpSetupForm_1 = require("./TotpSetupForm");
16
- const UserSettingsForm = ({ initialValues, onSubmit, languages, emailValidation, timezoneValidation, siteLanguageValidation, currencyValidation, darkModeValidation, directChallengeValidation, displayNameValidation, additionalFields, additionalInitialValues = {}, additionalValidation = {}, totpEnabled, onTotpSetup, onTotpConfirm, onTotpDisable, onTotpReset, labels = {}, }) => {
17
- const { tComponent } = (0, contexts_1.useI18n)();
18
- const [apiErrors, setApiErrors] = (0, react_1.useState)({});
19
- const [saving, setSaving] = (0, react_1.useState)(false);
20
- const [successMessage, setSuccessMessage] = (0, react_1.useState)(null);
21
- // TOTP management state
22
- const [totpStatus, setTotpStatus] = (0, react_1.useState)(totpEnabled);
23
- // Sync totpStatus when the totpEnabled prop transitions from undefined to a
24
- // concrete value (i.e. after the wrapper fetches it asynchronously).
25
- (0, react_1.useEffect)(() => {
26
- if (totpEnabled !== undefined) {
27
- setTotpStatus(totpEnabled);
28
- }
29
- }, [totpEnabled]);
30
- const [showTotpSetup, setShowTotpSetup] = (0, react_1.useState)(false);
31
- const [totpProvisioningUri, setTotpProvisioningUri] = (0, react_1.useState)(null);
32
- const [totpSecret, setTotpSecret] = (0, react_1.useState)(null);
33
- const [totpSetupLoading, setTotpSetupLoading] = (0, react_1.useState)(false);
34
- const [totpError, setTotpError] = (0, react_1.useState)(null);
35
- const [showDisablePrompt, setShowDisablePrompt] = (0, react_1.useState)(false);
36
- const [disableCode, setDisableCode] = (0, react_1.useState)('');
37
- const [disableSubmitting, setDisableSubmitting] = (0, react_1.useState)(false);
38
- const [showResetPrompt, setShowResetPrompt] = (0, react_1.useState)(false);
39
- const [resetCode, setResetCode] = (0, react_1.useState)('');
40
- const [resetSubmitting, setResetSubmitting] = (0, react_1.useState)(false);
41
- const handleEnableTotp = (0, react_1.useCallback)(async () => {
42
- if (!onTotpSetup)
43
- return;
44
- setTotpSetupLoading(true);
45
- setTotpError(null);
46
- try {
47
- const result = await onTotpSetup();
48
- if ('error' in result) {
49
- setTotpError(result.error);
50
- }
51
- else {
52
- setTotpProvisioningUri(result.provisioningUri);
53
- setTotpSecret(result.secret);
54
- setShowTotpSetup(true);
55
- }
56
- }
57
- catch {
58
- setTotpError(labels.totpError || 'Failed to set up two-factor authentication');
59
- }
60
- finally {
61
- setTotpSetupLoading(false);
62
- }
63
- }, [onTotpSetup, labels.totpError]);
64
- const handleTotpConfirm = (0, react_1.useCallback)(async (code) => {
65
- if (!onTotpConfirm) {
66
- return { error: 'TOTP confirmation is not available' };
67
- }
68
- const result = await onTotpConfirm(code);
69
- if ('success' in result && result.success) {
70
- setTotpStatus(true);
71
- setShowTotpSetup(false);
72
- setTotpProvisioningUri(null);
73
- setTotpSecret(null);
74
- }
75
- return result;
76
- }, [onTotpConfirm]);
77
- const handleDisableTotp = (0, react_1.useCallback)(async () => {
78
- if (!onTotpDisable || !disableCode)
79
- return;
80
- setDisableSubmitting(true);
81
- setTotpError(null);
82
- try {
83
- const result = await onTotpDisable(disableCode);
84
- if ('error' in result) {
85
- setTotpError(result.error);
86
- }
87
- else {
88
- setTotpStatus(false);
89
- setShowDisablePrompt(false);
90
- setDisableCode('');
91
- }
92
- }
93
- catch {
94
- setTotpError(labels.totpError || 'Failed to disable two-factor authentication');
95
- }
96
- finally {
97
- setDisableSubmitting(false);
98
- }
99
- }, [onTotpDisable, disableCode, labels.totpError]);
100
- const handleResetTotp = (0, react_1.useCallback)(async () => {
101
- if (!onTotpReset || !resetCode)
102
- return;
103
- setResetSubmitting(true);
104
- setTotpError(null);
105
- try {
106
- const result = await onTotpReset(resetCode);
107
- if ('error' in result) {
108
- setTotpError(result.error);
109
- }
110
- else {
111
- setTotpProvisioningUri(result.provisioningUri);
112
- setTotpSecret(result.secret);
113
- setShowResetPrompt(false);
114
- setResetCode('');
115
- setShowTotpSetup(true);
116
- }
117
- }
118
- catch {
119
- setTotpError(labels.totpError || 'Failed to reset two-factor authentication');
120
- }
121
- finally {
122
- setResetSubmitting(false);
123
- }
124
- }, [onTotpReset, resetCode, labels.totpError]);
125
- const handleCancelTotpAction = (0, react_1.useCallback)(() => {
126
- setShowTotpSetup(false);
127
- setShowDisablePrompt(false);
128
- setShowResetPrompt(false);
129
- setTotpProvisioningUri(null);
130
- setTotpSecret(null);
131
- setDisableCode('');
132
- setResetCode('');
133
- setTotpError(null);
134
- }, []);
135
- const timezones = (0, react_1.useMemo)(() => moment_timezone_1.default.tz.names(), []);
136
- const currencies = (0, react_1.useMemo)(() => i18n_lib_1.CurrencyCode.getAllData().map((c) => ({
137
- code: c.code,
138
- label: `${c.code} - ${c.currency}`,
139
- })), []);
140
- const validation = {
141
- email: emailValidation ||
142
- Yup.string()
143
- .email(tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_InvalidEmail))
144
- .required(tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_Required)),
145
- timezone: timezoneValidation ||
146
- Yup.string()
147
- .required(tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_TimezoneRequired))
148
- .test('valid-timezone', tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_TimezoneInvalid), (value) => !value || moment_timezone_1.default.tz.zone(value) !== null),
149
- siteLanguage: siteLanguageValidation ||
150
- Yup.string().required(tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_Required)),
151
- currency: currencyValidation ||
152
- Yup.string()
153
- .required(tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_Required))
154
- .test('valid-currency', tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_Required), (value) => !value || i18n_lib_1.CurrencyCode.isValid(value)),
155
- darkMode: darkModeValidation ||
156
- Yup.boolean().required(tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_Required)),
157
- directChallenge: directChallengeValidation ||
158
- Yup.boolean().required(tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_Required)),
159
- ...(suite_core_lib_2.Constants.EnableDisplayName ? {
160
- displayName: displayNameValidation ||
161
- Yup.string()
162
- .min(suite_core_lib_2.Constants.DisplayNameMinLength, tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_DisplayNameMinLengthTemplate))
163
- .max(suite_core_lib_2.Constants.DisplayNameMaxLength, tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_DisplayNameMaxLengthTemplate))
164
- .matches(suite_core_lib_2.Constants.DisplayNameRegex, tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Validation_DisplayNameRegexErrorTemplate)),
165
- } : {}),
166
- };
167
- const formik = (0, formik_1.useFormik)({
168
- initialValues: {
169
- ...initialValues,
170
- ...additionalInitialValues,
171
- },
172
- enableReinitialize: true,
173
- validationSchema: Yup.object({
174
- email: validation.email,
175
- timezone: validation.timezone,
176
- siteLanguage: validation.siteLanguage,
177
- currency: validation.currency,
178
- darkMode: validation.darkMode,
179
- directChallenge: validation.directChallenge,
180
- ...(suite_core_lib_2.Constants.EnableDisplayName && validation.displayName ? { displayName: validation.displayName } : {}),
181
- ...additionalValidation,
182
- }),
183
- onSubmit: async (values, { setSubmitting, setFieldError, setTouched }) => {
184
- setSaving(true);
185
- setSuccessMessage(null);
186
- const result = await onSubmit(values);
187
- if ('success' in result && result.success) {
188
- setSuccessMessage(result.message ||
189
- labels.successMessage ||
190
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_SaveSuccess));
191
- setApiErrors({});
192
- }
193
- else {
194
- const newApiErrors = {};
195
- const fieldsToTouch = {};
196
- if ('field' in result && result.field) {
197
- setFieldError(result.field, result.error);
198
- fieldsToTouch[result.field] = true;
199
- }
200
- if ('errors' in result && result.errors) {
201
- result.errors.forEach((err) => {
202
- if (err.path && err.msg) {
203
- setFieldError(err.path, err.msg);
204
- fieldsToTouch[err.path] = true;
205
- }
206
- });
207
- }
208
- if ('error' in result &&
209
- result.error &&
210
- !Object.keys(newApiErrors).length) {
211
- newApiErrors.general = result.error;
212
- }
213
- setApiErrors(newApiErrors);
214
- setTouched(fieldsToTouch, false);
215
- }
216
- setSubmitting(false);
217
- setSaving(false);
218
- },
219
- });
220
- return ((0, jsx_runtime_1.jsx)(material_1.Container, { maxWidth: "sm", children: (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: {
221
- mt: 4,
222
- display: 'flex',
223
- flexDirection: 'column',
224
- alignItems: 'center',
225
- }, children: [(0, jsx_runtime_1.jsx)(material_1.Typography, { variant: "h4", component: "h1", gutterBottom: true, children: labels.title ||
226
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_Title) }), (0, jsx_runtime_1.jsxs)(material_1.Box, { component: "form", onSubmit: formik.handleSubmit, sx: { mt: 1, width: '100%' }, children: [(0, jsx_runtime_1.jsx)(material_1.TextField, { fullWidth: true, id: "email", name: "email", label: labels.email ||
227
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Common_Email), value: formik.values.email, onChange: formik.handleChange, onBlur: formik.handleBlur, error: Boolean(formik.touched.email && (formik.errors.email || apiErrors.email)), helperText: (formik.touched.email &&
228
- (formik.errors.email || apiErrors.email)) ||
229
- labels.emailHelper ||
230
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_EmailHelper), margin: "normal" }), suite_core_lib_2.Constants.EnableDisplayName && ((0, jsx_runtime_1.jsx)(material_1.TextField, { fullWidth: true, id: "displayName", name: "displayName", label: labels.displayName ||
231
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Common_DisplayName), value: formik.values.displayName ?? '', onChange: formik.handleChange, onBlur: formik.handleBlur, error: Boolean(formik.touched.displayName && (formik.errors.displayName || apiErrors.displayName)), helperText: formik.touched.displayName && (formik.errors.displayName || apiErrors.displayName), margin: "normal" })), (0, jsx_runtime_1.jsxs)(material_1.FormControl, { fullWidth: true, margin: "normal", children: [(0, jsx_runtime_1.jsx)(material_1.InputLabel, { id: "timezone-label", children: labels.timezone ||
232
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Common_Timezone) }), (0, jsx_runtime_1.jsx)(material_1.Select, { labelId: "timezone-label", id: "timezone", name: "timezone", value: formik.values.timezone, onChange: formik.handleChange, onBlur: formik.handleBlur, error: formik.touched.timezone && Boolean(formik.errors.timezone), label: labels.timezone ||
233
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Common_Timezone), children: timezones.map((tz) => ((0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: tz, children: tz }, tz))) }), formik.touched.timezone &&
234
- (formik.errors.timezone || apiErrors.timezone) && ((0, jsx_runtime_1.jsx)(material_1.Typography, { color: "error", variant: "caption", children: formik.errors.timezone || apiErrors.timezone }))] }), (0, jsx_runtime_1.jsxs)(material_1.FormControl, { fullWidth: true, margin: "normal", children: [(0, jsx_runtime_1.jsx)(material_1.InputLabel, { id: "language-label", children: labels.siteLanguage ||
235
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_SiteLanguage) }), (0, jsx_runtime_1.jsx)(material_1.Select, { labelId: "language-label", id: "siteLanguage", name: "siteLanguage", value: formik.values.siteLanguage, onChange: formik.handleChange, onBlur: formik.handleBlur, error: formik.touched.siteLanguage &&
236
- Boolean(formik.errors.siteLanguage), label: labels.siteLanguage ||
237
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_SiteLanguage), children: languages.map((lang) => ((0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: lang.code, children: lang.label }, lang.code))) }), formik.touched.siteLanguage &&
238
- (formik.errors.siteLanguage || apiErrors.siteLanguage) && ((0, jsx_runtime_1.jsx)(material_1.Typography, { color: "error", variant: "caption", children: formik.errors.siteLanguage || apiErrors.siteLanguage }))] }), (0, jsx_runtime_1.jsxs)(material_1.FormControl, { fullWidth: true, margin: "normal", children: [(0, jsx_runtime_1.jsx)(material_1.InputLabel, { id: "currency-label", children: labels.currency ||
239
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_Currency) }), (0, jsx_runtime_1.jsx)(material_1.Select, { labelId: "currency-label", id: "currency", name: "currency", value: formik.values.currency, onChange: formik.handleChange, onBlur: formik.handleBlur, error: formik.touched.currency && Boolean(formik.errors.currency), label: labels.currency ||
240
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_Currency), children: currencies.map((curr) => ((0, jsx_runtime_1.jsx)(material_1.MenuItem, { value: curr.code, children: curr.label }, curr.code))) }), formik.touched.currency &&
241
- (formik.errors.currency || apiErrors.currency) && ((0, jsx_runtime_1.jsx)(material_1.Typography, { color: "error", variant: "caption", children: formik.errors.currency || apiErrors.currency }))] }), (0, jsx_runtime_1.jsx)(material_1.FormControl, { fullWidth: true, margin: "normal", children: (0, jsx_runtime_1.jsx)(material_1.FormControlLabel, { control: (0, jsx_runtime_1.jsx)(material_1.Switch, { id: "darkMode", name: "darkMode", checked: formik.values.darkMode, onChange: formik.handleChange }), label: labels.darkMode ||
242
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_DarkMode) }) }), (0, jsx_runtime_1.jsxs)(material_1.FormControl, { fullWidth: true, margin: "normal", children: [(0, jsx_runtime_1.jsx)(material_1.FormControlLabel, { control: (0, jsx_runtime_1.jsx)(material_1.Switch, { id: "directChallenge", name: "directChallenge", checked: formik.values.directChallenge, onChange: formik.handleChange }), label: labels.directChallenge ||
243
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Registration_DirectChallengeLabel) }), (0, jsx_runtime_1.jsx)(material_1.Typography, { variant: "caption", color: "text.secondary", sx: { ml: 4, mt: -1 }, children: labels.directChallengeHelper ||
244
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Registration_DirectChallengeHelper) })] }), additionalFields && additionalFields(formik), apiErrors.general && ((0, jsx_runtime_1.jsx)(material_1.Alert, { severity: "error", sx: { mt: 2, mb: 2 }, children: apiErrors.general })), successMessage && ((0, jsx_runtime_1.jsx)(material_1.Alert, { severity: "success", sx: { mt: 2, mb: 2 }, children: successMessage })), (0, jsx_runtime_1.jsx)(material_1.Button, { type: "submit", fullWidth: true, variant: "contained", color: "primary", sx: { mt: 3, mb: 2 }, disabled: formik.isSubmitting, children: saving
245
- ? labels.saving ||
246
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_Saving)
247
- : labels.save ||
248
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Settings_Save) })] }), totpStatus !== undefined && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Divider, { sx: { mt: 3, mb: 2 } }), (0, jsx_runtime_1.jsx)(material_1.Typography, { variant: "h6", component: "h2", gutterBottom: true, children: labels.totpSectionTitle || 'Two-Factor Authentication' }), (0, jsx_runtime_1.jsx)(material_1.Typography, { variant: "body2", color: "text.secondary", sx: { mb: 2 }, children: totpStatus
249
- ? (labels.totpStatusEnabled || '2FA is currently enabled')
250
- : (labels.totpStatusDisabled || '2FA is currently disabled') }), totpError && ((0, jsx_runtime_1.jsx)(material_1.Alert, { severity: "error", sx: { mb: 2 }, role: "alert", children: totpError })), !totpStatus && !showTotpSetup && ((0, jsx_runtime_1.jsx)(material_1.Button, { type: "button", variant: "outlined", onClick: handleEnableTotp, disabled: totpSetupLoading, "data-testid": "enable-totp-button", children: totpSetupLoading
251
- ? 'Setting up...'
252
- : (labels.totpEnableButton || 'Enable 2FA') })), showTotpSetup && totpProvisioningUri && totpSecret && ((0, jsx_runtime_1.jsxs)(material_1.Box, { sx: { mt: 2 }, children: [(0, jsx_runtime_1.jsx)(TotpSetupForm_1.TotpSetupForm, { provisioningUri: totpProvisioningUri, secret: totpSecret, onConfirm: handleTotpConfirm }), (0, jsx_runtime_1.jsx)(material_1.Box, { sx: { textAlign: 'center', mt: 1 }, children: (0, jsx_runtime_1.jsx)(material_1.Button, { type: "button", variant: "text", onClick: handleCancelTotpAction, "data-testid": "cancel-totp-setup-button", children: labels.totpCancelButton || 'Cancel' }) })] })), totpStatus && !showTotpSetup && !showDisablePrompt && !showResetPrompt && ((0, jsx_runtime_1.jsxs)(material_1.Box, { sx: { display: 'flex', gap: 2 }, children: [(0, jsx_runtime_1.jsx)(material_1.Button, { type: "button", variant: "outlined", color: "error", onClick: () => { setShowDisablePrompt(true); setTotpError(null); }, "data-testid": "disable-totp-button", children: labels.totpDisableButton || 'Disable 2FA' }), (0, jsx_runtime_1.jsx)(material_1.Button, { type: "button", variant: "outlined", onClick: () => { setShowResetPrompt(true); setTotpError(null); }, "data-testid": "reset-totp-button", children: labels.totpResetButton || 'Reset 2FA' })] })), showDisablePrompt && ((0, jsx_runtime_1.jsxs)(material_1.Box, { sx: { mt: 2 }, children: [(0, jsx_runtime_1.jsx)(material_1.Typography, { variant: "body2", sx: { mb: 1 }, children: "Enter your current 2FA code to disable two-factor authentication:" }), (0, jsx_runtime_1.jsx)(material_1.TextField, { fullWidth: true, id: "totp-disable-code", name: "totp-disable-code", label: labels.totpDisableCodeLabel || 'TOTP Code', value: disableCode, onChange: (e) => setDisableCode(e.target.value), inputProps: {
253
- 'aria-label': labels.totpDisableCodeLabel || 'TOTP Code',
254
- inputMode: 'numeric',
255
- maxLength: 6,
256
- pattern: '\\d{6}',
257
- }, autoComplete: "one-time-code", margin: "normal" }), (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: { display: 'flex', gap: 2, mt: 1 }, children: [(0, jsx_runtime_1.jsx)(material_1.Button, { type: "button", variant: "contained", color: "error", onClick: handleDisableTotp, disabled: disableSubmitting || !/^\d{6}$/.test(disableCode), "data-testid": "disable-totp-submit-button", children: disableSubmitting
258
- ? 'Disabling...'
259
- : (labels.totpDisableSubmitButton || 'Confirm Disable') }), (0, jsx_runtime_1.jsx)(material_1.Button, { type: "button", variant: "text", onClick: handleCancelTotpAction, "data-testid": "cancel-disable-totp-button", children: labels.totpCancelButton || 'Cancel' })] })] })), showResetPrompt && ((0, jsx_runtime_1.jsxs)(material_1.Box, { sx: { mt: 2 }, children: [(0, jsx_runtime_1.jsx)(material_1.Typography, { variant: "body2", sx: { mb: 1 }, children: "Enter your current 2FA code to reset two-factor authentication:" }), (0, jsx_runtime_1.jsx)(material_1.TextField, { fullWidth: true, id: "totp-reset-code", name: "totp-reset-code", label: labels.totpResetCodeLabel || 'TOTP Code', value: resetCode, onChange: (e) => setResetCode(e.target.value), inputProps: {
260
- 'aria-label': labels.totpResetCodeLabel || 'TOTP Code',
261
- inputMode: 'numeric',
262
- maxLength: 6,
263
- pattern: '\\d{6}',
264
- }, autoComplete: "one-time-code", margin: "normal" }), (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: { display: 'flex', gap: 2, mt: 1 }, children: [(0, jsx_runtime_1.jsx)(material_1.Button, { type: "button", variant: "contained", onClick: handleResetTotp, disabled: resetSubmitting || !/^\d{6}$/.test(resetCode), "data-testid": "reset-totp-submit-button", children: resetSubmitting
265
- ? 'Resetting...'
266
- : (labels.totpResetSubmitButton || 'Confirm Reset') }), (0, jsx_runtime_1.jsx)(material_1.Button, { type: "button", variant: "text", onClick: handleCancelTotpAction, "data-testid": "cancel-reset-totp-button", children: labels.totpCancelButton || 'Cancel' })] })] }))] }))] }) }));
267
- };
268
- exports.UserSettingsForm = UserSettingsForm;
269
- exports.default = exports.UserSettingsForm;
@@ -1,24 +0,0 @@
1
- import { FC } from 'react';
2
- export interface VerifyEmailPageProps {
3
- token: string | null;
4
- onVerify: (token: string) => Promise<{
5
- success: boolean;
6
- message?: string;
7
- }>;
8
- labels?: {
9
- title?: string;
10
- verifying?: string;
11
- success?: string;
12
- failed?: string;
13
- noToken?: string;
14
- checkYourEmail?: string;
15
- proceedToLogin?: string;
16
- contactSupport?: string;
17
- requestNewEmail?: string;
18
- };
19
- loginLink?: string;
20
- resendLink?: string;
21
- }
22
- export declare const VerifyEmailPage: FC<VerifyEmailPageProps>;
23
- export default VerifyEmailPage;
24
- //# sourceMappingURL=VerifyEmailPage.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"VerifyEmailPage.d.ts","sourceRoot":"","sources":["../../../../../packages/digitaldefiance-express-suite-react-components/src/components/VerifyEmailPage.tsx"],"names":[],"mappings":"AAcA,OAAO,EAAE,EAAE,EAAwC,MAAM,OAAO,CAAC;AAGjE,MAAM,WAAW,oBAAoB;IACnC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC;QAAE,OAAO,EAAE,OAAO,CAAC;QAAC,OAAO,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAC7E,MAAM,CAAC,EAAE;QACP,KAAK,CAAC,EAAE,MAAM,CAAC;QACf,SAAS,CAAC,EAAE,MAAM,CAAC;QACnB,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,cAAc,CAAC,EAAE,MAAM,CAAC;QACxB,cAAc,CAAC,EAAE,MAAM,CAAC;QACxB,cAAc,CAAC,EAAE,MAAM,CAAC;QACxB,eAAe,CAAC,EAAE,MAAM,CAAC;KAC1B,CAAC;IACF,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,eAAO,MAAM,eAAe,EAAE,EAAE,CAAC,oBAAoB,CAwLpD,CAAC;AAEF,eAAe,eAAe,CAAC"}
@@ -1,81 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.VerifyEmailPage = void 0;
4
- const jsx_runtime_1 = require("react/jsx-runtime");
5
- const suite_core_lib_1 = require("@digitaldefiance/suite-core-lib");
6
- const material_1 = require("@mui/material");
7
- const react_1 = require("react");
8
- const contexts_1 = require("../contexts");
9
- const VerifyEmailPage = ({ token, onVerify, labels = {}, loginLink = '/login', resendLink = '/resend-verification', }) => {
10
- const { tComponent } = (0, contexts_1.useI18n)();
11
- const [message, setMessage] = (0, react_1.useState)('');
12
- const [loading, setLoading] = (0, react_1.useState)(true);
13
- const [verificationStatus, setVerificationStatus] = (0, react_1.useState)('pending');
14
- const translatedLabels = (0, react_1.useMemo)(() => {
15
- return {
16
- title: labels.title ||
17
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Common_EmailVerification),
18
- success: labels.success ||
19
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.EmailVerification_Success),
20
- failed: labels.failed ||
21
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.EmailVerification_Failed),
22
- noToken: labels.noToken ||
23
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.NoVerificationTokenProvided),
24
- checkYourEmail: labels.checkYourEmail ||
25
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.Registration_CheckYourEmail),
26
- proceedToLogin: labels.proceedToLogin ||
27
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.ProceedToLogin),
28
- contactSupport: labels.contactSupport ||
29
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.HavingTroubleContactSupport),
30
- requestNewEmail: labels.requestNewEmail ||
31
- tComponent(suite_core_lib_1.SuiteCoreComponentId, suite_core_lib_1.SuiteCoreStringKey.RequestNewVerificationEmail),
32
- };
33
- }, [labels, tComponent]);
34
- // Use a ref to track whether verification has already been attempted,
35
- // preventing infinite re-render loops from unstable onVerify references.
36
- const hasVerified = (0, react_1.useRef)(false);
37
- // Stable reference to onVerify to avoid re-triggering the effect
38
- const onVerifyRef = (0, react_1.useRef)(onVerify);
39
- onVerifyRef.current = onVerify;
40
- (0, react_1.useEffect)(() => {
41
- if (hasVerified.current)
42
- return;
43
- if (token) {
44
- hasVerified.current = true;
45
- const verifyEmail = async () => {
46
- try {
47
- const result = await onVerifyRef.current(token);
48
- if (result.success) {
49
- setMessage(result.message || translatedLabels.success);
50
- setVerificationStatus('success');
51
- }
52
- else {
53
- setMessage(result.message || translatedLabels.failed);
54
- setVerificationStatus('error');
55
- }
56
- }
57
- catch {
58
- setMessage(translatedLabels.failed);
59
- setVerificationStatus('error');
60
- }
61
- finally {
62
- setLoading(false);
63
- }
64
- };
65
- verifyEmail();
66
- }
67
- else {
68
- hasVerified.current = true;
69
- setLoading(false);
70
- setVerificationStatus('info');
71
- }
72
- }, [token, translatedLabels]);
73
- return ((0, jsx_runtime_1.jsx)(material_1.Container, { maxWidth: "sm", children: (0, jsx_runtime_1.jsxs)(material_1.Box, { sx: {
74
- mt: 8,
75
- display: 'flex',
76
- flexDirection: 'column',
77
- alignItems: 'center',
78
- }, children: [(0, jsx_runtime_1.jsx)(material_1.Typography, { variant: "h4", component: "h1", gutterBottom: true, children: translatedLabels.title }), loading ? ((0, jsx_runtime_1.jsx)(material_1.CircularProgress, {})) : ((0, jsx_runtime_1.jsx)(material_1.Box, { sx: { width: '100%', mt: 2 }, children: verificationStatus === 'info' ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Alert, { severity: "info", sx: { mb: 2 }, children: translatedLabels.noToken }), (0, jsx_runtime_1.jsxs)(material_1.Typography, { variant: "body1", children: [translatedLabels.contactSupport, ' ', (0, jsx_runtime_1.jsx)(material_1.Link, { href: resendLink, color: "primary", children: translatedLabels.requestNewEmail }), "."] })] })) : ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Alert, { severity: verificationStatus === 'success' ? 'success' : 'error', sx: { mb: 2 }, children: message }), verificationStatus === 'success' && ((0, jsx_runtime_1.jsx)(material_1.Button, { variant: "contained", color: "primary", component: material_1.Link, href: loginLink, fullWidth: true, children: translatedLabels.proceedToLogin })), verificationStatus === 'error' && ((0, jsx_runtime_1.jsxs)(material_1.Typography, { variant: "body1", children: [translatedLabels.contactSupport, ' ', (0, jsx_runtime_1.jsx)(material_1.Link, { href: resendLink, color: "primary", children: translatedLabels.requestNewEmail }), "."] }))] })) }))] }) }));
79
- };
80
- exports.VerifyEmailPage = VerifyEmailPage;
81
- exports.default = exports.VerifyEmailPage;
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../packages/digitaldefiance-express-suite-react-components/src/components/index.ts"],"names":[],"mappings":"AACA,cAAc,aAAa,CAAC;AAC5B,cAAc,uBAAuB,CAAC;AACtC,cAAc,mBAAmB,CAAC;AAClC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,wBAAwB,CAAC;AACvC,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,6BAA6B,CAAC;AAC5C,cAAc,uBAAuB,CAAC;AACtC,cAAc,QAAQ,CAAC;AACvB,cAAc,sBAAsB,CAAC;AACrC,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,YAAY,CAAC;AAC3B,cAAc,oBAAoB,CAAC;AACnC,cAAc,WAAW,CAAC;AAC1B,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,wBAAwB,CAAC;AACvC,cAAc,mBAAmB,CAAC;AAClC,cAAc,KAAK,CAAC;AACpB,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,wBAAwB,CAAC"}
@@ -1,35 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- // Component exports
5
- tslib_1.__exportStar(require("./ApiAccess"), exports);
6
- tslib_1.__exportStar(require("./BackupCodeLoginForm"), exports);
7
- tslib_1.__exportStar(require("./BackupCodesForm"), exports);
8
- tslib_1.__exportStar(require("./CategoryMenu"), exports);
9
- tslib_1.__exportStar(require("./ChangePasswordForm"), exports);
10
- tslib_1.__exportStar(require("./ConfirmationDialog"), exports);
11
- tslib_1.__exportStar(require("./CurrencyCodeSelector"), exports);
12
- tslib_1.__exportStar(require("./CurrencyInput"), exports);
13
- tslib_1.__exportStar(require("./DashboardPage"), exports);
14
- tslib_1.__exportStar(require("./DropdownMenu"), exports);
15
- tslib_1.__exportStar(require("./ExpirationSecondsSelector"), exports);
16
- tslib_1.__exportStar(require("./FakeEmailAdminPanel"), exports);
17
- tslib_1.__exportStar(require("./Flag"), exports);
18
- tslib_1.__exportStar(require("./ForgotPasswordForm"), exports);
19
- tslib_1.__exportStar(require("./LoginForm"), exports);
20
- tslib_1.__exportStar(require("./LogoutPage"), exports);
21
- tslib_1.__exportStar(require("./RegisterForm"), exports);
22
- tslib_1.__exportStar(require("./ResetPasswordForm"), exports);
23
- tslib_1.__exportStar(require("./UserSettingsForm"), exports);
24
- tslib_1.__exportStar(require("./SideMenu"), exports);
25
- tslib_1.__exportStar(require("./SideMenuListItem"), exports);
26
- tslib_1.__exportStar(require("./TopMenu"), exports);
27
- tslib_1.__exportStar(require("./TranslatedTitle"), exports);
28
- tslib_1.__exportStar(require("./UserMenu"), exports);
29
- tslib_1.__exportStar(require("./UserLanguageSelector"), exports);
30
- tslib_1.__exportStar(require("./VerifyEmailPage"), exports);
31
- tslib_1.__exportStar(require("./T"), exports);
32
- tslib_1.__exportStar(require("./TDiv"), exports);
33
- tslib_1.__exportStar(require("./TImgAlt"), exports);
34
- tslib_1.__exportStar(require("./TotpSetupForm"), exports);
35
- tslib_1.__exportStar(require("./TotpVerificationForm"), exports);