@tap-payments/auth-jsconnect 2.8.44-test → 2.8.45-beta

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 (178) hide show
  1. package/build/@types/form.d.ts +0 -1
  2. package/build/@types/redux.d.ts +0 -1
  3. package/build/api/axios.js +1 -2
  4. package/build/api/entity.d.ts +2 -2
  5. package/build/api/entity.js +4 -12
  6. package/build/api/index.d.ts +2 -2
  7. package/build/constants/api.d.ts +1 -0
  8. package/build/constants/api.js +2 -0
  9. package/build/constants/app.d.ts +2 -0
  10. package/build/constants/app.js +11 -3
  11. package/build/features/app/bank/bankStore.d.ts +18 -13
  12. package/build/features/app/bank/bankStore.js +161 -173
  13. package/build/features/app/board/boardStore.js +30 -52
  14. package/build/features/app/brand/brandStore.d.ts +33 -16
  15. package/build/features/app/brand/brandStore.js +204 -173
  16. package/build/features/app/business/businessStore.d.ts +5 -0
  17. package/build/features/app/business/businessStore.js +86 -69
  18. package/build/features/app/connectExpress/connectExpressStore.js +10 -18
  19. package/build/features/app/entity/entityStore.d.ts +35 -15
  20. package/build/features/app/entity/entityStore.js +228 -159
  21. package/build/features/app/individual/individualStore.d.ts +37 -21
  22. package/build/features/app/individual/individualStore.js +265 -253
  23. package/build/features/app/password/passwordStore.d.ts +23 -40
  24. package/build/features/app/password/passwordStore.js +233 -226
  25. package/build/features/app/tax/taxStore.d.ts +7 -13
  26. package/build/features/app/tax/taxStore.js +147 -167
  27. package/build/features/bank/Bank.d.ts +0 -1
  28. package/build/features/bank/Bank.js +4 -7
  29. package/build/features/bank/screens/BankDetails/BankDetails.js +4 -12
  30. package/build/features/bank/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +2 -2
  31. package/build/features/bank/screens/Verify/Verify.js +5 -5
  32. package/build/features/board/Board.js +4 -8
  33. package/build/features/board/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +4 -3
  34. package/build/features/brand/Brand.d.ts +0 -1
  35. package/build/features/brand/Brand.js +4 -7
  36. package/build/features/brand/screens/BrandActivities/BrandActivities.js +1 -1
  37. package/build/features/brand/screens/BrandActivities/ExpectedSalesRange.js +3 -6
  38. package/build/features/brand/screens/BrandActivities/RefundPolicy.js +1 -1
  39. package/build/features/brand/screens/BrandActivities/TAC.js +1 -1
  40. package/build/features/brand/screens/BrandActivities/TransactionPolicy.js +1 -1
  41. package/build/features/brand/screens/BrandInfo/BrandInfo.js +1 -1
  42. package/build/features/brand/screens/BrandSegmentInfo/BrandSegmentInfo.js +1 -1
  43. package/build/features/brand/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +2 -2
  44. package/build/features/brand/screens/Verify/Verify.js +1 -1
  45. package/build/features/business/Business.js +4 -9
  46. package/build/features/business/screens/Activities/Activities.js +1 -1
  47. package/build/features/business/screens/BusinessType/BusinessType.js +1 -1
  48. package/build/features/business/screens/CivilID/CivilID.js +1 -1
  49. package/build/features/business/screens/Customers/Customers.js +1 -1
  50. package/build/features/business/screens/Customers/ExpectedSalesRange.js +3 -6
  51. package/build/features/business/screens/IDBOD/IDBOD.js +1 -1
  52. package/build/features/business/screens/OTP/OTP.js +1 -1
  53. package/build/features/business/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +2 -2
  54. package/build/features/business/screens/Verify/Verify.js +1 -1
  55. package/build/features/connect/screens/BrandSegment/BrandSegment.js +1 -1
  56. package/build/features/connect/screens/BusinessCountry/BusinessCountry.js +1 -2
  57. package/build/features/connect/screens/CivilID/CivilID.js +1 -1
  58. package/build/features/connect/screens/Individual/Email.js +1 -3
  59. package/build/features/connect/screens/Individual/Individual.js +1 -1
  60. package/build/features/connect/screens/Merchant/BrandList.js +3 -3
  61. package/build/features/connect/screens/Merchant/Merchant.js +1 -1
  62. package/build/features/connect/screens/Merchant/SalesChannels.js +1 -1
  63. package/build/features/connect/screens/Mobile/Mobile.js +1 -1
  64. package/build/features/connect/screens/NID/NID.js +1 -1
  65. package/build/features/connect/screens/OperatorError/OperatorError.js +1 -1
  66. package/build/features/connectExpress/screens/AuthenticationList/AuthenticationList.js +2 -5
  67. package/build/features/connectExpress/screens/AuthenticationList/EntityList.js +1 -6
  68. package/build/features/connectExpress/screens/AuthenticationList/validation.d.ts +0 -3
  69. package/build/features/connectExpress/screens/AuthenticationList/validation.js +0 -10
  70. package/build/features/connectExpress/screens/CivilID/CivilID.js +1 -1
  71. package/build/features/connectExpress/screens/CivilIDMissed/CivilID.js +1 -1
  72. package/build/features/connectExpress/screens/CollectBusinessInfo/CollectBusinessInfo.js +1 -1
  73. package/build/features/connectExpress/screens/CollectIndividualInfo/CollectIndividualInfo.js +1 -1
  74. package/build/features/connectExpress/screens/CollectIndividualInfo/Email.js +1 -3
  75. package/build/features/connectExpress/screens/Mobile/Mobile.js +1 -1
  76. package/build/features/connectExpress/screens/NID/NID.js +1 -1
  77. package/build/features/connectExpress/screens/NIDMissed/NID.js +1 -1
  78. package/build/features/connectExpress/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +2 -2
  79. package/build/features/entity/Entity.d.ts +0 -1
  80. package/build/features/entity/Entity.js +4 -7
  81. package/build/features/entity/screens/EntityCapital/CapitalPaid.js +4 -8
  82. package/build/features/entity/screens/EntityCapital/CapitalShareValue.js +4 -8
  83. package/build/features/entity/screens/EntityCapital/EntityCapital.js +1 -1
  84. package/build/features/entity/screens/EntityName/EntityName.js +1 -1
  85. package/build/features/entity/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +2 -2
  86. package/build/features/entity/screens/Verify/Verify.js +1 -1
  87. package/build/features/featuresScreens.js +7 -62
  88. package/build/features/individual/Individual.d.ts +0 -1
  89. package/build/features/individual/Individual.js +4 -7
  90. package/build/features/individual/screens/AdditionalIndividualInfo/AdditionalIndividualInfo.js +7 -14
  91. package/build/features/individual/screens/AdditionalIndividualInfo/MonthlyIncome.js +2 -5
  92. package/build/features/individual/screens/AdditionalIndividualInfo/ShareValue.js +3 -8
  93. package/build/features/individual/screens/AdditionalIndividualInfo/validation.d.ts +1 -4
  94. package/build/features/individual/screens/AdditionalIndividualInfo/validation.js +2 -3
  95. package/build/features/individual/screens/IndividualList/Email.js +2 -3
  96. package/build/features/individual/screens/IndividualList/IndividualList.js +5 -11
  97. package/build/features/individual/screens/IndividualList/UserList.js +9 -13
  98. package/build/features/individual/screens/IndividualPersonalInfo/Email.js +2 -4
  99. package/build/features/individual/screens/IndividualPersonalInfo/IndividualPersonalInfo.js +3 -4
  100. package/build/features/individual/screens/IndividualPhoneInfo/PhoneInfo.js +1 -1
  101. package/build/features/individual/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +2 -2
  102. package/build/features/individual/screens/Verify/Verify.js +1 -1
  103. package/build/features/password/Password.d.ts +0 -1
  104. package/build/features/password/Password.js +28 -75
  105. package/build/features/password/screens/CreatePassword/CreatePassword.js +4 -8
  106. package/build/features/password/screens/OTP/OTP.js +1 -1
  107. package/build/features/password/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +2 -2
  108. package/build/features/password/screens/Verify/Verify.js +5 -5
  109. package/build/features/shared/Button/FlowsButtons.js +3 -4
  110. package/build/features/shared/Containers/FeatureContainer.d.ts +0 -1
  111. package/build/features/shared/Containers/FeatureContainer.js +3 -3
  112. package/build/features/shared/SuccessFlowButtons/SuccessFlowButtons.d.ts +1 -5
  113. package/build/features/shared/SuccessFlowButtons/SuccessFlowButtons.js +3 -3
  114. package/build/features/signIn/SignIn.js +3 -12
  115. package/build/features/tax/Tax.d.ts +0 -1
  116. package/build/features/tax/Tax.js +4 -7
  117. package/build/features/tax/screens/SuccessWithFlowButtons/SuccessWithFlowButtons.js +2 -2
  118. package/build/features/tax/screens/TaxDetails/TaxDetails.js +2 -7
  119. package/build/features/tax/screens/Verify/Verify.js +5 -5
  120. package/build/hooks/index.d.ts +0 -1
  121. package/build/hooks/index.js +0 -1
  122. package/build/hooks/useVerifyToken.d.ts +2 -5
  123. package/build/hooks/useVerifyToken.js +5 -10
  124. package/build/utils/common.js +4 -4
  125. package/build/utils/locale.js +1 -2
  126. package/build/utils/string.d.ts +2 -5
  127. package/build/utils/string.js +5 -34
  128. package/package.json +2 -2
  129. package/build/features/bank/screens/OperatorError/OperatorError.d.ts +0 -5
  130. package/build/features/bank/screens/OperatorError/OperatorError.js +0 -9
  131. package/build/features/bank/screens/OperatorError/index.d.ts +0 -3
  132. package/build/features/bank/screens/OperatorError/index.js +0 -2
  133. package/build/features/board/screens/OperatorError/OperatorError.d.ts +0 -5
  134. package/build/features/board/screens/OperatorError/OperatorError.js +0 -9
  135. package/build/features/board/screens/OperatorError/index.d.ts +0 -3
  136. package/build/features/board/screens/OperatorError/index.js +0 -2
  137. package/build/features/brand/screens/OperatorError/OperatorError.d.ts +0 -5
  138. package/build/features/brand/screens/OperatorError/OperatorError.js +0 -9
  139. package/build/features/brand/screens/OperatorError/index.d.ts +0 -3
  140. package/build/features/brand/screens/OperatorError/index.js +0 -2
  141. package/build/features/business/screens/OperatorError/OperatorError.d.ts +0 -5
  142. package/build/features/business/screens/OperatorError/OperatorError.js +0 -9
  143. package/build/features/business/screens/OperatorError/index.d.ts +0 -3
  144. package/build/features/business/screens/OperatorError/index.js +0 -2
  145. package/build/features/connectExpress/screens/AuthenticationList/EntityLicenseType.d.ts +0 -31
  146. package/build/features/connectExpress/screens/AuthenticationList/EntityLicenseType.js +0 -90
  147. package/build/features/connectExpress/screens/OperatorError/OperatorError.d.ts +0 -5
  148. package/build/features/connectExpress/screens/OperatorError/OperatorError.js +0 -9
  149. package/build/features/connectExpress/screens/OperatorError/index.d.ts +0 -3
  150. package/build/features/connectExpress/screens/OperatorError/index.js +0 -2
  151. package/build/features/entity/screens/OperatorError/OperatorError.d.ts +0 -5
  152. package/build/features/entity/screens/OperatorError/OperatorError.js +0 -9
  153. package/build/features/entity/screens/OperatorError/index.d.ts +0 -3
  154. package/build/features/entity/screens/OperatorError/index.js +0 -2
  155. package/build/features/individual/screens/AdditionalIndividualInfo/IsAuthorizedSwitch.d.ts +0 -36
  156. package/build/features/individual/screens/AdditionalIndividualInfo/IsAuthorizedSwitch.js +0 -76
  157. package/build/features/individual/screens/OperatorError/OperatorError.d.ts +0 -5
  158. package/build/features/individual/screens/OperatorError/OperatorError.js +0 -9
  159. package/build/features/individual/screens/OperatorError/index.d.ts +0 -3
  160. package/build/features/individual/screens/OperatorError/index.js +0 -2
  161. package/build/features/password/screens/OperatorError/OperatorError.d.ts +0 -5
  162. package/build/features/password/screens/OperatorError/OperatorError.js +0 -9
  163. package/build/features/password/screens/OperatorError/index.d.ts +0 -3
  164. package/build/features/password/screens/OperatorError/index.js +0 -2
  165. package/build/features/password/screens/PrepareDataLoading/PrepareDataLoading.d.ts +0 -4
  166. package/build/features/password/screens/PrepareDataLoading/PrepareDataLoading.js +0 -10
  167. package/build/features/password/screens/PrepareDataLoading/index.d.ts +0 -2
  168. package/build/features/password/screens/PrepareDataLoading/index.js +0 -2
  169. package/build/features/signIn/screens/OperatorError/OperatorError.d.ts +0 -5
  170. package/build/features/signIn/screens/OperatorError/OperatorError.js +0 -9
  171. package/build/features/signIn/screens/OperatorError/index.d.ts +0 -3
  172. package/build/features/signIn/screens/OperatorError/index.js +0 -2
  173. package/build/features/tax/screens/OperatorError/OperatorError.d.ts +0 -5
  174. package/build/features/tax/screens/OperatorError/OperatorError.js +0 -9
  175. package/build/features/tax/screens/OperatorError/index.d.ts +0 -3
  176. package/build/features/tax/screens/OperatorError/index.js +0 -2
  177. package/build/hooks/useFormDirtyCheck.d.ts +0 -6
  178. package/build/hooks/useFormDirtyCheck.js +0 -29
