@tap-payments/auth-jsconnect 2.12.7-development → 2.12.8-development
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +60 -10
- package/build/features/kyc/screens/Terms/Terms.js +6 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -20,12 +20,17 @@ yarn add @tap-payments/auth-jsconnect
|
|
|
20
20
|
|
|
21
21
|
## Features
|
|
22
22
|
|
|
23
|
-
- [Connect](#Connect)
|
|
24
|
-
- [
|
|
25
|
-
- [
|
|
26
|
-
- [Individual](#Individual)
|
|
27
|
-
- [
|
|
28
|
-
- [
|
|
23
|
+
- [Connect](#Connect) - Create a new account with Tap Payments
|
|
24
|
+
- [ConnectExpress](#ConnectExpress) - Simplified connect flow
|
|
25
|
+
- [Business](#Business) - Business entity onboarding and verification
|
|
26
|
+
- [Individual](#Individual) - Individual entity onboarding and verification
|
|
27
|
+
- [Entity](#Entity) - Entity management and verification
|
|
28
|
+
- [Password](#Password) - Password management and recovery
|
|
29
|
+
- [Bank](#Bank) - Bank account management
|
|
30
|
+
- [Tax](#Tax) - Tax information management
|
|
31
|
+
- [Terminal](#Terminal) - Terminal kit for point-of-sale operations
|
|
32
|
+
- [Auth](#Auth) - Authentication module
|
|
33
|
+
- [KYC](#KYC) - Know Your Customer verification
|
|
29
34
|
|
|
30
35
|
## Examples
|
|
31
36
|
|
|
@@ -135,17 +140,48 @@ const App = () => {
|
|
|
135
140
|
```
|
|
136
141
|
|
|
137
142
|
## Connect
|
|
138
|
-
- Help
|
|
143
|
+
- Help merchants create an account with Tap Payments
|
|
139
144
|
|
|
140
|
-
##
|
|
145
|
+
## ConnectExpress
|
|
146
|
+
- Streamlined onboarding flow with simplified user experience
|
|
141
147
|
|
|
142
|
-
##
|
|
148
|
+
## Business
|
|
149
|
+
- Business entity registration and verification
|
|
150
|
+
- License number validation
|
|
151
|
+
- Support for creating new sessions after expiry
|
|
143
152
|
|
|
144
153
|
## Individual
|
|
154
|
+
- Individual entity registration and verification
|
|
155
|
+
- Arabic name validation (English names only accepted)
|
|
156
|
+
- Support for creating new sessions after expiry
|
|
157
|
+
|
|
158
|
+
## Entity
|
|
159
|
+
- Entity information management
|
|
160
|
+
- Frontend-editable fields even when non-editable from backend
|
|
161
|
+
- Entity verification workflows
|
|
162
|
+
|
|
163
|
+
## Password
|
|
164
|
+
- Password management and recovery
|
|
165
|
+
- Session expiry handling with new session creation support
|
|
145
166
|
|
|
146
167
|
## Bank
|
|
168
|
+
- Bank account information management and verification
|
|
147
169
|
|
|
148
170
|
## Tax
|
|
171
|
+
- Tax identification and information management
|
|
172
|
+
- Support for creating new sessions after expiry
|
|
173
|
+
- UNN Collection logic improvements
|
|
174
|
+
|
|
175
|
+
## Terminal
|
|
176
|
+
- Point-of-sale terminal operations
|
|
177
|
+
- Session expiry management with new session creation support
|
|
178
|
+
- Hotfix for improved session handling
|
|
179
|
+
|
|
180
|
+
## Auth
|
|
181
|
+
- Core authentication module for the library
|
|
182
|
+
|
|
183
|
+
## KYC
|
|
184
|
+
- Know Your Customer verification processes
|
|
149
185
|
|
|
150
186
|
```
|
|
151
187
|
|
|
@@ -164,4 +200,18 @@ const App = () => {
|
|
|
164
200
|
| onFlowCompleted `required` - `function` | callback function will called after completing the flow |
|
|
165
201
|
| onReady `required` - `function` | callback function will call after loading library configuration |
|
|
166
202
|
| onStepError `required` - `function` | callback function will call in case if any error happened in the screen |
|
|
167
|
-
|
|
|
203
|
+
| onStepCompleted `optional` - `function` | callback function will call after completing each step |
|
|
204
|
+
| onStepStarted `required` - `function` | callback function will call in the beginning of each step |
|
|
205
|
+
|
|
206
|
+
## Branch Information
|
|
207
|
+
|
|
208
|
+
This repository maintains multiple branches for different environments and stages:
|
|
209
|
+
|
|
210
|
+
| Branch | Purpose | Environment |
|
|
211
|
+
| ------------- | ------------------------------ | ----------- |
|
|
212
|
+
| `main` | Production releases | Production |
|
|
213
|
+
| `beta` | Beta features and testing | Beta |
|
|
214
|
+
| `sandbox` | Sandbox environment testing | Sandbox |
|
|
215
|
+
| `development` | Development features and fixes | Development |
|
|
216
|
+
|
|
217
|
+
**Workflow**: `development` → `sandbox` → `beta` → `main` (production)
|
|
@@ -42,14 +42,15 @@ var redirect = function (link) {
|
|
|
42
42
|
window.open(link, '_blank');
|
|
43
43
|
};
|
|
44
44
|
export var Terms = function () {
|
|
45
|
-
var _a, _b, _c;
|
|
45
|
+
var _a, _b, _c, _d, _e;
|
|
46
46
|
var st = useSanitizedTranslation();
|
|
47
47
|
var isAr = useLanguage().isAr;
|
|
48
48
|
var dispatch = useAppDispatch();
|
|
49
49
|
var settingsData = useAppSelector(settingsSelector).data;
|
|
50
|
-
var
|
|
51
|
-
var
|
|
52
|
-
var
|
|
50
|
+
var _f = useAppSelector(kycSelector), loading = _f.loading, error = _f.error, data = _f.data;
|
|
51
|
+
var hasUsers = (_b = (_a = data.responseData) === null || _a === void 0 ? void 0 : _a.userList) === null || _b === void 0 ? void 0 : _b.length;
|
|
52
|
+
var hasOneUserOnly = ((_d = (_c = data.responseData) === null || _c === void 0 ? void 0 : _c.userList) === null || _d === void 0 ? void 0 : _d.length) === 1;
|
|
53
|
+
var user = hasOneUserOnly ? (_e = data.responseData) === null || _e === void 0 ? void 0 : _e.userList[0] : undefined;
|
|
53
54
|
var idNumber = user ? maskIDNumber(user.identification.id) : '';
|
|
54
55
|
var countryCode = settingsData.businessCountry.iso2.toLowerCase();
|
|
55
56
|
var termsAndConditionsLink = getWebsiteLink(isAr, countryCode, EXTERNAL_LINKS.TERMS_CONDITIONS);
|
|
@@ -82,6 +83,6 @@ export var Terms = function () {
|
|
|
82
83
|
return st('continue');
|
|
83
84
|
return isSACountry ? st('approve_with_nafath_app') : st('approve_with_paci_app');
|
|
84
85
|
};
|
|
85
|
-
return (_jsxs(ScreenContainer, { children: [_jsx(Header, { idNumber: idNumber }), _jsx(BoxStyled, __assign({ onClick: function () { return redirect(termsAndConditionsLink); } }, { children: st('kyc_terms_conditions') })), _jsx(BoxStyled, __assign({ onClick: function () { return redirect(termsAndConditionsLink); } }, { children: st('kyc_refund_policy') })), _jsx(BoxStyled, __assign({ onClick: function () { return redirect(termsAndConditionsLink); } }, { children: st('kyc_dispute_policy') })), _jsx(BoxStyled, __assign({ onClick: function () { return redirect(privacyPolicyLink); }, sx: { mb: error ? 3 : 0 } }, { children: st('kyc_privacy_policy') })), _jsx(Button, __assign({ disabled: isOtherThanKWOrSACountry, sx: { mt: 3 }, disableBack: true, isAr: isAr, loading: loading, error: st(error || ''), onClick: onNext }, { children: getNextButtonTitle() }))] }));
|
|
86
|
+
return (_jsxs(ScreenContainer, { children: [_jsx(Header, { idNumber: idNumber }), _jsx(BoxStyled, __assign({ onClick: function () { return redirect(termsAndConditionsLink); } }, { children: st('kyc_terms_conditions') })), _jsx(BoxStyled, __assign({ onClick: function () { return redirect(termsAndConditionsLink); } }, { children: st('kyc_refund_policy') })), _jsx(BoxStyled, __assign({ onClick: function () { return redirect(termsAndConditionsLink); } }, { children: st('kyc_dispute_policy') })), _jsx(BoxStyled, __assign({ onClick: function () { return redirect(privacyPolicyLink); }, sx: { mb: error ? 3 : 0 } }, { children: st('kyc_privacy_policy') })), _jsx(Button, __assign({ disabled: isOtherThanKWOrSACountry ? true : !hasUsers, sx: { mt: 3 }, disableBack: true, isAr: isAr, loading: loading, error: st(error || ''), onClick: onNext }, { children: getNextButtonTitle() }))] }));
|
|
86
87
|
};
|
|
87
88
|
export default memo(Terms);
|