@tap-payments/auth-jsconnect 2.0.1 → 2.0.4

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 (76) hide show
  1. package/build/@types/app.d.ts +5 -0
  2. package/build/@types/form.d.ts +2 -1
  3. package/build/api/auth.d.ts +20 -3
  4. package/build/api/axios.js +8 -9
  5. package/build/api/data.d.ts +1 -0
  6. package/build/api/data.js +9 -2
  7. package/build/api/entity.d.ts +5 -1
  8. package/build/api/entity.js +11 -2
  9. package/build/api/index.d.ts +6 -4
  10. package/build/api/lead.d.ts +2 -1
  11. package/build/api/lead.js +14 -2
  12. package/build/components/AnimationFlow/AnimationFlow.d.ts +2 -1
  13. package/build/components/AnimationFlow/AnimationFlow.js +2 -2
  14. package/build/components/AnimationFlow/BottomSheet.d.ts +2 -1
  15. package/build/components/AnimationFlow/BottomSheet.js +16 -4
  16. package/build/constants/api.d.ts +2 -1
  17. package/build/constants/api.js +5 -3
  18. package/build/constants/app.d.ts +5 -0
  19. package/build/constants/app.js +21 -5
  20. package/build/features/app/bank/bankStore.js +17 -10
  21. package/build/features/app/business/businessStore.d.ts +3 -5
  22. package/build/features/app/business/businessStore.js +140 -48
  23. package/build/features/app/connect/connectStore.d.ts +5 -10
  24. package/build/features/app/connect/connectStore.js +117 -25
  25. package/build/features/app/individual/individualStore.d.ts +3 -2
  26. package/build/features/app/individual/individualStore.js +42 -30
  27. package/build/features/app/password/passwordStore.d.ts +29 -1
  28. package/build/features/app/password/passwordStore.js +194 -14
  29. package/build/features/app/tax/taxStore.js +19 -12
  30. package/build/features/bank/Bank.js +3 -4
  31. package/build/features/bank/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +16 -4
  32. package/build/features/business/Business.js +3 -4
  33. package/build/features/business/screens/Activities/Activities.js +1 -1
  34. package/build/features/business/screens/IDBOD/IDBOD.js +1 -1
  35. package/build/features/business/screens/OTP/OTPInput.js +3 -9
  36. package/build/features/business/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +17 -6
  37. package/build/features/connect/Connect.js +1 -1
  38. package/build/features/connect/screens/Mobile/Mobile.js +2 -2
  39. package/build/features/connect/screens/Mobile/MobileNumber.js +1 -1
  40. package/build/features/connect/screens/NID/IDNumber.js +1 -1
  41. package/build/features/connect/screens/NID/NID.js +2 -2
  42. package/build/features/connect/screens/OTP/OTPInput.js +3 -13
  43. package/build/features/featuresScreens.js +5 -0
  44. package/build/features/individual/Individual.js +3 -4
  45. package/build/features/individual/screens/AdditionalIndividualInfo/AdditionalIndividualInfo.js +7 -1
  46. package/build/features/individual/screens/AdditionalIndividualInfo/Occupation.d.ts +10 -0
  47. package/build/features/individual/screens/AdditionalIndividualInfo/Occupation.js +89 -0
  48. package/build/features/individual/screens/AdditionalIndividualInfo/validation.d.ts +3 -0
  49. package/build/features/individual/screens/AdditionalIndividualInfo/validation.js +1 -0
  50. package/build/features/individual/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +16 -4
  51. package/build/features/password/Password.js +11 -6
  52. package/build/features/password/screens/CreatePassword/CreatePassword.js +9 -2
  53. package/build/features/password/screens/OTP/OTP.d.ts +8 -0
  54. package/build/features/password/screens/OTP/OTP.js +78 -0
  55. package/build/features/password/screens/OTP/OTPInput.d.ts +5 -0
  56. package/build/features/password/screens/OTP/OTPInput.js +46 -0
  57. package/build/features/password/screens/OTP/index.d.ts +3 -0
  58. package/build/features/password/screens/OTP/index.js +2 -0
  59. package/build/features/password/screens/OTP/validation.d.ts +8 -0
  60. package/build/features/password/screens/OTP/validation.js +4 -0
  61. package/build/features/password/screens/Success/Success.js +8 -2
  62. package/build/features/password/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +17 -5
  63. package/build/features/password/screens/Verify/OTPInput.d.ts +2 -2
  64. package/build/features/password/screens/Verify/OTPInput.js +1 -1
  65. package/build/features/shared/Button/FlowsButtons.d.ts +8 -2
  66. package/build/features/shared/Button/FlowsButtons.js +92 -5
  67. package/build/features/shared/Button/SuccessButton.js +17 -13
  68. package/build/features/tax/Tax.js +3 -4
  69. package/build/features/tax/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +16 -4
  70. package/build/hooks/useAppTheme.js +3 -2
  71. package/build/index.css +4 -0
  72. package/build/theme/theme.d.ts +1 -1
  73. package/build/theme/theme.js +1 -2
  74. package/build/utils/string.d.ts +1 -0
  75. package/build/utils/string.js +4 -0
  76. package/package.json +1 -1