@@ -46,9 +46,9 @@ var FormStyled = styled(Form)(function () { return ({
46
46
  flexDirection: 'column'
47
47
  }); });
48
48
  var VerifyNumber = function (_a) {
49
- var _b, _c;
49
+ var _b, _c, _d;
50
50
  var dispatch = useAppDispatch();
51
- var _d = useAppSelector(bankSelector), data = _d.data, loading = _d.loading, error = _d.error;
51
+ var _e = useAppSelector(bankSelector), data = _e.data, loading = _e.loading, error = _e.error;
52
52
  var methods = useForm({
53
53
  resolver: yupResolver(OTPValidation),
54
54
  defaultValues: data.otpData,
@@ -56,8 +56,8 @@ var VerifyNumber = function (_a) {
56
56
  });
57
57
  var t = useTranslation().t;
58
58
  var isAr = useLanguage().isAr;
59
- var _e = React.useState(false), resendLoading = _e[0], setResendLoading = _e[1];
60
- var phone = (_c = (_b = data.verify.responseBody) === null || _b === void 0 ? void 0 : _b.verification_by) === null || _c === void 0 ? void 0 : _c.sent_to;
59
+ var _f = React.useState(false), resendLoading = _f[0], setResendLoading = _f[1];
60
+ var phone = (_d = (_c = (_b = data.verify.responseBody) === null || _b === void 0 ? void 0 : _b.contact) === null || _c === void 0 ? void 0 : _c.phone) === null || _d === void 0 ? void 0 : _d.number;
61
61
  React.useEffect(function () {
62
62
  if (error && methods.formState.isValid && phone)
63
63
  dispatch(clearError());
@@ -68,7 +68,7 @@ var VerifyNumber = function (_a) {
68
68
  var onSubmit = function (formData) {
69
69
  dispatch(verifyBankLeadOTP(deepCopy(formData)));
70
70
  };
71
- var disabled = !methods.formState.isValid || !phone || resendLoading;
71
+ var disabled = !methods.formState.isValid || !!error || !phone || resendLoading;
72
72
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(OTPTitleContainerStyled, { children: _jsxs(OTPTitleStyled, { children: [loading ? t('ide_otp_waiting_title') : t('ide_opt_sent_title'), !loading && phone && _jsx("span", __assign({ dir: 'ltr' }, { children: "".concat(maskPhone(phone || '')) }))] }) }), _jsx(OTPInput, { loading: resendLoading, setLoading: setResendLoading }), _jsx(Button, __assign({ disableBack: true, disabled: disabled, isAr: isAr, loading: loading, error: t(error || '') }, { children: t('next') }))] })) })) }));
73
73
  };
74
74
  export default React.memo(VerifyNumber);
@@ -51,15 +51,11 @@ var Board = memo(function (_a) {
51
51
  });
52
52
  }, []);
