@tap-payments/auth-jsconnect 2.10.6-development → 2.10.6

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 (191) hide show
  1. package/README.md +2 -2
  2. package/build/@types/app.d.ts +2 -2
  3. package/build/@types/app.js +0 -1
  4. package/build/@types/form.d.ts +2 -0
  5. package/build/@types/index.d.ts +0 -1
  6. package/build/@types/index.js +0 -1
  7. package/build/api/auth.d.ts +1 -9
  8. package/build/api/axios.d.ts +1 -1
  9. package/build/api/entity.d.ts +3 -0
  10. package/build/api/index.d.ts +1 -8
  11. package/build/api/index.js +1 -3
  12. package/build/api/lead.d.ts +1 -0
  13. package/build/app/rootReducer.d.ts +0 -1
  14. package/build/app/rootReducer.js +1 -3
  15. package/build/app/settings.js +1 -2
  16. package/build/app/store.d.ts +0 -2
  17. package/build/assets/currencies/AEDSymbol.d.ts +7 -0
  18. package/build/assets/currencies/AEDSymbol.js +28 -0
  19. package/build/assets/currencies/SARSymbol.js +1 -1
  20. package/build/assets/currencies/index.d.ts +2 -2
  21. package/build/assets/currencies/index.js +2 -2
  22. package/build/assets/currencies/utils.js +3 -1
  23. package/build/assets/locales/ar.json +13 -5
  24. package/build/assets/locales/en.json +14 -5
  25. package/build/components/OTPTimer/OTPTimer.d.ts +1 -2
  26. package/build/components/OTPTimer/OTPTimer.js +4 -4
  27. package/build/components/TextWithCurrency/TextWithCurrency.js +1 -1
  28. package/build/components/Tooltip/Tooltip.js +1 -1
  29. package/build/constants/api.d.ts +2 -0
  30. package/build/constants/api.js +4 -0
  31. package/build/constants/app.d.ts +12 -12
  32. package/build/constants/app.js +8 -119
  33. package/build/constants/assets.d.ts +4 -6
  34. package/build/constants/assets.js +118 -114
  35. package/build/constants/dummy.js +27 -20
  36. package/build/constants/flows.d.ts +0 -15
  37. package/build/constants/flows.js +0 -15
  38. package/build/constants/validation.d.ts +1 -1
  39. package/build/constants/validation.js +1 -1
  40. package/build/features/app/business/businessStore.js +15 -10
  41. package/build/features/app/connectExpress/connectExpressStore.js +19 -4
  42. package/build/features/app/individual/individualStore.js +1 -0
  43. package/build/features/auth/Auth.d.ts +1 -1
  44. package/build/features/auth/screens/AuthenticationList/EntityLicenseType.d.ts +2 -2
  45. package/build/features/auth/screens/AuthenticationList/EntityList.js +2 -2
  46. package/build/features/brand/screens/BrandActivities/ActivitiesList.d.ts +2 -2
  47. package/build/features/brand/screens/BrandActivities/RefundPolicy.d.ts +1 -1
  48. package/build/features/business/screens/BusinessType/BusinessType.js +13 -2
  49. package/build/features/business/screens/BusinessType/EntityLicenseList.js +11 -5
  50. package/build/features/business/screens/BusinessType/LicenseList.js +15 -7
  51. package/build/features/business/screens/BusinessType/LicenseType.d.ts +2 -2
  52. package/build/features/business/screens/BusinessType/UnifiedNumber.d.ts +35 -0
  53. package/build/features/business/screens/BusinessType/UnifiedNumber.js +84 -0
  54. package/build/features/business/screens/BusinessType/validation.d.ts +6 -3
  55. package/build/features/business/screens/BusinessType/validation.js +31 -10
  56. package/build/features/business/screens/Customers/CustomerLocations.d.ts +2 -2
  57. package/build/features/business/screens/Customers/RefundPolicy.d.ts +1 -1
  58. package/build/features/connectExpress/screens/AuthenticationList/EntityLicenseType.d.ts +2 -2
  59. package/build/features/connectExpress/screens/AuthenticationList/EntityList.js +2 -2
  60. package/build/features/connectExpress/screens/CollectBusinessInfo/CollectBusinessInfo.js +1 -0
  61. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseList.js +23 -7
  62. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseNumber.js +2 -2
  63. package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseType.d.ts +2 -2
  64. package/build/features/connectExpress/screens/CollectBusinessInfo/TAC.js +1 -1
  65. package/build/features/connectExpress/screens/CollectBusinessInfo/UnifiedNumber.d.ts +36 -0
  66. package/build/features/connectExpress/screens/CollectBusinessInfo/UnifiedNumber.js +81 -0
  67. package/build/features/connectExpress/screens/CollectBusinessInfo/validation.d.ts +6 -3
  68. package/build/features/connectExpress/screens/CollectBusinessInfo/validation.js +57 -21
  69. package/build/features/entity/screens/EntityName/EntityName.js +16 -15
  70. package/build/features/entity/screens/EntityName/EntityTypeList.d.ts +2 -2
  71. package/build/features/entity/screens/EntityName/UnifiedNumber.js +2 -2
  72. package/build/features/entity/screens/EntityName/validation.d.ts +50 -48
  73. package/build/features/entity/screens/EntityName/validation.js +100 -85
  74. package/build/features/featuresScreens.d.ts +0 -1
  75. package/build/features/featuresScreens.js +0 -67
  76. package/build/features/individual/screens/AdditionalIndividualInfo/IsAuthorizedSwitch.d.ts +2 -2
  77. package/build/features/individual/screens/AdditionalIndividualInfo/PEPSwitch.d.ts +2 -2
  78. package/build/features/individual/screens/IndividualPersonalInfo/Gender.d.ts +2 -2
  79. package/build/features/shared/Address/CountryList.d.ts +1 -1
  80. package/build/features/shared/Address/InputSelect.d.ts +1 -1
  81. package/build/features/shared/Button/Button.js +1 -1
  82. package/build/features/shared/Button/FlowsButtons.js +2 -3
  83. package/build/features/shared/SuccessFlowButtons/SuccessFlowButtons.js +2 -2
  84. package/build/features/shared/SuccessScreen/SuccessScreen.d.ts +1 -3
  85. package/build/features/shared/SuccessScreen/SuccessScreen.js +2 -2
  86. package/build/hooks/useAppConfig.js +1 -1
  87. package/build/hooks/useAppDispatch.d.ts +0 -1
  88. package/build/index.d.ts +2 -3
  89. package/build/index.js +2 -4
  90. package/build/theme/palette.js +0 -12
  91. package/build/theme/typography.js +0 -4
  92. package/build/utils/common.d.ts +1 -1
  93. package/build/utils/common.js +14 -8
  94. package/build/utils/string.d.ts +3 -2
  95. package/build/utils/string.js +5 -5
  96. package/build/utils/validation.js +1 -1
  97. package/package.json +3 -3
  98. package/build/@types/terminal.d.ts +0 -116
  99. package/build/@types/terminal.js +0 -1
  100. package/build/api/terminal.d.ts +0 -26
  101. package/build/api/terminal.js +0 -57
  102. package/build/components/DeviceCard/DeviceCard.d.ts +0 -18
  103. package/build/components/DeviceCard/DeviceCard.js +0 -103
  104. package/build/components/DeviceCard/index.d.ts +0 -3
  105. package/build/components/DeviceCard/index.js +0 -2
  106. package/build/features/app/terminal/terminalStore.d.ts +0 -109
  107. package/build/features/app/terminal/terminalStore.js +0 -673
  108. package/build/features/shared/PushNotification/PushNotification.d.ts +0 -11
  109. package/build/features/shared/PushNotification/PushNotification.js +0 -34
  110. package/build/features/shared/PushNotification/index.d.ts +0 -2
  111. package/build/features/shared/PushNotification/index.js +0 -2
  112. package/build/features/terminal/Terminal.d.ts +0 -14
  113. package/build/features/terminal/Terminal.js +0 -95
  114. package/build/features/terminal/index.d.ts +0 -1
  115. package/build/features/terminal/index.js +0 -1
  116. package/build/features/terminal/screens/LinkNewTerminal/LinkNewTerminal.d.ts +0 -3
  117. package/build/features/terminal/screens/LinkNewTerminal/LinkNewTerminal.js +0 -68
  118. package/build/features/terminal/screens/LinkNewTerminal/index.d.ts +0 -2
  119. package/build/features/terminal/screens/LinkNewTerminal/index.js +0 -2
  120. package/build/features/terminal/screens/LinkNewTerminal/styles.d.ts +0 -10
  121. package/build/features/terminal/screens/LinkNewTerminal/styles.js +0 -28
  122. package/build/features/terminal/screens/LinkedSuccess/LinkedSuccess.d.ts +0 -3
  123. package/build/features/terminal/screens/LinkedSuccess/LinkedSuccess.js +0 -51
  124. package/build/features/terminal/screens/LinkedSuccess/index.d.ts +0 -2
  125. package/build/features/terminal/screens/LinkedSuccess/index.js +0 -2
  126. package/build/features/terminal/screens/LinkedTerminalInfo/LinkedTerminalInfo.d.ts +0 -3
  127. package/build/features/terminal/screens/LinkedTerminalInfo/LinkedTerminalInfo.js +0 -50
  128. package/build/features/terminal/screens/LinkedTerminalInfo/index.d.ts +0 -2
  129. package/build/features/terminal/screens/LinkedTerminalInfo/index.js +0 -2
  130. package/build/features/terminal/screens/Loading/Loading.d.ts +0 -4
  131. package/build/features/terminal/screens/Loading/Loading.js +0 -10
  132. package/build/features/terminal/screens/Loading/index.d.ts +0 -2
  133. package/build/features/terminal/screens/Loading/index.js +0 -2
  134. package/build/features/terminal/screens/NoTerminalDeviceLinked/NoTerminalDeviceLinked.d.ts +0 -3
  135. package/build/features/terminal/screens/NoTerminalDeviceLinked/NoTerminalDeviceLinked.js +0 -56
  136. package/build/features/terminal/screens/NoTerminalDeviceLinked/index.d.ts +0 -2
  137. package/build/features/terminal/screens/NoTerminalDeviceLinked/index.js +0 -2
  138. package/build/features/terminal/screens/NoTerminalDeviceLinked/styles.d.ts +0 -36
  139. package/build/features/terminal/screens/NoTerminalDeviceLinked/styles.js +0 -34
  140. package/build/features/terminal/screens/OperatorError/OperatorError.d.ts +0 -5
  141. package/build/features/terminal/screens/OperatorError/OperatorError.js +0 -9
  142. package/build/features/terminal/screens/OperatorError/index.d.ts +0 -2
  143. package/build/features/terminal/screens/OperatorError/index.js +0 -2
  144. package/build/features/terminal/screens/ResetPasswordSuccess/ResetPasswordSuccess.d.ts +0 -3
  145. package/build/features/terminal/screens/ResetPasswordSuccess/ResetPasswordSuccess.js +0 -21
  146. package/build/features/terminal/screens/ResetPasswordSuccess/index.d.ts +0 -2
  147. package/build/features/terminal/screens/ResetPasswordSuccess/index.js +0 -2
  148. package/build/features/terminal/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.d.ts +0 -3
  149. package/build/features/terminal/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +0 -31
  150. package/build/features/terminal/screens/SuccessWithFlowButtons/index.d.ts +0 -2
  151. package/build/features/terminal/screens/SuccessWithFlowButtons/index.js +0 -2
  152. package/build/features/terminal/screens/TerminalDeviceList/DeviceList.d.ts +0 -9
  153. package/build/features/terminal/screens/TerminalDeviceList/DeviceList.js +0 -20
  154. package/build/features/terminal/screens/TerminalDeviceList/TerminalDeviceList.d.ts +0 -3
  155. package/build/features/terminal/screens/TerminalDeviceList/TerminalDeviceList.js +0 -144
  156. package/build/features/terminal/screens/TerminalDeviceList/index.d.ts +0 -2
  157. package/build/features/terminal/screens/TerminalDeviceList/index.js +0 -2
  158. package/build/features/terminal/screens/TerminalDeviceList/styles.d.ts +0 -9
  159. package/build/features/terminal/screens/TerminalDeviceList/styles.js +0 -13
  160. package/build/features/terminal/screens/TerminalListPage/TerminalListPage.d.ts +0 -3
  161. package/build/features/terminal/screens/TerminalListPage/TerminalListPage.js +0 -42
  162. package/build/features/terminal/screens/TerminalListPage/index.d.ts +0 -2
  163. package/build/features/terminal/screens/TerminalListPage/index.js +0 -2
  164. package/build/features/terminal/screens/UnlinkedSuccess/UnlinkedSuccess.d.ts +0 -3
  165. package/build/features/terminal/screens/UnlinkedSuccess/UnlinkedSuccess.js +0 -53
  166. package/build/features/terminal/screens/UnlinkedSuccess/index.d.ts +0 -2
  167. package/build/features/terminal/screens/UnlinkedSuccess/index.js +0 -2
  168. package/build/features/terminal/screens/UnlinkedTerminalInfo/UnlinkedTerminalInfo.d.ts +0 -3
  169. package/build/features/terminal/screens/UnlinkedTerminalInfo/UnlinkedTerminalInfo.js +0 -98
  170. package/build/features/terminal/screens/UnlinkedTerminalInfo/index.d.ts +0 -2
  171. package/build/features/terminal/screens/UnlinkedTerminalInfo/index.js +0 -2
  172. package/build/features/terminal/screens/UnlinkedTerminalInfo/styles.d.ts +0 -26
  173. package/build/features/terminal/screens/UnlinkedTerminalInfo/styles.js +0 -30
  174. package/build/features/terminal/screens/Verify/OTPInput.d.ts +0 -7
  175. package/build/features/terminal/screens/Verify/OTPInput.js +0 -51
  176. package/build/features/terminal/screens/Verify/Verify.d.ts +0 -5
  177. package/build/features/terminal/screens/Verify/Verify.js +0 -85
  178. package/build/features/terminal/screens/Verify/index.d.ts +0 -2
  179. package/build/features/terminal/screens/Verify/index.js +0 -2
  180. package/build/features/terminal/screens/Verify/validation.d.ts +0 -8
  181. package/build/features/terminal/screens/Verify/validation.js +0 -4
  182. package/build/features/terminal/screens/shared/Header.d.ts +0 -10
  183. package/build/features/terminal/screens/shared/Header.js +0 -30
  184. package/build/features/terminal/screens/shared/TerminalList.d.ts +0 -11
  185. package/build/features/terminal/screens/shared/TerminalList.js +0 -25
  186. package/build/features/terminal/screens/shared/index.d.ts +0 -5
  187. package/build/features/terminal/screens/shared/index.js +0 -5
  188. package/build/features/terminal/screens/shared/styles.d.ts +0 -196
  189. package/build/features/terminal/screens/shared/styles.js +0 -155
  190. package/build/features/terminal/screens/shared/utils.d.ts +0 -7
  191. package/build/features/terminal/screens/shared/utils.js +0 -24