@@ -1,6 +1,7 @@
1
1
  import { useEffect, useState } from 'react';
2
2
  import { LanguageMode, DirectionMode } from '../@types';
3
3
  import { settingsSelector } from '../app/settings';
4
+ import { isMobile } from 'react-device-detect';
4
5
  import { useAppSelector } from './useAppSelector';
5
6
  import { appTheme } from '../theme';
6
7
  export var useAppTheme = function () {
@@ -8,7 +9,7 @@ export var useAppTheme = function () {
8
9
  var data = useAppSelector(settingsSelector).data;
9
10
  useEffect(function () {
10
11
  var dir = data.language === LanguageMode.AR ? DirectionMode.RTL : DirectionMode.LTR;
11
- setTheme(appTheme(data.skin, dir));
12
- }, [data.skin, data.language]);
12
+ setTheme(appTheme(data.skin, isMobile, dir));
13
+ }, [data.skin, data.language, isMobile]);
13
14
  return { theme: theme };
14
15
  };
package/build/index.css CHANGED
@@ -133,3 +133,7 @@ table {
133
133
  border-collapse: collapse;
134
134
  border-spacing: 0;
135
135
  }
136
+
137
+ * {
138
+ box-sizing: border-box;
139
+ }
@@ -1,2 +1,2 @@
1
1
  import { DirectionMode, ThemeMode } from '../@types';
2
- export declare const appTheme: (mode: ThemeMode, dir: DirectionMode) => import("@mui/material/styles").Theme;
2
+ export declare const appTheme: (mode: ThemeMode, isMobile: boolean, dir: DirectionMode) => import("@mui/material/styles").Theme;
@@ -3,8 +3,7 @@ import { typography } from './typography';
3
3
  import { darkPalette, lightPalette } from './palette';
4
4
  import { components } from './components';
5
5
  import { shadows } from './shadows';
6
- import { isMobile } from 'react-device-detect';
7
- export var appTheme = function (mode, dir) {
6
+ export var appTheme = function (mode, isMobile, dir) {
8
7
  return createTheme({
9
8
  palette: mode === 'dark' ? darkPalette : lightPalette,
10
9
  direction: dir,
@@ -11,6 +11,7 @@ export declare const convertNumbers2English: (str: string) => string;
11
11
  export declare const getParameterByName: (name: string) => string | null;
12
12
  export declare const getClientEmailUrl: () => string;
13
13
  export declare const getFlowUrl: (path: string, lang: string) => string;
14
+ export declare const getResetFlowUrl: (path: string, lang: string, operationType: string, leadId: string) => string;
14
15
  export declare const capitalizeTheFirstLetterOfEachWord: (words: string) => string;
15
16
  export declare const getRequestHeaders: (deviceInfo: DeviceInfo) => {
16
17
  al: string;
@@ -62,6 +62,10 @@ export var getFlowUrl = function (path, lang) {
62
62
  var origin = window.location.origin;
63
63
  return origin + path + "?lang=".concat(lang, "&token=");
64
64
  };
65
+ export var getResetFlowUrl = function (path, lang, operationType, leadId) {
66
+ var origin = window.location.origin;
67
+ return origin + path + "?lang=".concat(lang, "&operation_type=").concat(operationType, "&lead_id=").concat(leadId, "&token=");
68
+ };
65
69
  export var capitalizeTheFirstLetterOfEachWord = function (words) {
66
70
  var separateWord = words.toLowerCase().split(' ');
67
71
  for (var i = 0; i < separateWord.length; i++) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tap-payments/auth-jsconnect",
3
- "version": "2.0.1",
3
+ "version": "2.0.4",
4
4
  "description": "connect library, auth",
5
5
  "private": false,
6
6
  "main": "build/index.js",