53
53
  React.useEffect(function () {
54
- if (settingLoading || !props.open)
55
- return;
56
- if (!data.isValidOperator) {
57
- dispatch(handleCurrentActiveScreen('BOARD_OPERATOR_ERROR_STEP'));
58
- return;
54
+ if (data.isValidOperator && props.open && !settingLoading) {
55
+ dispatch(createVerifyTokenBy(boardId));
56
+ if (props.mode === 'content')
57
+ dispatch(handleCurrentActiveScreen('BOARD_SUCCESS_FLOWS_BUTTONS_STEP'));
59
58
  }
60
- dispatch(createVerifyTokenBy(boardId));
61
- if (props.mode === 'content')
62
- dispatch(handleCurrentActiveScreen('BOARD_SUCCESS_FLOWS_BUTTONS_STEP'));
63
59
  }, [data.isValidOperator, settingLoading]);
64
60
  var initialLoading = settingLoading || customLoading;
65
61
  return (_jsx(ThemeProvider, __assign({ theme: theme }, { children: _jsx(Background, __assign({ mode: props.mode, open: open, isTapOrigin: isTapOrigin, loading: initialLoading }, { children: _jsx(AnimationFlow, __assign({ pointerEvents: loading ? 'none' : 'auto', isTapOrigin: isTapOrigin, loading: initialLoading, error: error, open: open, breakpoint: 'sm', screenId: activeScreen.name, merchantInfo: merchant, isMaturityExpress: !isTapDomain(props.merchantDomain), loaderColor: loaderColor, type: props.mode === 'content' ? 'CONTENT' : undefined, dialogEdgeFormat: data.appConfig.dialogEdgeFormat }, { children: _jsx(FeatureContainer, __assign({ isMaturityExpress: !isTapDomain(props.merchantDomain) }, { children: boardFeatureScreens.map(function (_a, index) {
@@ -12,15 +12,16 @@ var __assign = (this && this.__assign) || function () {
12
12
  import { jsx as _jsx } from "react/jsx-runtime";
13
13
  import { memo } from 'react';
14
14
  import { settingsSelector } from '../../../../app/settings';
15
- import { useAppSelector } from '../../../../hooks';
15
+ import { useAppSelector, useAppDispatch } from '../../../../hooks';
16
16
  import { SCOPE_AUTH } from '../../../../constants';
17
17
  import { boardSelector } from '../../../app/board/boardStore';
18
18
  import SuccessFlowButtons from '../../../shared/SuccessFlowButtons';
19
19
  var SuccessWithFlowButtons = function () {
20
+ var dispatch = useAppDispatch();
20
21
  var _a = useAppSelector(boardSelector), data = _a.data, loading = _a.loading;
21
22
  var settingsData = useAppSelector(settingsSelector).data;
22
23
  var isScopeAuthentication = settingsData.appConfig.scope === SCOPE_AUTH;
23
- var _b = data.verify.responseBody || {}, flows = _b.flows, entity = _b.entity, brand = _b.brand, bank = _b.bank_account, merchant = _b.merchant, user = _b.user, business = _b.business, board_id = _b.board_id, board_info_id = _b.board_info_id, name = _b.name, individuals = _b.individuals, recipient = _b.recipient;
24
+ var _b = data.verify.responseBody || {}, flows = _b.flows, entity = _b.entity, brand = _b.brand, bank = _b.bank_account, merchant = _b.merchant, user = _b.user, business = _b.business, board_id = _b.board_id, board_info_id = _b.board_info_id, name = _b.name, individuals = _b.individuals;
24
25
  var onClose = function () {
25
26
  var url = settingsData.appConfig.redirectUrl;
26
27
  if (!url)
@@ -29,6 +30,6 @@ var SuccessWithFlowButtons = function () {
29
30
  newUrl.searchParams.append('action', 'close');
30
31
  window.open("".concat(newUrl), '_self', '_blank');
31
32
  };
32
- return (_jsx(SuccessFlowButtons, { flowName: data.flowName, loading: loading, bank: bank, brand: brand, entity: entity, merchant: merchant, user: __assign({ names: { en: name } }, user), business: business, boardId: board_id, boardInfoId: board_info_id, individuals: individuals, flows: flows || [], onClose: isScopeAuthentication ? onClose : undefined, recipient: recipient }));
33
+ return (_jsx(SuccessFlowButtons, { flowName: data.flowName, loading: loading, bank: bank, brand: brand, entity: entity, merchant: merchant, user: __assign({ names: { en: name } }, user), business: business, boardId: board_id, boardInfoId: board_info_id, individuals: individuals, flows: flows || [], onClose: isScopeAuthentication ? onClose : undefined }));
33
34
  };
34
35
  export default memo(SuccessWithFlowButtons);
@@ -2,7 +2,6 @@ import { LibConfig } from '../../@types';
2
2
  export interface BrandLibProps extends LibConfig {
3
3
  verifyToken?: string;
4
4
  configToken?: string;
5
- loaderColor?: string;
6
5
  }
7
6
  export declare function BrandElement(props: BrandLibProps): import("react/jsx-runtime").JSX.Element;
8
7
  export declare function renderBrandLib(config: BrandLibProps, elementId: string): {
@@ -36,7 +36,7 @@ import { brandFeatureScreens } from '../featuresScreens';
36
36
  import { brandSelector, verifyLeadToken } from '../app/brand/brandStore';
37
37
  import Background from '../shared/Background';
38
38
  var Brand = memo(function (_a) {
39
- var verifyToken = _a.verifyToken, configToken = _a.configToken, loaderColor = _a.loaderColor, props = __rest(_a, ["verifyToken", "configToken", "loaderColor"]);
39
+ var verifyToken = _a.verifyToken, configToken = _a.configToken, props = __rest(_a, ["verifyToken", "configToken"]);
40
40
  var theme = useAppTheme().theme;
41
41
  var _b = useAppSelector(settingsSelector), data = _b.data, error = _b.error, settingLoading = _b.loading;
42
42
  var _c = useAppSelector(brandSelector), customLoading = _c.customLoading, loading = _c.loading, brandError = _c.error;
@@ -54,14 +54,11 @@ var Brand = memo(function (_a) {
54
54
  loadingScreenName: 'BRAND_LOADING_DATA_STEP',
55
55
  navigation: featureScreensNavigation,
56
56
  open: open,
57
- mode: props.mode,
58
57
  internalToken: verifyToken,
59
- settingLoading: settingLoading,
60
- operatorErrorScreenName: 'BRAND_OPERATOR_ERROR_STEP',
61
- isValidOperator: data.isValidOperator
58
+ settingLoading: settingLoading
62
59
  });
63
- var initialLoading = verifyToken && props.mode !== 'content' ? settingLoading : settingLoading || customLoading;
64
- return (_jsx(ThemeProvider, __assign({ theme: theme }, { children: _jsx(Background, __assign({ mode: props.mode, open: open, isTapOrigin: isTapOrigin, loading: initialLoading }, { children: _jsx(AnimationFlow, __assign({ pointerEvents: loading ? 'none' : 'auto', isTapOrigin: isTapOrigin, loading: initialLoading, error: error, open: open, breakpoint: 'sm', screenId: activeScreen.name, merchantInfo: merchant, isMaturityExpress: isMaturityExpress, loaderColor: loaderColor, type: props.mode === 'content' ? 'CONTENT' : undefined, dialogEdgeFormat: data.appConfig.dialogEdgeFormat }, { children: _jsx(FeatureContainer, __assign({ mode: props.mode, isMaturityExpress: isMaturityExpress }, { children: brandFeatureScreens.map(function (_a, index) {
60
+ var initialLoading = verifyToken ? settingLoading : settingLoading || customLoading;
61
+ return (_jsx(ThemeProvider, __assign({ theme: theme }, { children: _jsx(Background, __assign({ open: open, isTapOrigin: isTapOrigin, loading: initialLoading }, { children: _jsx(AnimationFlow, __assign({ pointerEvents: loading ? 'none' : 'auto', isTapOrigin: isTapOrigin, loading: initialLoading, error: error, open: open, breakpoint: 'sm', screenId: activeScreen.name, merchantInfo: merchant, isMaturityExpress: isMaturityExpress, type: props.mode === 'content' ? 'CONTENT' : undefined, dialogEdgeFormat: data.appConfig.dialogEdgeFormat }, { children: _jsx(FeatureContainer, __assign({ isMaturityExpress: isMaturityExpress }, { children: brandFeatureScreens.map(function (_a, index) {
65
62
  var Element = _a.element, name = _a.name;
66
63
  var isActive = activeScreen.name === name;
67
64
  return (_jsx(Collapse, __assign({ in: isActive, timeout: { enter: 1000, exit: 800 } }, { children: _jsx(Element, {}) }), index));
@@ -105,7 +105,7 @@ var BrandActivities = function (_a) {
105
105
  };
106
106
  var t = useTranslation().t;
107
107
  var isAr = useLanguage().isAr;
108
- var disabled = !methods.formState.isValid;
108
+ var disabled = !methods.formState.isValid || !!error;
109
109
  var isActivitiesListActive = listActive === ListType.ActivitiesList;
110
110
  var isCustomerBaseListActive = listActive === ListType.CustomerBaseList;
111
111
  var isExpectedCustomerListActive = listActive === ListType.ExpectedCustomerList;
@@ -15,7 +15,7 @@ import { useTranslation } from 'react-i18next';
15
15
  import { useController, useFormContext } from 'react-hook-form';
16
16
  import Box from '@mui/material/Box';
17
17
  import { styled } from '@mui/material/styles';
18
- import { getCurrencyByCountryIso2, isExist } from '../../../../utils';
18
+ import { isExist } from '../../../../utils';
19
19
  import { useLanguage, useAppSelector, useAppDispatch } from '../../../../hooks';
20
20
  import { settingsSelector } from '../../../../app/settings';
21
21
  import SimpleList from '../../../../components/SimpleList';
@@ -68,7 +68,7 @@ var ExpectedSalesRange = function (_a) {
68
68
  var expectedSaleControl = useController({ name: 'expectedSale', control: control });
69
69
  var _g = useAppSelector(brandSelector), data = _g.data, error = _g.error;
70
70
  var settingsData = useAppSelector(settingsSelector).data;
71
- var brandActivities = data.brandActivities;
71
+ var brandActivities = data.brandActivities, currency = data.currency;
72
72
  var expectedSales = (brandActivities.responseBody || {}).expectedSales;
73
73
  var expectedSalesRangeValue = expectedSaleControl.field.value;
74
74
  var countryCode = settingsData.businessCountry;
@@ -95,9 +95,6 @@ var ExpectedSalesRange = function (_a) {
95
95
  var handleCloseSubMenu = function () {
96
96
  setSubIndex('');
97
97
  };
98
- var getCurrency = React.useMemo(function () {
99
- return t(getCurrencyByCountryIso2(countryCode.iso2));
100
- }, [countryCode.iso2]);
101
98
  React.useEffect(function () {
102
99
  if ((expectedSales === null || expectedSales === void 0 ? void 0 : expectedSales.length) > 0) {
103
100
  setExpectedSalesRangeList(expectedSales);
@@ -127,7 +124,7 @@ var ExpectedSalesRange = function (_a) {
127
124
  setSubIndex(item.id);
128
125
  }, [anchorEl, expectedSalesRangeValue]);
129
126
  return (_jsx(Collapse, __assign({ in: show }, { children: _jsxs(ScreenContainer, { children: [_jsxs(InputLabelStyled, { children: [t('expected_sales_monthly', {
130
- currency: getCurrency
127
+ currency: t(currency)
131
128
  }), _jsx(MandatoryStyled, { children: "*" })] }), _jsx(InputStyled, { readOnly: readOnly, value: isAr ? (_b = expectedSalesRangeValue === null || expectedSalesRangeValue === void 0 ? void 0 : expectedSalesRangeValue.name.ar) !== null && _b !== void 0 ? _b : '' : (_c = expectedSalesRangeValue === null || expectedSalesRangeValue === void 0 ? void 0 : expectedSalesRangeValue.name.en) !== null && _c !== void 0 ? _c : '', onClick: !!anchorEl ? handleCloseMainMenu : handleOpenMainMenu, placeholder: t('choose_expected_sales'), endAdornment: _jsx(EndAdornmentExpanded, { anchorEl: anchorEl, isVerified: isVerified }) }), _jsxs(Collapse, __assign({ in: !!anchorEl }, { children: [_jsx(Search, { onSearchValue: handleSearch }), _jsx(SimpleListStyled, { sx: { maxHeight: '350px', paddingTop: 0 }, list: expectedSalesRangeList, listItemProps: { sx: { padding: 0 } }, onSelectItem: function (item) {
132
129
  var isOnlyOneItem = !item.sub || item.sub.length === 1;
133
130
  if (isOnlyOneItem)
@@ -88,6 +88,6 @@ var RefundPolicy = function (_a) {
88
88
  return;
89
89
  refundControl.field.onChange(checked);
90
90
  };
91
- return (_jsxs(ScreenContainer, { children: [_jsxs(ContainerStyled, __assign({ readOnly: readOnly || isChecked }, { children: [_jsx(CheckboxStyled, { disabled: isChecked, disableRipple: true, disableFocusRipple: true, focusRipple: false, checked: refundChecked, onChange: handleRefundCheckedChange }), _jsxs(TextStyled, { children: [t('agree_on_refund_policy'), _jsx(LinkStyled, __assign({ href: isAr ? TAP_WEBSITE + countryCode + EXTERNAL_LINKS.REFUND_AR : TAP_WEBSITE + countryCode + EXTERNAL_LINKS.REFUND_EN, target: '_blank', underline: 'always' }, { children: t('refund_policy_compliance') }))] })] })), _jsx(CollapseStyled, __assign({ in: !!warningMessage }, { children: _jsx(Warning, __assign({ warningType: 'alert' }, { children: warningMessage && t(warningMessage) })) }))] }));
91
+ return (_jsx(Collapse, __assign({ in: !isChecked }, { children: _jsxs(ScreenContainer, { children: [_jsxs(ContainerStyled, __assign({ readOnly: readOnly }, { children: [_jsx(CheckboxStyled, { disableRipple: true, disableFocusRipple: true, focusRipple: false, checked: refundChecked, onChange: handleRefundCheckedChange }), _jsxs(TextStyled, { children: [t('agree_on_refund_policy'), _jsx(LinkStyled, __assign({ href: isAr ? TAP_WEBSITE + countryCode + EXTERNAL_LINKS.REFUND_AR : TAP_WEBSITE + countryCode + EXTERNAL_LINKS.REFUND_EN, target: '_blank', underline: 'always' }, { children: t('refund_policy_compliance') }))] })] })), _jsx(CollapseStyled, __assign({ in: !!warningMessage }, { children: _jsx(Warning, __assign({ warningType: 'alert' }, { children: warningMessage && t(warningMessage) })) }))] }) })));
92
92
  };
93
93
  export default RefundPolicy;
@@ -88,6 +88,6 @@ var TAC = function (_a) {
88
88
  return;
89
89
  tacControl.field.onChange(checked);
90
90
  };
91
- return (_jsxs(ScreenContainer, __assign({ sx: { mt: 2.75 } }, { children: [_jsxs(TACContainerStyled, __assign({ readOnly: readOnly || isChecked }, { children: [_jsx(CheckboxStyled, { disabled: isChecked, disableRipple: true, disableFocusRipple: true, focusRipple: false, checked: tacChecked, onChange: handleTACCheckedChange }), _jsxs(TextStyled, { children: [t('read_agree_terms_and_conditions_message'), _jsx(LinkStyled, __assign({ href: isAr ? TAP_WEBSITE + countryCode + EXTERNAL_LINKS.TOS_AR : TAP_WEBSITE + countryCode + EXTERNAL_LINKS.TOS_EN, target: '_blank', underline: 'always' }, { children: t('terms_and_conditions_link_title') }))] })] })), _jsx(CollapseStyled, __assign({ in: !!warningMessage }, { children: _jsx(Warning, __assign({ warningType: 'alert' }, { children: warningMessage && t(warningMessage) })) }))] })));
91
+ return (_jsx(Collapse, __assign({ in: !isChecked }, { children: _jsxs(ScreenContainer, __assign({ sx: { mt: 2.75 } }, { children: [_jsxs(TACContainerStyled, __assign({ readOnly: readOnly }, { children: [_jsx(CheckboxStyled, { disableRipple: true, disableFocusRipple: true, focusRipple: false, checked: tacChecked, onChange: handleTACCheckedChange }), _jsxs(TextStyled, { children: [t('read_agree_terms_and_conditions_message'), _jsx(LinkStyled, __assign({ href: isAr ? TAP_WEBSITE + countryCode + EXTERNAL_LINKS.TOS_AR : TAP_WEBSITE + countryCode + EXTERNAL_LINKS.TOS_EN, target: '_blank', underline: 'always' }, { children: t('terms_and_conditions_link_title') }))] })] })), _jsx(CollapseStyled, __assign({ in: !!warningMessage }, { children: _jsx(Warning, __assign({ warningType: 'alert' }, { children: warningMessage && t(warningMessage) })) }))] })) })));
92
92
  };
93
93
  export default React.memo(TAC);
@@ -51,6 +51,6 @@ var TransactionPolicy = function (_a) {
51
51
  return;
52
52
  transactionControl.field.onChange(checked);
53
53
  };
54
- return (_jsxs(ScreenContainer, { children: [_jsxs(ContainerStyled, __assign({ readOnly: readOnly || isChecked }, { children: [_jsx(CheckboxStyled, { disabled: isChecked, disableRipple: true, disableFocusRipple: true, focusRipple: false, checked: transactionChecked, onChange: handleTransactionCheckedChange }), _jsxs(TextStyled, { children: [t('agree_on_chargeback_policy'), _jsx(LinkStyled, __assign({ href: isAr ? TAP_WEBSITE + countryCode + EXTERNAL_LINKS.TRANSACTION_AR : TAP_WEBSITE + countryCode + EXTERNAL_LINKS.TRANSACTION_EN, target: '_blank', underline: 'always' }, { children: t('chargeback_policy') }))] })] })), _jsx(CollapseStyled, __assign({ in: !!warningMessage }, { children: _jsx(Warning, __assign({ warningType: 'alert' }, { children: warningMessage && t(warningMessage) })) }))] }));
54
+ return (_jsx(Collapse, __assign({ in: !isChecked }, { children: _jsxs(ScreenContainer, { children: [_jsxs(ContainerStyled, __assign({ readOnly: readOnly }, { children: [_jsx(CheckboxStyled, { disableRipple: true, disableFocusRipple: true, focusRipple: false, checked: transactionChecked, onChange: handleTransactionCheckedChange }), _jsxs(TextStyled, { children: [t('agree_on_chargeback_policy'), _jsx(LinkStyled, __assign({ href: isAr ? TAP_WEBSITE + countryCode + EXTERNAL_LINKS.TRANSACTION_AR : TAP_WEBSITE + countryCode + EXTERNAL_LINKS.TRANSACTION_EN, target: '_blank', underline: 'always' }, { children: t('chargeback_policy') }))] })] })), _jsx(CollapseStyled, __assign({ in: !!warningMessage }, { children: _jsx(Warning, __assign({ warningType: 'alert' }, { children: warningMessage && t(warningMessage) })) }))] }) })));
55
55
  };
56
56
  export default TransactionPolicy;
@@ -80,7 +80,7 @@ var BrandInfo = function (_a) {
80
80
  if ((responseBody === null || responseBody === void 0 ? void 0 : responseBody.response_code) === '5')
81
81
  methods.setError('brandName', { message: 'brand_name_already_exist' });
82
82
  }, [responseBody]);
83
- var brandErrChecks = !methods.formState.isValid || !!methods.formState.errors.brandName;
83
+ var brandErrChecks = !methods.formState.isValid || !!methods.formState.errors.brandName || !!error;
84
84
  var disabled = brandErrChecks || brandNameChecking || uploadingBrandLogo;
85
85
  var disableBack = settingsData.appConfig.mode === 'content';
86
86
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(BrandName, { readOnly: readOnly['brandName'] || (noneEditable['name.en'] && noneEditable['name.ar']), brandNameChecking: brandNameChecking, fetchingBrandName: setBrandNameChecking, isVerified: isBrandNameVerified }), _jsx(BrandLogo, { defaultFile: defaultBrandLogoFile, readOnly: readOnly['brandLogoId'], isVerified: dataVerified['logo'] }), _jsx(SalesChannels, { readOnly: readOnly['salesChannels'] || noneEditable['channel_services'] }), _jsx(Button, __assign({ disableBack: disableBack, onBackClicked: function () { return onBack(); }, disabled: disabled, isAr: isAr, error: t(error || ''), loading: loading }, { children: t('next') }))] })) })) }));
@@ -90,7 +90,7 @@ var BrandInfo = function (_a) {
90
90
  if (error)
91
91
  dispatch(clearError());
92
92
  }, [methods.formState.isValid]);
93
- var disabled = !methods.formState.isValid;
93
+ var disabled = !methods.formState.isValid || !!error;
94
94
  var handleMenuClick = function (flag) {
95
95
  setListActive(flag);
96
96
  };
@@ -21,10 +21,10 @@ var SuccessWithFlowButtons = function () {
21
21
  var _a = useAppSelector(brandSelector), data = _a.data, loading = _a.loading;
22
22
  var settingsData = useAppSelector(settingsSelector).data;
23
23
  var isScopeAuthentication = settingsData.appConfig.scope === SCOPE_AUTH;
24
- var _b = data.verify.responseBody || {}, flows = _b.flows, entity = _b.entity, brand = _b.brand, bank = _b.bank_account, merchant = _b.merchant, user = _b.user, business = _b.business, board_id = _b.board_id, board_info_id = _b.board_info_id, name = _b.name, individuals = _b.individuals, recipient = _b.recipient;
24
+ var _b = data.verify.responseBody || {}, flows = _b.flows, entity = _b.entity, brand = _b.brand, bank = _b.bank_account, merchant = _b.merchant, user = _b.user, business = _b.business, board_id = _b.board_id, board_info_id = _b.board_info_id, name = _b.name, individuals = _b.individuals;
25
25
  var onClose = function () {
26
26
  dispatch(onCloseCompleteBrand());
27
27
  };
28
- return (_jsx(SuccessFlowButtons, { flowName: data.flowName, loading: loading, bank: bank, brand: brand, entity: entity, merchant: merchant, user: __assign({ names: { en: name } }, user), business: business, boardId: board_id, boardInfoId: board_info_id, individuals: individuals, flows: flows || [], onClose: isScopeAuthentication ? onClose : undefined, recipient: recipient }));
28
+ return (_jsx(SuccessFlowButtons, { flowName: data.flowName, loading: loading, bank: bank, brand: brand, entity: entity, merchant: merchant, user: __assign({ names: { en: name } }, user), business: business, boardId: board_id, boardInfoId: board_info_id, individuals: individuals, flows: flows || [], onClose: isScopeAuthentication ? onClose : undefined }));
29
29
  };
30
30
  export default memo(SuccessWithFlowButtons);
@@ -72,7 +72,7 @@ var VerifyNumber = function (_a) {
72
72
  var onSubmit = function (formData) {
73
73
  dispatch(verifyBrandLeadOTP(deepCopy(formData)));
74
74
  };
75
- var disabled = !methods.formState.isValid || !phone || resendLoading;
75
+ var disabled = !methods.formState.isValid || !!error || !phone || resendLoading;
76
76
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(OTPTitleContainerStyled, { children: _jsxs(OTPTitleStyled, { children: [loading ? t('ide_otp_waiting_title') : t('ide_opt_sent_title'), !loading && phone && _jsx("span", __assign({ dir: 'ltr' }, { children: "".concat(maskPhone(phone || '')) }))] }) }), _jsx(OTPInput, { loading: resendLoading, setLoading: setResendLoading }), _jsx(Button, __assign({ disableBack: true, disabled: disabled, isAr: isAr, loading: loading, error: t(error || '') }, { children: t('next') }))] })) })) }));
77
77
  };
78
78
  export default React.memo(VerifyNumber);
@@ -13,7 +13,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
13
13
  import { memo, useEffect } from 'react';
14
14
  import { createRoot } from 'react-dom/client';
15
15
  import { useAppTheme, useAppDispatch, useAppSelector, useAppConfig, useErrorListener, useStepStartedListener } from '../../hooks';
16
- import { handleCurrentActiveScreen, handleLanguage, settingsSelector } from '../../app/settings';
16
+ import { handleLanguage, settingsSelector } from '../../app/settings';
17
17
  import { FeatureContainer } from '../shared/Containers';
18
18
  import { businessSelector, verifyLeadToken } from '../app/business/businessStore';
19
19
  import AnimationFlow from '../../components/AnimationFlow';
@@ -46,14 +46,9 @@ var Business = memo(function (props) {
46
46
  });
47
47
  };
48
48
  useEffect(function () {
49
- if (settingLoading || !open)
50
- return;
51
- if (!data.isValidOperator) {
52
- dispatch(handleCurrentActiveScreen('BUSINESS_OPERATOR_ERROR_STEP'));
53
- return;
54
- }
55
- verifyToken();
56
- }, [data.isValidOperator, settingLoading]);
49
+ if (!settingLoading && open)
50
+ verifyToken();
51
+ }, [settingLoading]);
57
52
  return (_jsx(ThemeProvider, __assign({ theme: theme }, { children: _jsx(Background, __assign({ open: open, isTapOrigin: isTapOrigin, loading: settingLoading || customLoading }, { children: _jsx(AnimationFlow, __assign({ pointerEvents: loading ? 'none' : 'auto', isTapOrigin: isTapOrigin, loading: settingLoading || customLoading, error: error, open: open, breakpoint: 'sm', screenId: activeScreen.name, merchantInfo: merchant, isMaturityExpress: isMaturityExpress, dialogEdgeFormat: data.appConfig.dialogEdgeFormat }, { children: _jsx(FeatureContainer, __assign({ isMaturityExpress: isMaturityExpress }, { children: businessFeatureScreens.map(function (_a, index) {
58
53
  var Element = _a.element, name = _a.name;
59
54
  var isActive = activeScreen.name === name;
@@ -72,7 +72,7 @@ var Activities = function () {
72
72
  anchorEl ? setAnchorEl(false) : setAnchorEl(true);
73
73
  };
74
74
  var isOperationStartDateVerified = dataVerified['operations.business_start_date'] && (operations === null || operations === void 0 ? void 0 : operations.business_start_date) === methods.watch('operationStartDate');
75
- var disabled = !methods.formState.isValid;
75
+ var disabled = !methods.formState.isValid || !!error;
76
76
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(Collapse, __assign({ in: !collapse && !anchorEl }, { children: _jsx(LicenseName, {}) })), _jsx(Collapse, __assign({ in: !collapse }, { children: _jsx(ActivitiesList, { readOnly: readOnly['activities'] || noneEditable['activities'], onListOpen: function () { return handleMenuClick(); }, onListClose: function () { return handleMenuClick(); } }) })), _jsx(Collapse, __assign({ in: !anchorEl }, { children: _jsx(OperationStartDate, { isVerified: isOperationStartDateVerified, readOnly: readOnly['operationStartDate'] || noneEditable['operations.business_start_date'], onDateClicked: handleCollapseOpenClose }) })), _jsx(Collapse, __assign({ in: !collapse && !anchorEl }, { children: _jsx(Button, __assign({ disableBack: true, onBackClicked: function () { return onBack(); }, isAr: isAr, disabled: disabled, loading: loading, error: t(error || '') }, { children: t('next') })) }))] })) })) }));
77
77
  };
78
78
  export default Activities;
@@ -99,7 +99,7 @@ var BusinessType = function (_a) {
99
99
  var hasEntityList = !!(entityLicenseList === null || entityLicenseList === void 0 ? void 0 : entityLicenseList.length);
100
100
  var showLicenseList = hasEntityList ? (isSACountry || isOtherCountry) && isOtherLicense(selectedLicenseEntity) : isSACountry || isOtherCountry;
101
101
  var showEntityList = isKWCountry ? hasEntityList && !isLicenseListActive && isCR : hasEntityList && !isLicenseListActive;
102
- var disabled = !methods.formState.isValid || uploading || uploadingArticle;
102
+ var disabled = !methods.formState.isValid || !!error || uploading || uploadingArticle;
103
103
  var disableBack = !data.otpData.isNID;
104
104
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(Form, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(LicenseType, { show: !listActive && isKWCountry }), _jsx(EntityLicenseList, { show: showEntityList, onListOpen: function () { return handleMenuClick(ListType.EntityLicenseList); }, onListClose: function () { return handleMenuClick(); } }), _jsx(LicenseList, { show: showLicenseList && !isEntityLicenseListActive, onListOpen: function () { return handleMenuClick(ListType.LicenseList); }, onListClose: function () { return handleMenuClick(); } }), _jsx(EntityName, { show: !isAnyListActive && isKWCountry && isCR }), _jsx(LicenseNumber, { show: isKWCountry ? !isAnyListActive && isCR : !isAnyListActive }), _jsx(LicenseCertificate, { show: !isAnyListActive && isKWCountry && isCR }), _jsx(Article, { show: !isAnyListActive && isKWCountry && isCR }), _jsx(Collapse, __assign({ in: !isAnyListActive, timeout: 500 }, { children: _jsx(Button, __assign({ disableBack: disableBack, onBackClicked: function () { return onBack(); }, isAr: isAr, disabled: disabled, loading: loading, error: t(error || '') }, { children: t('next') })) }))] })) })) }));
105
105
  };
@@ -62,7 +62,7 @@ var CivilID = function (_a) {
62
62
  if (error)
63
63
  dispatch(clearError());
64
64
  };
65
- var disabled = !methods.formState.isValid;
65
+ var disabled = !methods.formState.isValid || !!error;
66
66
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(IDNumber, { sx: { mb: 7.5, transition: 'mb 0.3s' } }), _jsx(Button, __assign({ loading: loading, isAr: isAr, disableBack: true, disabled: disabled || settingsStore.loading, error: t(error || '') }, { children: t('next') }))] })) })) }));
67
67
  };
68
68
  export default React.memo(CivilID);
@@ -127,7 +127,7 @@ var Customers = function (_a) {
127
127
  var whenNotSelectExpectedCustomers = !isCustomerLocationsListActive && !isExpectedSalesListActive;
128
128
  var whenNotSelectExpectedSales = !isCustomerLocationsListActive && !isExpectedCustomersListActive;
129
129
  var isAnyListSelected = !isExpectedCustomersListActive && !isCustomerLocationsListActive && !isExpectedSalesListActive;
130
- var disabled = !methods.formState.isValid;
130
+ var disabled = !methods.formState.isValid || !!error;
131
131
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(CustomerLocations, { readOnly: readOnly['customerLocations'] || noneEditable['operations.customer_base_location'], show: whenNotSelectCustomersLocation, onListOpen: function () { return handleMenuClick(ListType.CustomerLocationsList); }, onListClose: function () { return handleMenuClick(); }, isVerified: isCustomerLocationsVerified }), _jsx(ExpectedCustomers, { readOnly: readOnly['expectedCustomer'] || noneEditable['operations.customer_base'], show: whenNotSelectExpectedCustomers, onListOpen: function () { return handleMenuClick(ListType.ExpectedCustomersList); }, onListClose: function () { return handleMenuClick(); }, isVerified: isExpectedCustomersVerified }), _jsx(ExpectedSales, { readOnly: readOnly['expectedSale'] || noneEditable['operations.sales_range'], show: whenNotSelectExpectedSales, onListOpen: function () { return handleMenuClick(ListType.ExpectedSalesList); }, onListClose: function () { return handleMenuClick(); }, isVerified: isExpectedSalesRangeVerified }), _jsxs(Collapse, __assign({ in: isAnyListSelected }, { children: [_jsx(RefundPolicy, { readOnly: readOnly['refundPolicy'] || noneEditable['terms'] }), _jsx(TransactionPolicy, { readOnly: readOnly['transactionPolicy'] || noneEditable['terms'] }), _jsx(Box, __assign({ sx: { mt: 2 } }, { children: _jsx(Button, __assign({ onBackClicked: function () { return onBack(); }, isAr: isAr, disabled: disabled, loading: loading, error: t(error || '') }, { children: t('next') })) }))] }))] })) })) }));
132
132
  };
133
133
  export default React.memo(Customers);
@@ -22,7 +22,7 @@ import Collapse from '../../../../components/Collapse';
22
22
  import ExpandIcon from '../../../../components/ExpandIcon';
23
23
  import { EndAdornmentExpanded } from '../../../shared/EndAdornment';
24
24
  import { businessSelector, clearError } from '../../../app/business/businessStore';
25
- import { getCurrencyByCountryIso2, isExist } from '../../../../utils';
25
+ import { isExist } from '../../../../utils';
26
26
  import { ScreenContainer } from '../../../shared/Containers';
27
27
  import Search from '../../../shared/Search';
28
28
  import InputSelect from '../../../shared/InputSelect';
@@ -66,7 +66,7 @@ var ExpectedSalesRange = function (_a) {
66
66
  var expectedSaleControl = useController({ name: 'expectedSale', control: control });
67
67
  var _e = useAppSelector(businessSelector), data = _e.data, error = _e.error;
68
68
  var settingsData = useAppSelector(settingsSelector).data;
69
- var activitiesData = data.activitiesData;
69
+ var activitiesData = data.activitiesData, currency = data.currency;
70
70
  var expectedSales = (activitiesData.responseBody || {}).expectedSales;
71
71
  var expectedSalesRangeValue = expectedSaleControl.field.value;
72
72
  var countryCode = settingsData.businessCountry;
@@ -121,11 +121,8 @@ var ExpectedSalesRange = function (_a) {
121
121
  if (item)
122
122
  setSubIndex(item.id);
123
123
  }, [anchorEl, expectedSalesRangeValue]);
124
- var getCurrency = React.useMemo(function () {
125
- return t(getCurrencyByCountryIso2(countryCode.iso2));
126
- }, [countryCode.iso2]);
127
124
  return (_jsx(Collapse, __assign({ in: show }, { children: _jsxs(ScreenContainer, { children: [_jsx(InputLabelStyled, { children: t('expected_sales_monthly', {
128
- currency: getCurrency
125
+ currency: t(currency)
129
126
  }) }), _jsx(InputStyled, { readOnly: readOnly, value: (isAr ? expectedSalesRangeValue === null || expectedSalesRangeValue === void 0 ? void 0 : expectedSalesRangeValue.name.ar : expectedSalesRangeValue === null || expectedSalesRangeValue === void 0 ? void 0 : expectedSalesRangeValue.name.en) || '', onClick: !!anchorEl ? handleCloseMainMenu : handleOpenMainMenu, placeholder: t('choose_expected_sales'), endAdornment: _jsx(EndAdornmentExpanded, { anchorEl: anchorEl, isVerified: isVerified }) }), _jsxs(Collapse, __assign({ in: !!anchorEl }, { children: [_jsx(Search, { onSearchValue: handleSearch }), _jsx(SimpleListStyled, { sx: { maxHeight: '350px', paddingTop: 0 }, list: expectedSalesRangeList, listItemProps: { sx: { padding: 0 } }, onSelectItem: function (item) {
130
127
  var isOnlyOneItem = !item.sub || item.sub.length === 1;
131
128
  if (isOnlyOneItem)
@@ -54,7 +54,7 @@ var IDBOD = function (_a) {
54
54
  var handleCollapseOpenClose = function (flag) {
55
55
  setCollapse(flag);
56
56
  };
57
- var disabled = !methods.formState.isValid;
57
+ var disabled = !methods.formState.isValid || !!error;
58
58
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(Collapse, __assign({ in: !collapse }, { children: _jsx(ID, {}) })), _jsx(DOB, { onDateClicked: handleCollapseOpenClose }), _jsx(Collapse, __assign({ in: !collapse }, { children: _jsx(Button, __assign({ loading: loading, disableBack: true, isAr: isAr, disabled: disabled, error: t(error || '') }, { children: t('next') })) }))] })) })) }));
59
59
  };
60
60
  export default React.memo(IDBOD);
@@ -82,7 +82,7 @@ var OTP = function (_a) {
82
82
  var onBack = function () {
83
83
  dispatch(handlePrevScreenStep());
84
84
  };
85
- var disabled = !methods.formState.isValid;
85
+ var disabled = !methods.formState.isValid || !!error;
86
86
  var idNumber = data.nidData.nid;
87
87
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(OTPTitleContainerStyled, { children: _jsxs(OTPTitleStyled, { children: [loading ? t('ide_otp_waiting_title') : t('opt_nid_sent_title', { provider: 'ABSHER' }), ' ', !loading && _jsx("span", __assign({ dir: 'ltr' }, { children: "".concat(maskID(idNumber || '')) }))] }) }), _jsx(OTPInput, {}), _jsx(Button, __assign({ onBackClicked: function () { return onBack(); }, disabled: disabled, isAr: isAr, loading: loading, error: t(error || '') }, { children: t('next') }))] })) })) }));
88
88
  };
@@ -16,7 +16,7 @@ import { businessSelector } from '../../../app/business/businessStore';
16
16
  import SuccessFlowButtons from '../../../shared/SuccessFlowButtons';
17
17
  var SuccessWithFlowButtons = function () {
18
18
  var data = useAppSelector(businessSelector).data;
19
- var _a = data.verify.responseBody || {}, flows = _a.flows, entity = _a.entity, brand = _a.brand, bank = _a.bank_account, merchant = _a.merchant, user = _a.user, business = _a.business, board_id = _a.board_id, board_info_id = _a.board_info_id, name = _a.name, individuals = _a.individuals, recipient = _a.recipient;
20
- return (_jsx(SuccessFlowButtons, { flowName: data.flowName, bank: bank, brand: brand, entity: entity, merchant: merchant, user: __assign({ names: { en: name } }, user), business: business, boardId: board_id, individuals: individuals, boardInfoId: board_info_id, flows: flows || [], recipient: recipient }));
19
+ var _a = data.verify.responseBody || {}, flows = _a.flows, entity = _a.entity, brand = _a.brand, bank = _a.bank_account, merchant = _a.merchant, user = _a.user, business = _a.business, board_id = _a.board_id, board_info_id = _a.board_info_id, name = _a.name, individuals = _a.individuals;
20
+ return (_jsx(SuccessFlowButtons, { flowName: data.flowName, bank: bank, brand: brand, entity: entity, merchant: merchant, user: __assign({ names: { en: name } }, user), business: business, boardId: board_id, individuals: individuals, boardInfoId: board_info_id, flows: flows || [] }));
21
21
  };
22
22
  export default memo(SuccessWithFlowButtons);
@@ -72,7 +72,7 @@ var VerifyNumber = function (_a) {
72
72
  var onBack = function () {
73
73
  dispatch(handlePrevScreenStep());
74
74
  };
75
- var disabled = !methods.formState.isValid || !phone || resendLoading;
75
+ var disabled = !methods.formState.isValid || !!error || !phone || resendLoading;
76
76
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(OTPTitleContainerStyled, { children: _jsxs(OTPTitleStyled, { children: [loading ? t('ide_otp_waiting_title') : t('ide_opt_sent_title'), !loading && phone && _jsx("span", __assign({ dir: 'ltr' }, { children: "".concat(maskPhone(phone || '')) }))] }) }), _jsx(OTPInput, { loading: resendLoading, setLoading: setResendLoading }), _jsx(Button, __assign({ disableBack: true, onBackClicked: function () { return onBack(); }, disabled: disabled, isAr: isAr, loading: loading, error: t(error || '') }, { children: t('next') }))] })) })) }));
77
77
  };