@@ -1,67 +1,56 @@
1
1
  import * as yup from 'yup';
2
2
  import { BusinessType } from '../../../../@types';
3
- import { KW_MIN_LICENSE_LENGTH, CR_MIN_LICENSE_LENGTH, FL_MIN_LICENSE_LENGTH } from '../../../../constants';
4
- export var EntityNameValidationSchema = function () {
3
+ import { KW_MIN_LICENSE_LENGTH, UNIFIED_NUMBER_MIN_LENGTH } from '../../../../constants';
4
+ export var EntityNameValidationSchema = function (noneEditable) {
5
5
  return yup.object().shape({
6
- legalName: yup
7
- .string()
8
- .required('')
9
- .test({
10
- test: function (value) {
11
- var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
12
- if (length === 0)
13
- return true;
14
- return length >= 3 ? true : this.createError({ message: 'enter_legal_name_min_three_chars' });
15
- }
16
- }),
6
+ legalName: noneEditable['legal_name.en'] && noneEditable['legal_name.ar']
7
+ ? yup.string().optional()
8
+ : yup
9
+ .string()
10
+ .required('')
11
+ .test({
12
+ test: function (value) {
13
+ var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
14
+ if (length === 0)
15
+ return true;
16
+ return length >= 3 ? true : this.createError({ message: 'enter_legal_name_min_three_chars' });
17
+ }
18
+ }),
17
19
  licenseType: yup.string().optional(),
18
- entityType: yup.string().required('entity_type_required'),
19
- licenseNumber: yup
20
- .string()
21
- .test({
22
- test: function (value) {
23
- var type = this.parent.licenseType;
24
- var isCR = type === BusinessType.CR;
25
- var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
26
- if (length === 0)
27
- return true;
28
- if (isCR) {
29
- return length >= CR_MIN_LICENSE_LENGTH ? true : this.createError({ message: 'cr_max_length' });
20
+ entityType: noneEditable['type'] ? yup.string().optional() : yup.string().required('entity_type_required'),
21
+ licenseNumber: yup.string().optional(),
22
+ unifiedNumber: noneEditable['license.additional_info']
23
+ ? yup.string().optional()
24
+ : yup.string().when('licenseType', function (licenseType) {
25
+ var isCR = licenseType === BusinessType.CR;
26
+ if (!isCR) {
27
+ return yup.string().optional();
30
28
  }
31
- return length >= FL_MIN_LICENSE_LENGTH ? true : this.createError({ message: 'fl_max_length' });
32
- }
33
- })
34
- .required(''),
35
- unifiedNumber: yup.string().optional(),
36
- issuingDate: yup.string().required('choose_any_issuing_date'),
37
- expiryDate: yup.string().required('choose_any_expiry_date'),
29
+ return yup
30
+ .string()
31
+ .required('')
32
+ .test({
33
+ test: function (value) {
34
+ var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
35
+ if (length >= UNIFIED_NUMBER_MIN_LENGTH)
36
+ return true;
37
+ if (length === 0)
38
+ return this.createError({ message: '' });
39
+ return this.createError({ message: 'unified_number_required' });
40
+ }
41
+ });
42
+ }),
43
+ issuingDate: noneEditable['license.issuing_date'] ? yup.string().optional() : yup.string().required('choose_any_issuing_date'),
44
+ expiryDate: yup.string().optional(),
38
45
  certificateId: yup.array().optional(),
39
46
  articleId: yup.string().optional()
40
47
  });
41
48
  };
42
- export var EntityNameKWValidationSchema = function () {
49
+ export var EntityNameKWValidationSchema = function (noneEditable) {
43
50
  return yup.object().shape({
44
- legalName: yup
45
- .string()
46
- .required('')
47
- .test({
48
- test: function (value) {
49
- var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
50
- if (length === 0)
51
- return true;
52
- return length >= 3 ? true : this.createError({ message: 'enter_legal_name_min_three_chars' });
53
- }
54
- }),
55
- licenseType: yup.string().optional(),
56
- entityType: yup.string().required('entity_type_required'),
57
- licenseNumber: yup
58
- .string()
59
- .when('licenseType', function (licenseType) {
60
- var isCR = licenseType === BusinessType.CR;
61
- if (!isCR) {
62
- return yup.string().optional();
63
- }
64
- return yup
51
+ legalName: noneEditable['legal_name.en'] && noneEditable['legal_name.ar']
52
+ ? yup.string().optional()
53
+ : yup
65
54
  .string()
66
55
  .required('')
67
56
  .test({
@@ -69,37 +58,44 @@ export var EntityNameKWValidationSchema = function () {
69
58
  var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
70
59
  if (length === 0)
71
60
  return true;
72
- return length >= KW_MIN_LICENSE_LENGTH ? true : this.createError({ message: 'cr_kw_max_length' });
61
+ return length >= 3 ? true : this.createError({ message: 'enter_legal_name_min_three_chars' });
62
+ }
63
+ }),
64
+ licenseType: yup.string().optional(),
65
+ entityType: noneEditable['type'] ? yup.string().optional() : yup.string().required('entity_type_required'),
66
+ licenseNumber: noneEditable['license.number']
67
+ ? yup.string().optional()
68
+ : yup
69
+ .string()
70
+ .when('licenseType', function (licenseType) {
71
+ var isCR = licenseType === BusinessType.CR;
72
+ if (!isCR) {
73
+ return yup.string().optional();
73
74
  }
74
- });
75
- })
76
- .required(''),
77
- issuingDate: yup.string().required('choose_any_issuing_date'),
78
- expiryDate: yup.string().required('choose_any_expiry_date'),
75
+ return yup
76
+ .string()
77
+ .required('')
78
+ .test({
79
+ test: function (value) {
80
+ var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
81
+ if (length === 0)
82
+ return true;
83
+ return length >= KW_MIN_LICENSE_LENGTH ? true : this.createError({ message: 'cr_kw_max_length' });
84
+ }
85
+ });
86
+ })
87
+ .required(''),
88
+ issuingDate: noneEditable['license.issuing_date'] ? yup.string().optional() : yup.string().required('choose_any_issuing_date'),
89
+ expiryDate: noneEditable['license.expiry_date'] ? yup.string().optional() : yup.string().required('choose_any_expiry_date'),
79
90
  certificateId: yup.array().optional(),
80
91
  articleId: yup.string().optional()
81
92
  });
82
93
  };
83
- export var EntityNameOtherCountryValidationSchema = function () {
94
+ export var EntityNameOtherCountryValidationSchema = function (noneEditable) {
84
95
  return yup.object().shape({
85
- legalName: yup
86
- .string()
87
- .required('')
88
- .test({
89
- test: function (value) {
90
- var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
91
- if (length === 0)
92
- return true;
93
- return length >= 3 ? true : this.createError({ message: 'enter_legal_name_min_three_chars' });
94
- }
95
- }),
96
- licenseType: yup.string().optional(),
97
- entityType: yup.string().required('entity_type_required'),
98
- licenseNumber: yup
99
- .string()
100
- .when('licenseType', function (licenseType) {
101
- var isCR = licenseType === BusinessType.CR;
102
- return yup
96
+ legalName: noneEditable['legal_name.en'] && noneEditable['legal_name.ar']
97
+ ? yup.string().optional()
98
+ : yup
103
99
  .string()
104
100
  .required('')
105
101
  .test({
@@ -107,13 +103,32 @@ export var EntityNameOtherCountryValidationSchema = function () {
107
103
  var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
108
104
  if (length === 0)
109
105
  return true;
110
- return length >= KW_MIN_LICENSE_LENGTH ? true : this.createError({ message: isCR ? 'cr_kw_max_length' : 'fl_max_length' });
106
+ return length >= 3 ? true : this.createError({ message: 'enter_legal_name_min_three_chars' });
111
107
  }
112
- });
113
- })
114
- .required(''),
115
- issuingDate: yup.string().required('choose_any_issuing_date'),
116
- expiryDate: yup.string().required('choose_any_expiry_date'),
108
+ }),
109
+ licenseType: yup.string().optional(),
110
+ entityType: noneEditable['type'] ? yup.string().optional() : yup.string().required('entity_type_required'),
111
+ licenseNumber: noneEditable['license.number']
112
+ ? yup.string().optional()
113
+ : yup
114
+ .string()
115
+ .when('licenseType', function (licenseType) {
116
+ var isCR = licenseType === BusinessType.CR;
117
+ return yup
118
+ .string()
119
+ .required('')
120
+ .test({
121
+ test: function (value) {
122
+ var length = (value === null || value === void 0 ? void 0 : value.length) || 0;
123
+ if (length === 0)
124
+ return true;
125
+ return length >= KW_MIN_LICENSE_LENGTH ? true : this.createError({ message: isCR ? 'cr_kw_max_length' : 'fl_max_length' });
126
+ }
127
+ });
128
+ })
129
+ .required(''),
130
+ issuingDate: noneEditable['license.issuing_date'] ? yup.string().optional() : yup.string().required('choose_any_issuing_date'),
131
+ expiryDate: noneEditable['license.expiry_date'] ? yup.string().optional() : yup.string().required('choose_any_expiry_date'),
117
132
  certificateId: yup.array().optional(),
118
133
  articleId: yup.string().optional()
119
134
  });
@@ -12,4 +12,3 @@ export declare const entityFeatureScreens: Array<FeatureScreenStep>;
12
12
  export declare const brandFeatureScreens: Array<FeatureScreenStep>;
13
13
  export declare const boardFeatureScreens: Array<FeatureScreenStep>;
14
14
  export declare const kycFeatureScreens: Array<FeatureScreenStep>;
15
- export declare const terminalFeatureScreens: Array<FeatureScreenStep>;
@@ -141,19 +141,6 @@ import KycOperatorErrorPage from './kyc/screens/OperatorError';
141
141
  import KycSuccessPage from './kyc/screens/Success';
142
142
  import KycTermsPage from './kyc/screens/Terms';
143
143
  import KycUsersPage from './kyc/screens/Users';
144
- import TerminalLoadingPage from './terminal/screens/Loading';
145
- import TerminalOperatorErrorPage from './terminal/screens/OperatorError';
146
- import TerminalVerifyPage from './terminal/screens/Verify';
147
- import NoTerminalDeviceLinkedPage from './terminal/screens/NoTerminalDeviceLinked';
148
- import TerminalDeviceListPage from './terminal/screens/TerminalDeviceList';
149
- import TerminalListPage from './terminal/screens/TerminalListPage';
150
- import LinkNewTerminalPage from './terminal/screens/LinkNewTerminal';
151
- import LinkedTerminalInfoPage from './terminal/screens/LinkedTerminalInfo';
152
- import UnlinkedTerminalInfoPage from './terminal/screens/UnlinkedTerminalInfo';
153
- import LinkedSuccessPage from './terminal/screens/LinkedSuccess';
154
- import UnlinkedSuccessPage from './terminal/screens/UnlinkedSuccess';
155
- import TerminalBoardPage from './terminal/screens/SuccessWithFlowButtons';
156
- import TerminalResetPasswordSuccessPage from './terminal/screens/ResetPasswordSuccess';
157
144
  export var connectFeatureScreens = [
158
145
  {
159
146
  name: 'CONNECT_BUSINESS_COUNTRY_STEP',
@@ -718,57 +705,3 @@ export var kycFeatureScreens = [
718
705
  element: KycSuccessPage
719
706
  }
720
707
  ];
721
- export var terminalFeatureScreens = [
722
- {
723
- name: CONNECT_FLOWS.terminal.loadingData,
724
- element: TerminalLoadingPage
725
- },
726
- {
727
- name: CONNECT_FLOWS.terminal.operatorError,
728
- element: TerminalOperatorErrorPage
729
- },
730
- {
731
- name: CONNECT_FLOWS.terminal.verify,
732
- element: TerminalVerifyPage
733
- },
734
- {
735
- name: CONNECT_FLOWS.terminal.noTerminalLinked,
736
- element: NoTerminalDeviceLinkedPage
737
- },
738
- {
739
- name: CONNECT_FLOWS.terminal.terminalDeviceList,
740
- element: TerminalDeviceListPage
741
- },
742
- {
743
- name: CONNECT_FLOWS.terminal.terminalLinkNew,
744
- element: LinkNewTerminalPage
745
- },
746
- {
747
- name: CONNECT_FLOWS.terminal.terminalList,
748
- element: TerminalListPage
749
- },
750
- {
751
- name: CONNECT_FLOWS.terminal.linkedTerminalInfo,
752
- element: LinkedTerminalInfoPage
753
- },
754
- {
755
- name: CONNECT_FLOWS.terminal.unlinkedTerminalInfo,
756
- element: UnlinkedTerminalInfoPage
757
- },
758
- {
759
- name: CONNECT_FLOWS.terminal.terminalLinkedSuccess,
760
- element: LinkedSuccessPage
761
- },
762
- {
763
- name: CONNECT_FLOWS.terminal.terminalUnlinkedSuccess,
764
- element: UnlinkedSuccessPage
765
- },
766
- {
767
- name: CONNECT_FLOWS.terminal.board,
768
- element: TerminalBoardPage
769
- },
770
- {
771
- name: CONNECT_FLOWS.terminal.resetPassword,
772
- element: TerminalResetPasswordSuccessPage
773
- }
774
- ];
@@ -2,7 +2,7 @@ import * as React from 'react';
2
2
  export declare const InfoIconStyled: import("@emotion/styled").StyledComponent<{
3
3
  children?: React.ReactNode;
4
4
  classes?: Partial<import("@mui/material").SvgIconClasses> | undefined;
5
- color?: "inherit" | "disabled" | "error" | "info" | "action" | "success" | "primary" | "secondary" | "warning" | undefined;
5
+ color?: "inherit" | "disabled" | "error" | "info" | "success" | "action" | "primary" | "secondary" | "warning" | undefined;
6
6
  fontSize?: "small" | "inherit" | "medium" | "large" | undefined;
7
7
  htmlColor?: string | undefined;
8
8
  inheritViewBox?: boolean | undefined;
@@ -16,7 +16,7 @@ export declare const InfoIconStyled: import("@emotion/styled").StyledComponent<{
16
16
  export declare const InfoOutlinedIconStyled: import("@emotion/styled").StyledComponent<{
17
17
  children?: React.ReactNode;
18
18
  classes?: Partial<import("@mui/material").SvgIconClasses> | undefined;
19
- color?: "inherit" | "disabled" | "error" | "info" | "action" | "success" | "primary" | "secondary" | "warning" | undefined;
19
+ color?: "inherit" | "disabled" | "error" | "info" | "success" | "action" | "primary" | "secondary" | "warning" | undefined;
20
20
  fontSize?: "small" | "inherit" | "medium" | "large" | undefined;
21
21
  htmlColor?: string | undefined;
22
22
  inheritViewBox?: boolean | undefined;
@@ -2,7 +2,7 @@ import * as React from 'react';
2
2
  export declare const InfoIconStyled: import("@emotion/styled").StyledComponent<{
3
3
  children?: React.ReactNode;
4
4
  classes?: Partial<import("@mui/material").SvgIconClasses> | undefined;
5
- color?: "inherit" | "disabled" | "error" | "info" | "action" | "success" | "primary" | "secondary" | "warning" | undefined;
5
+ color?: "inherit" | "disabled" | "error" | "info" | "success" | "action" | "primary" | "secondary" | "warning" | undefined;
6
6
  fontSize?: "small" | "inherit" | "medium" | "large" | undefined;
7
7
  htmlColor?: string | undefined;
8
8
  inheritViewBox?: boolean | undefined;
@@ -16,7 +16,7 @@ export declare const InfoIconStyled: import("@emotion/styled").StyledComponent<{
16
16
  export declare const InfoOutlinedIconStyled: import("@emotion/styled").StyledComponent<{
17
17
  children?: React.ReactNode;
18
18
  classes?: Partial<import("@mui/material").SvgIconClasses> | undefined;
19
- color?: "inherit" | "disabled" | "error" | "info" | "action" | "success" | "primary" | "secondary" | "warning" | undefined;
19
+ color?: "inherit" | "disabled" | "error" | "info" | "success" | "action" | "primary" | "secondary" | "warning" | undefined;
20
20
  fontSize?: "small" | "inherit" | "medium" | "large" | undefined;
21
21
  htmlColor?: string | undefined;
22
22
  inheritViewBox?: boolean | undefined;
@@ -2,7 +2,7 @@ import * as React from 'react';
2
2
  export declare const InfoIconStyled: import("@emotion/styled").StyledComponent<{
3
3
  children?: React.ReactNode;
4
4
  classes?: Partial<import("@mui/material").SvgIconClasses> | undefined;
5
- color?: "inherit" | "disabled" | "error" | "info" | "action" | "success" | "primary" | "secondary" | "warning" | undefined;
5
+ color?: "inherit" | "disabled" | "error" | "info" | "success" | "action" | "primary" | "secondary" | "warning" | undefined;
6
6
  fontSize?: "small" | "inherit" | "medium" | "large" | undefined;
7
7
  htmlColor?: string | undefined;
8
8
  inheritViewBox?: boolean | undefined;
@@ -16,7 +16,7 @@ export declare const InfoIconStyled: import("@emotion/styled").StyledComponent<{
16
16
  export declare const InfoOutlinedIconStyled: import("@emotion/styled").StyledComponent<{
17
17
  children?: React.ReactNode;
18
18
  classes?: Partial<import("@mui/material").SvgIconClasses> | undefined;
19
- color?: "inherit" | "disabled" | "error" | "info" | "action" | "success" | "primary" | "secondary" | "warning" | undefined;
19
+ color?: "inherit" | "disabled" | "error" | "info" | "success" | "action" | "primary" | "secondary" | "warning" | undefined;
20
20
  fontSize?: "small" | "inherit" | "medium" | "large" | undefined;
21
21
  htmlColor?: string | undefined;
22
22
  inheritViewBox?: boolean | undefined;
@@ -30,7 +30,7 @@ export declare const LabelContainerStyled: import("@emotion/styled").StyledCompo
30
30
  export declare const CheckIconStyled: import("@emotion/styled").StyledComponent<{
31
31
  children?: React.ReactNode;
32
32
  classes?: Partial<import("@mui/material").SvgIconClasses> | undefined;
33
- color?: "inherit" | "disabled" | "error" | "info" | "action" | "success" | "primary" | "secondary" | "warning" | undefined;
33
+ color?: "inherit" | "disabled" | "error" | "info" | "success" | "action" | "primary" | "secondary" | "warning" | undefined;
34
34
  fontSize?: "small" | "inherit" | "medium" | "large" | undefined;
35
35
  htmlColor?: string | undefined;
36
36
  inheritViewBox?: boolean | undefined;
@@ -29,7 +29,7 @@ export declare const LabelContainerStyled: import("@emotion/styled").StyledCompo
29
29
  export declare const CheckIconStyled: import("@emotion/styled").StyledComponent<{
30
30
  children?: React.ReactNode;
31
31
  classes?: Partial<import("@mui/material").SvgIconClasses> | undefined;
32
- color?: "inherit" | "disabled" | "error" | "info" | "action" | "success" | "primary" | "secondary" | "warning" | undefined;
32
+ color?: "inherit" | "disabled" | "error" | "info" | "success" | "action" | "primary" | "secondary" | "warning" | undefined;
33
33
  fontSize?: "small" | "inherit" | "medium" | "large" | undefined;
34
34
  htmlColor?: string | undefined;
35
35
  inheritViewBox?: boolean | undefined;
@@ -112,5 +112,5 @@ export default function CustomButton(_a) {
112
112
  }, 500);
113
113
  };
114
114
  }, []);
115
- return (_jsxs(Fragment, { children: [_jsx(Collapse, __assign({ in: !!error && !hideError }, { children: _jsx(Warning, __assign({ sx: { mb: 1 }, warningType: 'error' }, { children: error })) })), _jsxs(ButtonBoxStyled, __assign({ sx: sx }, { children: [isBackEnabled && (_jsx(BackButtonStyled, __assign({ isAr: isAr, type: 'reset', startIcon: _jsx(BackIconStyled, { isAr: isAr, src: ICONS_NAMES.WHITE_ARROW }) }, props, { onClick: function () { return onBackClicked === null || onBackClicked === void 0 ? void 0 : onBackClicked(); } }))), _jsx(ButtonStyled, __assign({ disabled: disabled, isLoading: btnLoading, type: !btnLoading ? 'submit' : 'button', isBack: isBackEnabled, endIcon: btnLoading === false ? !disableNextIcon && _jsx(IconStyled, { isAr: isAr, src: ICONS_NAMES.WHITE_ARROW }) : undefined }, props, { children: !btnLoading ? (_jsxs(Text, __assign({ sx: { marginInlineEnd: isBackEnabled ? '-24px' : '-15px' } }, { children: [" ", children] }))) : (_jsx(Loader, { innerColor: 'white', outerColor: 'white', size: 15, toggleAnimation: !!btnLoading })) }))] }))] }));
115
+ return (_jsxs(Fragment, { children: [_jsx(Collapse, __assign({ in: !!error && !hideError }, { children: _jsx(Warning, __assign({ sx: { mb: 1 }, warningType: 'error' }, { children: error })) })), _jsxs(ButtonBoxStyled, __assign({ sx: sx }, { children: [isBackEnabled && (_jsx(BackButtonStyled, __assign({ onClick: function () { return onBackClicked === null || onBackClicked === void 0 ? void 0 : onBackClicked(); }, isAr: isAr, type: 'reset', startIcon: _jsx(BackIconStyled, { isAr: isAr, src: ICONS_NAMES.WHITE_ARROW }) }, props))), _jsx(ButtonStyled, __assign({ disabled: disabled, isLoading: btnLoading, type: !btnLoading ? 'submit' : 'button', isBack: isBackEnabled, endIcon: btnLoading === false ? !disableNextIcon && _jsx(IconStyled, { isAr: isAr, src: ICONS_NAMES.WHITE_ARROW }) : undefined }, props, { children: !btnLoading ? (_jsxs(Text, __assign({ sx: { marginInlineEnd: isBackEnabled ? '-24px' : '-15px' } }, { children: [" ", children] }))) : (_jsx(Loader, { innerColor: 'white', outerColor: 'white', size: 15, toggleAnimation: !!btnLoading })) }))] }))] }));
116
116
  }
@@ -163,7 +163,6 @@ export default function FlowsButtons(_a) {
163
163
  var isAr = useLanguage().isAr;
164
164
  var t = useTranslation().t;
165
165
  var onRedirect = function (item) {
166
- var _a;
167
166
  if (!item.href)
168
167
  return;
169
168
  var name = item.name === FlowsTypes.BANK ? 'Wallet' : capitalize(item.name);
@@ -181,7 +180,7 @@ export default function FlowsButtons(_a) {
181
180
  return;
182
181
  }
183
182
  if (typeof settingsData.appConfig.onBoardButtonClick === 'function') {
184
- settingsData.appConfig.onBoardButtonClick({ name: item.name, token: item.token, countryCode: (_a = settingsData.businessCountry) === null || _a === void 0 ? void 0 : _a.iso2 });
183
+ settingsData.appConfig.onBoardButtonClick({ name: item.name, token: item.token });
185
184
  return;
186
185
  }
187
186
  dispatch(handleOpen(false));
@@ -242,6 +241,6 @@ export default function FlowsButtons(_a) {
242
241
  onResetPassword();
243
242
  else
244
243
  onRedirect({ title: title, href: href, src: src, hoverSrc: hoverSrc, isCompleted: isCompleted, name: name, status: status, token: token });
245
- } }, { children: _jsx(ButtonStyled, __assign({ variant: 'outlined', disabled: isResetPassword(name, status) && loading, isCompleted: isCompleted, hasUrl: !!href, sx: __assign({ mb: isLast ? 2.5 : 1.8 }, sx), endIcon: isResetPassword(name, status) && loading ? (_jsx(_Fragment, {})) : isCompleted ? (_jsx(CheckIconStyled, {})) : (_jsxs("div", __assign({ style: { display: 'flex', alignItems: 'center' } }, { children: [name !== 'password' && name !== 'terminal' && (_jsx(Dot, { completed: ['complete', 'completed', 'reviewed'].includes(status === null || status === void 0 ? void 0 : status.toLowerCase()) })), _jsx(Image, { sx: { height: 15, transform: isAr ? 'scale(-1)' : 'scale(1)', marginInlineStart: 0 }, src: ICONS_NAMES.Arrow_filled_right_icon })] }))), startIcon: isResetPassword(name, status) && loading ? (_jsx(_Fragment, {})) : isBrand(name) ? (_jsx(_Fragment, { children: _jsx(BrandImage, { children: _jsx(BrandNameStyled, { children: brandName }) }) })) : (_jsx(Image, { src: src, alt: title })), type: 'button' }, { children: title })) }), idx));
244
+ } }, { children: _jsx(ButtonStyled, __assign({ variant: 'outlined', disabled: isResetPassword(name, status) && loading, isCompleted: isCompleted, hasUrl: !!href, sx: __assign({ mb: isLast ? 2.5 : 1.8 }, sx), endIcon: isResetPassword(name, status) && loading ? (_jsx(_Fragment, {})) : isCompleted ? (_jsx(CheckIconStyled, {})) : (_jsxs("div", __assign({ style: { display: 'flex', alignItems: 'center' } }, { children: [name !== 'password' && _jsx(Dot, { completed: ['complete', 'completed', 'reviewed'].includes(status === null || status === void 0 ? void 0 : status.toLowerCase()) }), _jsx(Image, { sx: { height: 15, transform: isAr ? 'scale(-1)' : 'scale(1)', marginInlineStart: 0 }, src: ICONS_NAMES.Arrow_filled_right_icon })] }))), startIcon: isResetPassword(name, status) && loading ? (_jsx(_Fragment, {})) : isBrand(name) ? (_jsx(_Fragment, { children: _jsx(BrandImage, { children: _jsx(BrandNameStyled, { children: brandName }) }) })) : (_jsx(Image, { src: src, alt: title })), type: 'button' }, { children: title })) }), idx));
246
245
  }), onClose && (_jsx(SharedButton, __assign({ sx: { mt: 2.5, ml: 0, mr: 0 }, isAr: isAr, disableBack: true, loading: storeLoading, onClick: onClose }, { children: t('close_and_complete_later') })))] }));