78
78
  export default React.memo(VerifyNumber);
@@ -56,7 +56,7 @@ var BrandSegment = function (_a) {
56
56
  if (error)
57
57
  dispatch(clearError());
58
58
  }, [methods.formState.isValid]);
59
- var disabled = !methods.formState.isValid;
59
+ var disabled = !methods.formState.isValid || !!error;
60
60
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(Form, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(TeamSize, { show: true, onListOpen: function () { return setListActive(true); }, onListClose: function () { return setListActive(false); } }), _jsx(Collapse, __assign({ in: !listActive, timeout: 500 }, { children: _jsx(Button, __assign({ onBackClicked: function () { return onBack(); }, disabled: disabled, isAr: isAr, error: t(error || ''), loading: loading }, { children: t('next') })) }))] })) })) }));
61
61
  };
62
62
  export default React.memo(BrandSegment);
@@ -81,8 +81,7 @@ var BusinessCountryScreen = function (_a) {
81
81
  return [2];
82
82
  countryCode = findCountryByIso2(settingsData.countries, iso2);
83
83
  dispatch(handleSetCountryByIso2(iso2));
84
- if (settingsData.appConfig.mode !== 'popup')
85
- updateLocationUrlWithCountry(iso2);
84
+ updateLocationUrlWithCountry(iso2);
86
85
  if (!data.leadId) return [3, 2];
87
86
  return [4, dispatch(updateBusinessCountry(iso2))];
88
87
  case 1:
@@ -92,7 +92,7 @@ var CivilID = function (_a) {
92
92
  React.useEffect(function () {
93
93
  dispatch(resetStore());
94
94
  }, []);
95
- var disabled = !methods.formState.isValid;
95
+ var disabled = !methods.formState.isValid || !!error;
96
96
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(IDNumber, { sx: { mb: methods.formState.isValid ? 7.5 : 0, transition: 'mb 0.3s' } }), _jsx(Button, __assign({ loading: loading, isAr: isAr, onBackClicked: onBackToCountryList, disableBack: !data.isStartFromBusinessCountry, disabled: disabled || settingsStore.loading, error: t(error || '') }, { children: t('next') })), _jsxs(Collapse, __assign({ in: !methods.formState.isValid }, { children: [_jsxs(OrBoxStyled, { children: [_jsx(DividerStyled, {}), _jsx(TextStyled, { children: t('or') }), _jsx(DividerStyled, {})] }), _jsx(MobileButton, __assign({ onClick: function () { return onBack(); }, disabled: loading || settingsStore.loading }, { children: t('mobile_button_label') }))] }))] })) })) }));
97
97
  };
98
98
  export default React.memo(CivilID);
@@ -53,7 +53,6 @@ import { useController, useFormContext } from 'react-hook-form';
53
53
  import { useTranslation } from 'react-i18next';
54
54
  import { styled } from '@mui/material/styles';
55
55
  import { useAppDispatch, useAppSelector } from '../../../../hooks';
56
- import { removeAllOtherThanCharsNumbersAtAndDot } from '../../../../utils';
57
56
  import Collapse from '../../../../components/Collapse';
58
57
  import { ScreenContainer } from '../../../shared/Containers';
59
58
  import Input from '../../../shared/Input';
@@ -90,8 +89,7 @@ var Email = function (_a) {
90
89
  });
91
90
  }); }, 500);
92
91
  var handleEmailChange = function (event) {
93
- var value = removeAllOtherThanCharsNumbersAtAndDot(event.target.value);
94
- emailControl.field.onChange(value);
92
+ emailControl.field.onChange(event.target.value);
95
93
  };
96
94
  React.useEffect(function () {
97
95
  var isValid = emailValue && !error && emailValue.length > 3;
@@ -100,7 +100,7 @@ var Individual = function (_a) {
100
100
  }, [responseBody]);
101
101
  var isLeadEmailAvailable = (contact === null || contact === void 0 ? void 0 : contact.email) === methods.watch('email');
102
102
  var isEmailValid = typeof is_available === 'undefined' ? isLeadEmailAvailable : is_available;
103
- var emailErrChecks = !methods.formState.isValid || !!methods.formState.errors.email;
103
+ var emailErrChecks = !methods.formState.isValid || !!methods.formState.errors.email || !!error;
104
104
  var disabled = emailErrChecks || emailChecking || !isEmailValid;
105
105
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(Name, { show: !listActive }), _jsx(MobileNumber, { show: !isMobile, onListOpen: function () { return handleMenuListClick(); }, onListClose: function () { return handleMenuListClick(); }, countries: settingsData.countries }), _jsx(Email, { show: !listActive, fetchingEmail: function (v) { return setEmailChecking(v); }, emailChecking: emailChecking }), _jsx(Collapse, __assign({ in: !listActive }, { children: _jsx(Button, __assign({ onBackClicked: function () { return onBack(); }, disabled: disabled, isAr: isAr, loading: loading, error: t(error || '') }, { children: t('next') })) }))] })) })) }));
106
106
  };