247
246
  }
@@ -72,8 +72,7 @@ var SuccessFlowButtons = function (_a) {
72
72
  { name: 'entity', status: entity === null || entity === void 0 ? void 0 : entity.data_state },
73
73
  { name: 'bank', status: bank === null || bank === void 0 ? void 0 : bank.data_state },
74
74
  { name: 'tax', status: entity === null || entity === void 0 ? void 0 : entity.tax_data_state },
75
- { name: 'individual', status: individuals === null || individuals === void 0 ? void 0 : individuals.data_state },
76
- { name: 'terminal', status: '' }
75
+ { name: 'individual', status: individuals === null || individuals === void 0 ? void 0 : individuals.data_state }
77
76
  ];
78
77
  var reMapFlowData = function (flows) {
79
78
  if (flows === void 0) { flows = []; }
@@ -118,6 +117,7 @@ var SuccessFlowButtons = function (_a) {
118
117
  }, [flows, isAr]);
119
118
  useEffect(function () {
120
119
  var _a, _b;
120
+ console.log('status', status);
121
121
  if ((status === null || status === void 0 ? void 0 : status.toLocaleLowerCase()) === 'complete') {
122
122
  (_b = (_a = settings.data.appConfig).onBoardCompleted) === null || _b === void 0 ? void 0 : _b.call(_a);
123
123
  }
@@ -1,4 +1,3 @@
1
- import { SxProps, Theme } from '@mui/material/styles';
2
1
  import * as React from 'react';
3
2
  export interface ThankYouProps {
4
3
  title?: string;
@@ -10,7 +9,6 @@ export interface ThankYouProps {
10
9
  description?: string | React.ReactElement;
11
10
  enableBack?: boolean;
12
11
  onBack?: () => void;
13
- sx?: SxProps<Theme>;
14
12
  }
15
- declare const _default: React.MemoExoticComponent<({ title, description, showEmailProviders, onSuccess, successTitle, loading, error, enableBack, onBack, sx }: ThankYouProps) => JSX.Element>;
13
+ declare const _default: React.MemoExoticComponent<({ title, description, showEmailProviders, onSuccess, successTitle, loading, error, enableBack, onBack }: ThankYouProps) => JSX.Element>;
16
14
  export default _default;
@@ -55,9 +55,9 @@ var IconStyled = styled(Icon)(function (_a) {
55
55
  _b);
56
56
  });
57
57
  var ThankYou = function (_a) {
58
- var title = _a.title, description = _a.description, showEmailProviders = _a.showEmailProviders, onSuccess = _a.onSuccess, successTitle = _a.successTitle, loading = _a.loading, error = _a.error, enableBack = _a.enableBack, onBack = _a.onBack, sx = _a.sx;
58
+ var title = _a.title, description = _a.description, showEmailProviders = _a.showEmailProviders, onSuccess = _a.onSuccess, successTitle = _a.successTitle, loading = _a.loading, error = _a.error, enableBack = _a.enableBack, onBack = _a.onBack;
59
59
  var t = useTranslation().t;
60
60
  var isAr = useLanguage().isAr;
61
- return (_jsxs(ContainerStyled, __assign({ sx: sx }, { children: [_jsx(IconStyled, { src: ICONS_NAMES.SUCCESS_GIF, alt: 'loading...' }), _jsxs(TitleStyled, { children: [title, " "] }), description && _jsx(DescriptionStyled, { children: description }), showEmailProviders && (_jsx(MailBoxStyled, { children: _jsx(EmailProvidersButton, { gmail: { title: t('gmail_btn_open_title'), href: 'https://mail.google.com/mail/u/0/#inbox' }, outlook: { title: t('outlook_btn_open_title'), href: 'https://outlook.live.com/mail/0/' }, apple: { title: t('apple_btn_open_title'), href: 'mailto:' }, mail: { title: t('mail_btn_open_title'), href: 'mailto:' } }) })), onSuccess && !showEmailProviders && (_jsx(MailBoxStyled, { children: _jsx(SuccessButton, __assign({ onClick: onSuccess, disableBack: true, disableNextIcon: true, disabled: loading, isAr: isAr, loading: loading, error: t(error || '') }, { children: t(successTitle || '') })) })), enableBack && (_jsx(Button, __assign({ sx: { mb: 1.5, mt: 0 }, onClick: function () { return onBack === null || onBack === void 0 ? void 0 : onBack(); }, variant: 'text' }, { children: t('back') })))] })));
61
+ return (_jsxs(ContainerStyled, { children: [_jsx(IconStyled, { src: ICONS_NAMES.SUCCESS_GIF, alt: 'loading...' }), _jsxs(TitleStyled, { children: [title, " "] }), description && _jsx(DescriptionStyled, { children: description }), showEmailProviders && (_jsx(MailBoxStyled, { children: _jsx(EmailProvidersButton, { gmail: { title: t('gmail_btn_open_title'), href: 'https://mail.google.com/mail/u/0/#inbox' }, outlook: { title: t('outlook_btn_open_title'), href: 'https://outlook.live.com/mail/0/' }, apple: { title: t('apple_btn_open_title'), href: 'mailto:' }, mail: { title: t('mail_btn_open_title'), href: 'mailto:' } }) })), onSuccess && !showEmailProviders && (_jsx(MailBoxStyled, { children: _jsx(SuccessButton, __assign({ onClick: onSuccess, disableBack: true, disableNextIcon: true, disabled: loading, isAr: isAr, loading: loading, error: t(error || '') }, { children: t(successTitle || '') })) })), enableBack && (_jsx(Button, __assign({ sx: { mb: 1.5, mt: 0 }, onClick: function () { return onBack === null || onBack === void 0 ? void 0 : onBack(); }, variant: 'text' }, { children: t('back') })))] }));
62
62
  };
63
63
  export default React.memo(ThankYou);
@@ -48,7 +48,7 @@ export var useAppConfig = function (_a) {
48
48
  if (!disableSettingFetching && !configToken)
49
49
  removeRequestHeaders();
50
50
  checkDomain();
51
- setBaseUrl(publicKey, rest.businessCountryCode);
51
+ setBaseUrl(publicKey, rest.region);
52
52
  setAppConfig();
53
53
  if (typeof boardMaturity === 'boolean')
54
54
  dispatch(handelBoardMaturity(boardMaturity));
@@ -13,5 +13,4 @@ export declare const useAppDispatch: () => import("redux-thunk").ThunkDispatch<{
13
13
  auth: import("../features/app/auth/authStore").AuthState;
14
14
  board: import("../features/app/board/boardStore").BoardState;
15
15
  kyc: import("../features/app/kyc/kycStore").KYCDataState;
16
- terminal: import("../features/app/terminal/terminalStore").TerminalDataState;
17
16
  }, undefined, import("redux").AnyAction> & import("redux").Dispatch<import("redux").AnyAction>;
package/build/index.d.ts CHANGED
@@ -13,6 +13,5 @@ import { EntityElement, EntityLibProps } from './features/entity';
13
13
  import { BrandElement, BrandLibProps } from './features/brand';
14
14
  import { BoardLibProps, BoardElement } from './features/board';
15
15
  import { KYCLibProps, KYCElement } from './features/kyc';
16
- import { TerminalLibProps, TerminalElement } from './features/terminal';
17
- export type { ConnectLibProps, ConnectExpressLibProps, AuthLibProps, BusinessLibProps, PasswordLibProps, IndividualLibProps, BankLibProps, TaxLibProps, EntityLibProps, BrandLibProps, SignInLibProps, BoardLibProps, KYCLibProps, TerminalLibProps };
18
- export { ConnectElement, ConnectExpressElement, AuthElement, BusinessElement, PasswordElement, IndividualElement, BankElement, TaxElement, EntityElement, BrandElement, SignInElement, BoardElement, KYCElement, TerminalElement };
16
+ export type { ConnectLibProps, ConnectExpressLibProps, AuthLibProps, BusinessLibProps, PasswordLibProps, IndividualLibProps, BankLibProps, TaxLibProps, EntityLibProps, BrandLibProps, SignInLibProps, BoardLibProps, KYCLibProps };
17
+ export { ConnectElement, ConnectExpressElement, AuthElement, BusinessElement, PasswordElement, IndividualElement, BankElement, TaxElement, EntityElement, BrandElement, SignInElement, BoardElement, KYCElement };
package/build/index.js CHANGED
@@ -13,8 +13,7 @@ import { EntityElement, renderEntityLib } from './features/entity';
13
13
  import { BrandElement, renderBrandLib } from './features/brand';
14
14
  import { BoardElement, renderBoardLib } from './features/board';
15
15
  import { KYCElement, renderKYCLib } from './features/kyc';
16
- import { TerminalElement, renderTerminalLib } from './features/terminal';
17
- export { ConnectElement, ConnectExpressElement, AuthElement, BusinessElement, PasswordElement, IndividualElement, BankElement, TaxElement, EntityElement, BrandElement, SignInElement, BoardElement, KYCElement, TerminalElement };
16
+ export { ConnectElement, ConnectExpressElement, AuthElement, BusinessElement, PasswordElement, IndividualElement, BankElement, TaxElement, EntityElement, BrandElement, SignInElement, BoardElement, KYCElement };
18
17
  window['TapAuth'] = {
19
18
  renderConnectLib: renderConnectLib,
20
19
  renderConnectExpressLib: renderConnectExpressLib,
@@ -28,7 +27,6 @@ window['TapAuth'] = {
28
27
  renderBrandLib: renderBrandLib,
29
28
  renderSignInLib: renderSignInLib,
30
29
  renderBoardLib: renderBoardLib,
31
- renderKYCLib: renderKYCLib,
32
- renderTerminalLib: renderTerminalLib
30
+ renderKYCLib: renderKYCLib
33
31
  };
34
32
  console.log("TapAuth version: ".concat(require('../package.json').version));
@@ -48,18 +48,6 @@ export var lightPalette = {
48
48
  main: '#808592',
49
49
  light: '#EAECEF',
50
50
  dark: '#3B4152'
51
- },
52
- components: {
53
- deviceCard: {
54
- title: '#20232B',
55
- statusText: '#1F222A80',
56
- statusBackground: ' #F0F0F0',
57
- deviceInfoBackground: 'linear-gradient(127.37deg, rgba(255, 255, 255, 0.6) 59.07%, rgba(255, 255, 255, 0.444) 100.12%);',
58
- border: '#e8ecf2'
59
- },
60
- toastDeviceSelectorDropdown: {
61
- border: '#f2f2f2'
62
- }
63
51
  }
64
52
  };
65
53
  export var darkPalette = {
@@ -5,7 +5,6 @@ export var typography = {
5
5
  fontWeightLight: 300,
6
6
  fontWeightRegular: 400,
7
7
  fontWeightMedium: 500,
8
- fontWeightSemiBold: 600,
9
8
  fontWeightBold: 700,
10
9
  allVariants: {
11
10
  fontFamily: '"Lato", "Tajawal", "Roboto"',
@@ -20,7 +19,6 @@ export var typography = {
20
19
  h2: { fontSize: '3rem' },
21
20
  h3: { fontSize: '2.5rem' },
22
21
  h4: { fontSize: '2rem' },
23
- h4_small: { fontSize: '1.625rem' },
24
22
  h5: { fontSize: '1.5rem' },
25
23
  h6: { fontSize: '1.25rem' },
26
24
  subtitle1: { fontSize: '1.125rem' },
@@ -28,8 +26,6 @@ export var typography = {
28
26
  body1: { fontSize: '1rem' },
29
27
  body2: { fontSize: '0.875rem' },
30
28
  button: { fontSize: '0.875rem' },
31
- button_small: { fontSize: '0.813rem' },
32
29
  caption: { fontSize: '0.75rem' },
33
- caption_small: { fontSize: '0.625rem' },
34
30
  overline: { fontSize: '0.5rem' }
35
31
  };
@@ -1,6 +1,6 @@
1
1
  export declare const sleep: (milliseconds?: number) => Promise<unknown>;
2
2
  export declare const dangerousMessage: (message: string, callBack?: Function) => void;
3
- export declare const setBaseUrl: (publicKey: string, countryCode?: string) => void;
3
+ export declare const setBaseUrl: (publicKey: string, region?: string) => void;
4
4
  export declare const updateLocationUrlWithCountry: (countryIso2: string) => void;
5
5
  export declare const openConnect: (pk: string, countryCode?: string) => void;
6
6
  export declare function getMetaData(): Record<string, string> | undefined;
@@ -1,7 +1,7 @@
1
1
  import { axiosInstance } from '../api';
2
- import { ENDPOINT_PATHS, CONNECT_DEV_URL, CONNECT_PROD_URL } from '../constants';
2
+ import { ENDPOINT_PATHS, CONNECT_SANDBOX_URL, CONNECT_PROD_URL } from '../constants';
3
3
  import { objectHasValues } from './object';
4
- import { isSA } from './string';
4
+ import { isDisasterRecoveryEnv, isSA } from './string';
5
5
  export var sleep = function (milliseconds) {
6
6
  if (milliseconds === void 0) { milliseconds = 1000; }
7
7
  return new Promise(function (resolve) { return setTimeout(resolve, milliseconds); });
@@ -12,14 +12,20 @@ export var dangerousMessage = function (message, callBack) {
12
12
  }
13
13
  callBack === null || callBack === void 0 ? void 0 : callBack({ message: message });
14
14
  };
15
- export var setBaseUrl = function (publicKey, countryCode) {
16
- if (countryCode === void 0) { countryCode = ''; }
15
+ export var setBaseUrl = function (publicKey, region) {
16
+ if (region === void 0) { region = ''; }
17
17
  var isProd = publicKey.includes('pk_live');
18
- if (isProd) {
19
- axiosInstance.defaults.baseURL = isSA(countryCode) ? ENDPOINT_PATHS.PRODUCTION_BASE_URL_SA : ENDPOINT_PATHS.PRODUCTION_BASE_URL;
18
+ var _a = region.split('-'), country = _a[0], envType = _a[1];
19
+ if (!isProd) {
20
+ axiosInstance.defaults.baseURL = ENDPOINT_PATHS.SANDBOX_BASE_URL;
20
21
  return;
21
22
  }
22
- axiosInstance.defaults.baseURL = ENDPOINT_PATHS.DEV_BASE_URL;
23
+ if (isSA(country)) {
24
+ axiosInstance.defaults.baseURL = isDisasterRecoveryEnv(envType) ? ENDPOINT_PATHS.PRODUCTION_BASE_URL_SA_DR : ENDPOINT_PATHS.PRODUCTION_BASE_URL_SA;
25
+ }
26
+ else {
27
+ axiosInstance.defaults.baseURL = ENDPOINT_PATHS.PRODUCTION_BASE_URL;
28
+ }
23
29
  };
24
30
  export var updateLocationUrlWithCountry = function (countryIso2) {
25
31
  var country = countryIso2.toLowerCase();
@@ -38,7 +44,7 @@ export var updateLocationUrlWithCountry = function (countryIso2) {
38
44
  window.history.replaceState({}, '', newUrl);
39
45
  };
40
46
  export var openConnect = function (pk, countryCode) {
41
- var newUrl = new URL(pk.includes('pk_live') ? CONNECT_PROD_URL : CONNECT_DEV_URL);
47
+ var newUrl = new URL(pk.includes('pk_live') ? CONNECT_PROD_URL : CONNECT_SANDBOX_URL);
42
48
  if (countryCode) {
43
49
  newUrl.pathname = "/".concat(countryCode.toLowerCase());
44
50
  }