@@ -60,9 +60,9 @@ var BrandList = function (_a) {
60
60
  setAnchorEl(null);
61
61
  (_a = rest.onListClose) === null || _a === void 0 ? void 0 : _a.call(rest);
62
62
  };
63
- var getBrandName = function (brand) {
64
- var _a, _b;
65
- return (isAr ? (_a = brand === null || brand === void 0 ? void 0 : brand.name) === null || _a === void 0 ? void 0 : _a.ar : (_b = brand === null || brand === void 0 ? void 0 : brand.name) === null || _b === void 0 ? void 0 : _b.en) || '';
63
+ var getBrandName = function (_a) {
64
+ var name = _a.name;
65
+ return (isAr ? name === null || name === void 0 ? void 0 : name.ar : name === null || name === void 0 ? void 0 : name.en) || '';
66
66
  };
67
67
  var getBrandId = function (item) {
68
68
  return item.id || '';
@@ -84,7 +84,7 @@ var Merchant = function (_a) {
84
84
  if (termAndConditionChecked === true)
85
85
  methods.setValue('termAndConditionChecked', termAndConditionChecked);
86
86
  }, [termAndConditionChecked]);
87
- var brandErrChecks = !methods.formState.isValid || !!methods.formState.errors.brandName;
87
+ var brandErrChecks = !methods.formState.isValid || !!methods.formState.errors.brandName || !!error;
88
88
  var disabled = brandErrChecks || brandNameChecking || ((_c = data.brandData.responseBody) === null || _c === void 0 ? void 0 : _c.response_code) === '5';
89
89
  var hasBrandList = (brandList === null || brandList === void 0 ? void 0 : brandList.length) > 0;
90
90
  var isOtherBrand = (brandListItem === null || brandListItem === void 0 ? void 0 : brandListItem.id) === 'other' && hasBrandList;
@@ -15,7 +15,7 @@ var SalesChannels = function (_a) {
15
15
  var channelList = (responseBody || {}).channel_list;
16
16
  var selectedBrandControl = getValues('selectedBrandItem');
17
17
  React.useEffect(function () {
18
- if (selectedBrandItem === null || selectedBrandItem === void 0 ? void 0 : selectedBrandItem.id) {
18
+ if (selectedBrandItem.id) {
19
19
  setValue('selectedBrandItem', selectedBrandItem);
20
20
  var sales = mapSalesChannel(selectedBrandItem.channel_services || []);
21
21
  field.onChange(sales);
@@ -126,7 +126,7 @@ var Mobile = function (_a) {
126
126
  var isBusinessListActive = listType === ListType.BusinessList;
127
127
  var isCountryListActive = listType === ListType.CountryCodeList;
128
128
  var listActive = isBusinessListActive || isCountryListActive;
129
- var disabled = !methods.formState.isValid;
129
+ var disabled = !methods.formState.isValid || !!error;
130
130
  var title = t('join_our_community');
131
131
  var subTitle = t('ide_terms_and_conditions_description');
132
132
  return (_jsxs(ScreenContainer, { children: [(title || subTitle) && _jsx(MIDTitle, { show: !listActive, title: title, description: subTitle }), _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(InputsContainerStyled, { children: _jsx(MobileNumber, { show: !isBusinessListActive, countries: settingsStore.data.countries, onListOpen: function () { return handleMenuListClick(ListType.CountryCodeList); }, onListClose: function () { return handleMenuListClick(); } }) }), _jsxs(Collapse, __assign({ in: !listActive }, { children: [_jsx(Button, __assign({ isAr: isAr, onBackClicked: onBackToCountryList, disableBack: !data.isStartFromBusinessCountry, disabled: disabled || settingsStore.loading, loading: loading, error: t(error || '') }, { children: t('next') })), _jsxs(Collapse, __assign({ in: !methods.formState.isValid && !isOtherThanKWOrSACountry }, { children: [_jsxs(OrBoxStyled, { children: [_jsx(DividerStyled, {}), _jsx(TextStyled, { children: t('or') }), _jsx(DividerStyled, {})] }), isKWCountry ? (_jsx(MobileButton, __assign({ disabled: settingsStore.loading || loading, onClick: function () { return onBack(); }, icon: ICONS_NAMES.PACI_ICON }, { children: t('paci_button_label') }))) : (_jsx(AbsherButton, __assign({ disabled: settingsStore.loading || loading, onClick: function () { return onBack(); } }, { children: t('absher_button_label') })))] }))] }))] })) }))] }));
@@ -101,7 +101,7 @@ var NID = function (_a) {
101
101
  React.useEffect(function () {
102
102
  dispatch(resetStore());
103
103
  }, []);
104
- var disabled = !methods.formState.isValid;
104
+ var disabled = !methods.formState.isValid || !!error;
105
105
  return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(FormStyled, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(Collapse, __assign({ in: !collapse }, { children: _jsx(IDNumber, { show: !collapse }) })), _jsx(DOB, { onDateClicked: handleCollapseOpenClose }), _jsxs(Collapse, __assign({ in: !collapse }, { children: [_jsx(Button, __assign({ loading: loading, isAr: isAr, onBackClicked: onBackToCountryList, disableBack: !data.isStartFromBusinessCountry, disabled: disabled || settingsStore.loading, error: t(error || '') }, { children: t('next') })), _jsxs(Collapse, __assign({ in: !methods.formState.isValid }, { children: [_jsxs(OrBoxStyled, { children: [_jsx(DividerStyled, {}), _jsx(TextStyled, { children: t('or') }), _jsx(DividerStyled, {})] }), _jsx(MobileButton, __assign({ onClick: function () { return onBack(); }, disabled: loading || settingsStore.loading }, { children: t('mobile_button_label') }))] }))] }))] })) })) }));
106
106
  };
107
107
  export default React.memo(NID);
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import * as React from 'react';
3
3
  import { useTranslation } from 'react-i18next';
4
- import GenericError from '../../../shared/GenericError';
4
+ import GenericError from '../../../../features/shared/GenericError';
5
5
  var OperatorError = function (_a) {
6
6
  var t = useTranslation().t;
7
7
  return _jsx(GenericError, { error: t('operator_is_invalid'), errorTitle: t('oops') });
@@ -29,7 +29,6 @@ import BrandList from './BrandList';
29
29
  import EntityList from './EntityList';
30
30
  import LicenseNumber from './LicenseNumber';
31
31
  import EntityLegalName from './EntityLegalName';
32
- import LicenseType from './EntityLicenseType';
33
32
  var ListType;
34
33
  (function (ListType) {
35
34
  ListType["BrandList"] = "BrandList";
@@ -65,8 +64,7 @@ var AuthenticationList = function (_a) {
65
64
  var dispatch = useAppDispatch();
66
65
  var onSubmit = function (formData) {
67
66
  if (isAddEntity) {
68
- var licenseNumber = formData.licenseNumber, legalName = formData.legalName, brandInfo_1 = formData.brandInfo, licenseType = formData.licenseType;
69
- var data_1 = { licenseNumber: licenseNumber, legalName: legalName, brandInfo: brandInfo_1, licenseType: licenseType };
67
+ var data_1 = { licenseNumber: formData.licenseNumber, legalName: formData.legalName, brandInfo: formData.brandInfo };
70
68
  dispatch(createEntity(deepCopy(data_1)));
71
69
  return;
72
70
  }
@@ -78,7 +76,6 @@ var AuthenticationList = function (_a) {
78
76
  setIsAddEntity(false);
79
77
  methods.setValue('licenseNumber', '');
80
78
  methods.setValue('legalName', '');
81
- methods.setValue('licenseType', '');
82
79
  methods.setValue('entityInfo', undefined, { shouldValidate: true });
83
80
  return;
84
81
  }
@@ -99,6 +96,6 @@ var AuthenticationList = function (_a) {
99
96
  };
100
97
  var isBrandList = listActive === ListType.BrandList;
101
98
  var isEntityList = listActive === ListType.EntityList;
102
- return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(Form, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(BrandList, { list: brandList || [], show: !isAddEntity && !isEntityList, onListOpen: function () { return handleMenuClick(ListType.BrandList); }, onListClose: function () { return handleMenuClick(); } }), _jsx(EntityList, { countryList: settingsData.countries || [], show: !isBrandList, handleAddEntity: function (flag) { return setIsAddEntity(flag); }, onListOpen: function () { return handleMenuClick(ListType.EntityList); }, onListClose: function () { return handleMenuClick(); } }), _jsxs(Collapse, __assign({ in: isAddEntity && !isBrandList && !isEntityList }, { children: [_jsx(EntityLegalName, {}), _jsx(LicenseType, {}), _jsx(LicenseNumber, {})] })), _jsx(Collapse, __assign({ in: !listActive, timeout: 500 }, { children: _jsx(Button, __assign({ onBackClicked: function () { return onBack(); }, disabled: disabled, isAr: isAr, error: t(error || ''), loading: loading }, { children: isAddEntity ? t('create_new_entity') : t('next') })) }))] })) })) }));
99
+ return (_jsx(ScreenContainer, { children: _jsx(FormProvider, __assign({}, methods, { children: _jsxs(Form, __assign({ onSubmit: methods.handleSubmit(onSubmit) }, { children: [_jsx(BrandList, { list: brandList || [], show: !isAddEntity && !isEntityList, onListOpen: function () { return handleMenuClick(ListType.BrandList); }, onListClose: function () { return handleMenuClick(); } }), _jsx(EntityList, { countryList: settingsData.countries || [], show: !isBrandList, handleAddEntity: function (flag) { return setIsAddEntity(flag); }, onListOpen: function () { return handleMenuClick(ListType.EntityList); }, onListClose: function () { return handleMenuClick(); } }), _jsxs(Collapse, __assign({ in: isAddEntity && !isBrandList && !isEntityList }, { children: [_jsx(EntityLegalName, {}), _jsx(LicenseNumber, {})] })), _jsx(Collapse, __assign({ in: !listActive, timeout: 500 }, { children: _jsx(Button, __assign({ onBackClicked: function () { return onBack(); }, disabled: disabled, isAr: isAr, error: t(error || ''), loading: loading }, { children: isAddEntity ? t('create_new_entity') : t('next') })) }))] })) })) }));
103
100
  };
104
101
  export default React.memo(AuthenticationList);