@tap-payments/auth-jsconnect 2.3.43-test → 2.3.47-test
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/build/@types/form.d.ts +0 -1
- package/build/api/brand.d.ts +7 -0
- package/build/api/brand.js +10 -1
- package/build/api/index.d.ts +3 -1
- package/build/components/DatePicker/DatePicker.js +1 -0
- package/build/components/RadioGroup/RadioGroup.d.ts +5 -2
- package/build/components/RadioGroup/RadioGroup.js +5 -9
- package/build/components/RadioGroup/index.d.ts +1 -1
- package/build/features/app/brand/brandStore.js +14 -3
- package/build/features/app/business/businessStore.d.ts +3 -12
- package/build/features/app/business/businessStore.js +30 -70
- package/build/features/app/connectExpress/connectExpressStore.js +12 -8
- package/build/features/bank/screens/BankDetails/ConfirmPolicy.js +6 -10
- package/build/features/brand/screens/BrandActivities/ActivitiesList.d.ts +0 -5
- package/build/features/brand/screens/BrandActivities/ActivitiesList.js +5 -5
- package/build/features/brand/screens/BrandActivities/CustomerBase.d.ts +0 -5
- package/build/features/brand/screens/BrandActivities/CustomerBase.js +5 -5
- package/build/features/brand/screens/BrandActivities/ExpectedCustomers.js +13 -3
- package/build/features/brand/screens/BrandActivities/ExpectedSalesRange.js +12 -2
- package/build/features/brand/screens/BrandActivities/RefundPolicy.d.ts +5 -1
- package/build/features/brand/screens/BrandActivities/RefundPolicy.js +6 -9
- package/build/features/brand/screens/BrandActivities/TAC.d.ts +12 -0
- package/build/features/brand/screens/BrandActivities/TAC.js +6 -9
- package/build/features/brand/screens/BrandActivities/TransactionPolicy.js +1 -1
- package/build/features/brand/screens/BrandInfo/Segments.js +9 -1
- package/build/features/brand/screens/BrandInfo/TeamSize.js +9 -1
- package/build/features/business/screens/Activities/ActivitiesList.d.ts +0 -5
- package/build/features/business/screens/Activities/ActivitiesList.js +5 -5
- package/build/features/business/screens/Activities/OperationStartDate.js +1 -1
- package/build/features/business/screens/BusinessType/Article.d.ts +3 -1
- package/build/features/business/screens/BusinessType/Article.js +19 -54
- package/build/features/business/screens/BusinessType/BusinessType.js +4 -4
- package/build/features/business/screens/BusinessType/LicenseList.js +1 -1
- package/build/features/business/screens/Customers/CustomerLocations.d.ts +0 -5
- package/build/features/business/screens/Customers/CustomerLocations.js +5 -5
- package/build/features/business/screens/Customers/ExpectedCustomers.js +12 -2
- package/build/features/business/screens/Customers/ExpectedSalesRange.js +12 -2
- package/build/features/business/screens/IDBOD/DOB.js +1 -1
- package/build/features/connect/screens/Merchant/BrandList.js +1 -1
- package/build/features/connect/screens/Merchant/Segments.js +6 -1
- package/build/features/connect/screens/Merchant/TeamSize.js +6 -1
- package/build/features/connectExpress/screens/Brand/Brand.js +1 -1
- package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseList.js +3 -3
- package/build/features/connectExpress/screens/CollectBusinessInfo/LicenseType.js +1 -1
- package/build/features/connectExpress/screens/CollectBusinessInfo/TAC.d.ts +12 -0
- package/build/features/connectExpress/screens/CollectBusinessInfo/TAC.js +6 -9
- package/build/features/connectExpress/screens/NID/TAC.d.ts +12 -0
- package/build/features/connectExpress/screens/NID/TAC.js +6 -9
- package/build/features/entity/screens/EntityCapital/ActivityList.d.ts +0 -5
- package/build/features/entity/screens/EntityCapital/ActivityList.js +5 -5
- package/build/features/entity/screens/EntityName/Article.js +1 -2
- package/build/features/entity/screens/EntityName/EntityTypeList.d.ts +0 -5
- package/build/features/entity/screens/EntityName/EntityTypeList.js +5 -5
- package/build/features/individual/screens/AdditionalIndividualInfo/InfluencerSwitch.js +1 -1
- package/build/features/individual/screens/AdditionalIndividualInfo/MonthlyIncome.js +10 -2
- package/build/features/individual/screens/AdditionalIndividualInfo/Occupation.js +9 -1
- package/build/features/individual/screens/AdditionalIndividualInfo/PEPSwitch.js +1 -1
- package/build/features/individual/screens/AdditionalIndividualInfo/SourceOfIncome.js +9 -1
- package/build/features/individual/screens/IndividualPersonalInfo/BirthCity.js +9 -1
- package/build/features/individual/screens/IndividualPersonalInfo/BirthCountry.js +9 -1
- package/build/features/individual/screens/IndividualPersonalInfo/DOB.js +1 -1
- package/build/features/individual/screens/IndividualPersonalInfo/ExpiryDate.js +1 -1
- package/build/features/individual/screens/IndividualPersonalInfo/Gender.js +1 -1
- package/build/features/individual/screens/IndividualPersonalInfo/IssuedCountry.js +9 -1
- package/build/features/individual/screens/IndividualPersonalInfo/MobileNumber.js +9 -6
- package/build/features/individual/screens/IndividualPersonalInfo/Nationality.js +9 -1
- package/build/features/shared/Address/CountryList.js +1 -1
- package/build/features/shared/Address/InputSelect.js +1 -1
- package/build/features/shared/Input/Input.js +2 -3
- package/build/features/shared/SalesChannels/SaleChannelIconsInput.js +2 -1
- package/build/features/shared/SalesChannels/SalesChannel.js +2 -1
- package/build/features/shared/UploadFile/FileUpload.js +5 -5
- package/build/features/shared/UploadFile/UploadFile.js +7 -7
- package/build/features/shared/UploadMultipleFile/UploadFile.js +5 -5
- package/build/features/tax/screens/TaxDetails/ConfirmPolicy.js +6 -9
- package/build/utils/string.d.ts +1 -1
- package/build/utils/string.js +6 -0
- package/package.json +1 -1
|
@@ -37,6 +37,14 @@ import Input from '../../../shared/Input';
|
|
|
37
37
|
var CountryItemContainer = styled(Box)(function () { return ({
|
|
38
38
|
display: 'flex'
|
|
39
39
|
}); });
|
|
40
|
+
var InputStyled = styled(Input)(function (_a) {
|
|
41
|
+
var readOnly = _a.readOnly;
|
|
42
|
+
return ({
|
|
43
|
+
'& .MuiInputBase-input': {
|
|
44
|
+
cursor: readOnly ? 'default' : 'pointer'
|
|
45
|
+
}
|
|
46
|
+
});
|
|
47
|
+
});
|
|
40
48
|
var CountryNameText = styled(Text, { shouldForwardProp: function (prop) { return prop !== 'isSelected'; } })(function (_a) {
|
|
41
49
|
var theme = _a.theme, isSelected = _a.isSelected;
|
|
42
50
|
return (__assign(__assign({ color: theme.palette.text.primary }, theme.typography.body2), { fontWeight: isSelected ? theme.typography.fontWeightMedium : theme.typography.fontWeightLight, paddingInlineStart: theme.spacing(1.25) }));
|
|
@@ -77,7 +85,7 @@ var BirthCountry = React.forwardRef(function (_a, ref) {
|
|
|
77
85
|
};
|
|
78
86
|
var location = placeOfBirthCountryControl.field.value;
|
|
79
87
|
var error = (_b = placeOfBirthCountryControl.fieldState.error) === null || _b === void 0 ? void 0 : _b.message;
|
|
80
|
-
return (_jsx(Collapse, __assign({ in: rest.show }, { children: _jsxs(ScreenContainer, __assign({ ref: ref, sx: { pt: 2.5 } }, { children: [_jsx(
|
|
88
|
+
return (_jsx(Collapse, __assign({ in: rest.show }, { children: _jsxs(ScreenContainer, __assign({ ref: ref, sx: { pt: 2.5 } }, { children: [_jsx(InputStyled, { label: t('place_of_birth_country_label'), readOnly: readOnly, onClick: !!anchorEl ? function () { return onCloseCountrySelect(); } : onOpenCountrySelect, endAdornment: _jsx(ExpandIcon, { anchorEl: !!anchorEl }), placeholder: t('choose_place_of_birth_country'), value: (isAr ? (_c = location === null || location === void 0 ? void 0 : location.name) === null || _c === void 0 ? void 0 : _c.arabic : (_d = location === null || location === void 0 ? void 0 : location.name) === null || _d === void 0 ? void 0 : _d.english) || '', warningMessage: error && t(error) }), _jsx(Collapse, __assign({ in: !!anchorEl }, { children: _jsx(SimpleList, { searchKeyPath: 'name.english', searchValuePath: ['name.arabic', 'name.english'], list: locationCountries, onSelectItem: onSelectItem, renderItem: function (item) {
|
|
81
89
|
return (_jsxs(_Fragment, { children: [_jsx(CountryItemContainer, { children: _jsx(CountryNameText, __assign({ isSelected: (item === null || item === void 0 ? void 0 : item.idd_prefix) === (location === null || location === void 0 ? void 0 : location.idd_prefix) }, { children: isAr ? item.name.arabic : item.name.english })) }), item.idd_prefix === (location === null || location === void 0 ? void 0 : location.idd_prefix) && _jsx(CheckIconStyled, {})] }));
|
|
82
90
|
} }) }))] })) })));
|
|
83
91
|
});
|
|
@@ -22,7 +22,7 @@ import { ScreenContainer } from '../../../shared/Containers';
|
|
|
22
22
|
import { individualSelector, clearError } from '../../../app/individual/individualStore';
|
|
23
23
|
var InputLabelStyled = styled(Text)(function (_a) {
|
|
24
24
|
var theme = _a.theme;
|
|
25
|
-
return (__assign(__assign({ color: alpha(theme.palette.text.primary, 0.
|
|
25
|
+
return (__assign(__assign({ color: alpha(theme.palette.text.primary, 0.6) }, theme.typography.caption), { cursor: 'pointer' }));
|
|
26
26
|
});
|
|
27
27
|
var BOD = function (_a) {
|
|
28
28
|
var _b;
|
|
@@ -23,7 +23,7 @@ import { ScreenContainer } from '../../../shared/Containers';
|
|
|
23
23
|
import { individualSelector, clearError } from '../../../app/individual/individualStore';
|
|
24
24
|
var InputLabelStyled = styled(Text)(function (_a) {
|
|
25
25
|
var theme = _a.theme;
|
|
26
|
-
return (__assign(__assign({ color: alpha(theme.palette.text.primary, 0.
|
|
26
|
+
return (__assign(__assign({ color: alpha(theme.palette.text.primary, 0.6) }, theme.typography.caption), { cursor: 'pointer' }));
|
|
27
27
|
});
|
|
28
28
|
var ExpiryDate = function (_a) {
|
|
29
29
|
var _b;
|
|
@@ -78,6 +78,6 @@ var Gender = function (_a) {
|
|
|
78
78
|
genderControl.field.onChange(target.value);
|
|
79
79
|
};
|
|
80
80
|
var genderValue = genderControl.field.value;
|
|
81
|
-
return (_jsx(Collapse, __assign({ in: show }, { children: _jsxs(ScreenContainer, __assign({ sx: { pb: 2.5, pl: 2.5, pr: 2.5, pt: 2.5 } }, { children: [_jsx(LabelTextStyled, { children: t('individual_gender_title') }), _jsxs(RadioGroupStyled, __assign({ value: genderValue != null ? genderValue : false, onChange: handleOnChange }, { children: [_jsx(RadioLabel, { value: IndividualGender.MALE, label: _jsx(LabelStyled, { children: t('gender_male') }), control: _jsx(RadioStyled, { color: 'primary', disableFocusRipple: true, disableRipple: true, disableTouchRipple: true, focusRipple: false }) }), _jsx(RadioLabel, { value: IndividualGender.FEMALE, sx: { marginInlineEnd: '0px' }, label: _jsx(LabelStyled, { children: t('gender_female') }), control: _jsx(RadioStyled, { color: 'primary', disableFocusRipple: true, disableRipple: true, disableTouchRipple: true, focusRipple: false }) })] }))] })) })));
|
|
81
|
+
return (_jsx(Collapse, __assign({ in: show }, { children: _jsxs(ScreenContainer, __assign({ sx: { pb: 2.5, pl: 2.5, pr: 2.5, pt: 2.5 } }, { children: [_jsx(LabelTextStyled, { children: t('individual_gender_title') }), _jsxs(RadioGroupStyled, __assign({ readOnly: readOnly, value: genderValue != null ? genderValue : false, onChange: handleOnChange }, { children: [_jsx(RadioLabel, { value: IndividualGender.MALE, label: _jsx(LabelStyled, { children: t('gender_male') }), control: _jsx(RadioStyled, { color: 'primary', disableFocusRipple: true, disableRipple: true, disableTouchRipple: true, focusRipple: false }) }), _jsx(RadioLabel, { value: IndividualGender.FEMALE, sx: { marginInlineEnd: '0px' }, label: _jsx(LabelStyled, { children: t('gender_female') }), control: _jsx(RadioStyled, { color: 'primary', disableFocusRipple: true, disableRipple: true, disableTouchRipple: true, focusRipple: false }) })] }))] })) })));
|
|
82
82
|
};
|
|
83
83
|
export default Gender;
|
|
@@ -37,6 +37,14 @@ import Input from '../../../shared/Input';
|
|
|
37
37
|
var CountryItemContainer = styled(Box)(function () { return ({
|
|
38
38
|
display: 'flex'
|
|
39
39
|
}); });
|
|
40
|
+
var InputStyled = styled(Input)(function (_a) {
|
|
41
|
+
var readOnly = _a.readOnly;
|
|
42
|
+
return ({
|
|
43
|
+
'& .MuiInputBase-input': {
|
|
44
|
+
cursor: readOnly ? 'default' : 'pointer'
|
|
45
|
+
}
|
|
46
|
+
});
|
|
47
|
+
});
|
|
40
48
|
var CountryNameText = styled(Text, { shouldForwardProp: function (prop) { return prop !== 'isSelected'; } })(function (_a) {
|
|
41
49
|
var theme = _a.theme, isSelected = _a.isSelected;
|
|
42
50
|
return (__assign(__assign({ color: theme.palette.text.primary }, theme.typography.body2), { fontWeight: isSelected ? theme.typography.fontWeightMedium : theme.typography.fontWeightLight, paddingInlineStart: theme.spacing(1.25) }));
|
|
@@ -78,7 +86,7 @@ var IssuedCountry = React.forwardRef(function (_a, ref) {
|
|
|
78
86
|
};
|
|
79
87
|
var location = issuedCountryControl.field.value;
|
|
80
88
|
var error = (_b = issuedCountryControl.fieldState.error) === null || _b === void 0 ? void 0 : _b.message;
|
|
81
|
-
return (_jsx(Collapse, __assign({ in: rest.show }, { children: _jsxs(ScreenContainer, __assign({ ref: ref, sx: { pt: 2.5 } }, { children: [_jsx(
|
|
89
|
+
return (_jsx(Collapse, __assign({ in: rest.show }, { children: _jsxs(ScreenContainer, __assign({ ref: ref, sx: { pt: 2.5 } }, { children: [_jsx(InputStyled, { label: t('issued_country_label'), readOnly: readOnly, disabled: disabled, onClick: disabled ? undefined : !!anchorEl ? function () { return onCloseCountrySelect(); } : onOpenCountrySelect, endAdornment: disabled ? _jsx(_Fragment, {}) : _jsx(ExpandIcon, { anchorEl: !!anchorEl }), placeholder: t('choose_issued_country'), value: (isAr ? (_c = location === null || location === void 0 ? void 0 : location.name) === null || _c === void 0 ? void 0 : _c.arabic : (_d = location === null || location === void 0 ? void 0 : location.name) === null || _d === void 0 ? void 0 : _d.english) || '', warningMessage: error && t(error) }), _jsx(Collapse, __assign({ in: !!anchorEl }, { children: _jsx(SimpleList, { searchKeyPath: 'name.english', searchValuePath: ['name.arabic', 'name.english'], list: locationCountries, onSelectItem: onSelectItem, renderItem: function (item) {
|
|
82
90
|
return (_jsxs(_Fragment, { children: [_jsx(CountryItemContainer, { children: _jsx(CountryNameText, __assign({ isSelected: (item === null || item === void 0 ? void 0 : item.idd_prefix) === (location === null || location === void 0 ? void 0 : location.idd_prefix) }, { children: isAr ? item.name.arabic : item.name.english })) }), item.idd_prefix === (location === null || location === void 0 ? void 0 : location.idd_prefix) && _jsx(CheckIconStyled, {})] }));
|
|
83
91
|
} }) }))] })) })));
|
|
84
92
|
});
|
|
@@ -72,12 +72,15 @@ var ExpandIconStyled = styled(ExpandIcon)(function (_a) {
|
|
|
72
72
|
marginInlineStart: theme.spacing(1)
|
|
73
73
|
});
|
|
74
74
|
});
|
|
75
|
-
var InputStyled = styled(Input)(function () {
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
75
|
+
var InputStyled = styled(Input)(function (_a) {
|
|
76
|
+
var readOnly = _a.readOnly;
|
|
77
|
+
return ({
|
|
78
|
+
direction: 'ltr',
|
|
79
|
+
'& .MuiInputBase-input': {
|
|
80
|
+
cursor: readOnly ? 'default' : 'pointer'
|
|
81
|
+
}
|
|
82
|
+
});
|
|
83
|
+
});
|
|
81
84
|
var MobileNumber = React.forwardRef(function (_a, ref) {
|
|
82
85
|
var _b, _c, _d;
|
|
83
86
|
var countries = _a.countries, readOnly = _a.readOnly, rest = __rest(_a, ["countries", "readOnly"]);
|
|
@@ -37,6 +37,14 @@ import Input from '../../../shared/Input';
|
|
|
37
37
|
var CountryItemContainer = styled(Box)(function () { return ({
|
|
38
38
|
display: 'flex'
|
|
39
39
|
}); });
|
|
40
|
+
var InputStyled = styled(Input)(function (_a) {
|
|
41
|
+
var readOnly = _a.readOnly;
|
|
42
|
+
return ({
|
|
43
|
+
'& .MuiInputBase-input': {
|
|
44
|
+
cursor: readOnly ? 'default' : 'pointer'
|
|
45
|
+
}
|
|
46
|
+
});
|
|
47
|
+
});
|
|
40
48
|
var CountryNameText = styled(Text, { shouldForwardProp: function (prop) { return prop !== 'isSelected'; } })(function (_a) {
|
|
41
49
|
var theme = _a.theme, isSelected = _a.isSelected;
|
|
42
50
|
return (__assign(__assign({ color: theme.palette.text.primary }, theme.typography.body2), { fontWeight: isSelected ? theme.typography.fontWeightMedium : theme.typography.fontWeightLight, paddingInlineStart: theme.spacing(1.25) }));
|
|
@@ -78,7 +86,7 @@ var Nationality = React.forwardRef(function (_a, ref) {
|
|
|
78
86
|
};
|
|
79
87
|
var location = nationalityControl.field.value;
|
|
80
88
|
var error = (_b = nationalityControl.fieldState.error) === null || _b === void 0 ? void 0 : _b.message;
|
|
81
|
-
return (_jsx(Collapse, __assign({ in: rest.show }, { children: _jsxs(ScreenContainer, __assign({ ref: ref, sx: { pt: 2.5 } }, { children: [_jsx(
|
|
89
|
+
return (_jsx(Collapse, __assign({ in: rest.show }, { children: _jsxs(ScreenContainer, __assign({ ref: ref, sx: { pt: 2.5 } }, { children: [_jsx(InputStyled, { label: t('nationality_label'), readOnly: readOnly, disabled: disabled, onClick: disabled ? undefined : !!anchorEl ? function () { return onCloseCountrySelect(); } : onOpenCountrySelect, endAdornment: disabled ? _jsx(_Fragment, {}) : _jsx(ExpandIcon, { anchorEl: !!anchorEl }), placeholder: t('choose_nationality'), value: (isAr ? (_c = location === null || location === void 0 ? void 0 : location.name) === null || _c === void 0 ? void 0 : _c.arabic : (_d = location === null || location === void 0 ? void 0 : location.name) === null || _d === void 0 ? void 0 : _d.english) || '', warningMessage: error && t(error) }), _jsx(Collapse, __assign({ in: !!anchorEl }, { children: _jsx(SimpleList, { searchKeyPath: 'name.english', searchValuePath: ['name.arabic', 'name.english'], list: locationCountries, onSelectItem: onSelectItem, renderItem: function (item) {
|
|
82
90
|
return (_jsxs(_Fragment, { children: [_jsx(CountryItemContainer, { children: _jsx(CountryNameText, __assign({ isSelected: (item === null || item === void 0 ? void 0 : item.idd_prefix) === (location === null || location === void 0 ? void 0 : location.idd_prefix) }, { children: isAr ? item.name.arabic : item.name.english })) }), item.idd_prefix === (location === null || location === void 0 ? void 0 : location.idd_prefix) && _jsx(CheckIconStyled, {})] }));
|
|
83
91
|
} }) }))] })) })));
|
|
84
92
|
});
|
|
@@ -80,7 +80,7 @@ function CountryList(_a) {
|
|
|
80
80
|
return '';
|
|
81
81
|
return isAr ? item.name.arabic : item.name.english;
|
|
82
82
|
}, [isAr, list, value]);
|
|
83
|
-
return (_jsxs(Box, { children: [_jsx(LabelContainerStyled, { children: _jsxs(InputLabelStyled, { children: [t(label), " ", isRequired && _jsx(MandatoryStyled, { children: "*" })] }) }), _jsxs(Box, { children: [_jsx(InputStyled, {
|
|
83
|
+
return (_jsxs(Box, { children: [_jsx(LabelContainerStyled, { children: _jsxs(InputLabelStyled, { children: [t(label), " ", isRequired && _jsx(MandatoryStyled, { children: "*" })] }) }), _jsxs(Box, { children: [_jsx(InputStyled, { value: nameValue, placeholder: placeholder, onClick: handleListOpenClose, endAdornment: !disabled && _jsx(ExpandIcon, { anchorEl: !!anchorEl }) }), _jsx(Collapse, __assign({ in: !!anchorEl }, { children: _jsx(SimpleListStyled, { searchValuePath: ['name.english', 'name.arabic'], searchKeyPath: 'name.english', list: list, onSelectItem: handleValueChange, renderItem: function (item) {
|
|
84
84
|
var _a, _b;
|
|
85
85
|
var isChecked = item.countryId === value;
|
|
86
86
|
return (_jsxs(_Fragment, { children: [_jsx(Box, __assign({ display: 'flex' }, { children: _jsx(NameContainer, __assign({ isSelected: isChecked }, { children: isAr ? (_a = item.name) === null || _a === void 0 ? void 0 : _a.arabic : (_b = item.name) === null || _b === void 0 ? void 0 : _b.english })) })), isChecked && _jsx(CheckIconStyled, {})] }));
|
|
@@ -141,7 +141,7 @@ function InputSelect(_a) {
|
|
|
141
141
|
return React.useMemo(function () {
|
|
142
142
|
if (data.length === 0 && countryIso2)
|
|
143
143
|
return (_jsx(InputText, { label: label, onChange: function (value) { return onSelect(value); }, placeholder: placeholder, isRequired: isRequired, value: value, error: error }, 'input-text'));
|
|
144
|
-
return (_jsxs(Box, { children: [_jsx(LabelContainerStyled, { children: _jsxs(InputLabelStyled, { children: [t(label), " ", isRequired && _jsx(MandatoryStyled, { children: "*" })] }) }), _jsxs(Box, { children: [_jsx(InputStyled, {
|
|
144
|
+
return (_jsxs(Box, { children: [_jsx(LabelContainerStyled, { children: _jsxs(InputLabelStyled, { children: [t(label), " ", isRequired && _jsx(MandatoryStyled, { children: "*" })] }) }), _jsxs(Box, { children: [_jsx(InputStyled, { value: nameValue, placeholder: placeholder, onClick: handleListOpenClose, endAdornment: loading ? _jsx(CircularProgress, { size: 25, thickness: 5 }) : _jsx(ExpandIcon, { anchorEl: !!anchorEl }) }), _jsx(Collapse, __assign({ in: !!anchorEl }, { children: _jsx(SimpleListStyled, { searchValuePath: ['name.en', 'name.ar'], searchKeyPath: 'name.en', list: data, onSelectItem: function (item) {
|
|
145
145
|
onSelect(item.id);
|
|
146
146
|
setAnchorEl(null);
|
|
147
147
|
}, renderItem: function (item) {
|
|
@@ -37,9 +37,8 @@ export var InputStyled = styled(Input)(function (_a) {
|
|
|
37
37
|
}, '&.MuiInputBase-adornedStart': {
|
|
38
38
|
paddingInlineStart: theme.spacing(2.5)
|
|
39
39
|
} }, (readOnly && {
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
}
|
|
40
|
+
cursor: 'default',
|
|
41
|
+
opacity: '0.6'
|
|
43
42
|
})));
|
|
44
43
|
});
|
|
45
44
|
var LabelContainerStyled = styled(Box)(function (_a) {
|
|
@@ -31,10 +31,11 @@ var SocialMediaGroupStyled = styled(SocialMediaGroup)(function (_a) {
|
|
|
31
31
|
});
|
|
32
32
|
});
|
|
33
33
|
var InputStyled = styled(Input)(function (_a) {
|
|
34
|
-
var theme = _a.theme;
|
|
34
|
+
var theme = _a.theme, readOnly = _a.readOnly;
|
|
35
35
|
return ({
|
|
36
36
|
padding: theme.spacing(0, 2, 0, 0),
|
|
37
37
|
paddingInlineEnd: theme.spacing(2),
|
|
38
|
+
opacity: readOnly ? 0.6 : 1,
|
|
38
39
|
input: {
|
|
39
40
|
paddingInlineStart: theme.spacing(0)
|
|
40
41
|
}
|
|
@@ -50,10 +50,11 @@ var TextStyled = styled(Text)(function (_a) {
|
|
|
50
50
|
return (__assign(__assign({ color: alpha(theme.palette.text.primary, 0.4), fontWeight: theme.typography.fontWeightLight, whiteSpace: 'pre' }, theme.typography.body2), { marginBlockStart: theme.spacing(1.75) }));
|
|
51
51
|
});
|
|
52
52
|
var CheckBoxStyled = styled(CheckBox)(function (_a) {
|
|
53
|
-
var theme = _a.theme;
|
|
53
|
+
var theme = _a.theme, disabled = _a.disabled;
|
|
54
54
|
return ({
|
|
55
55
|
paddingInline: '15px',
|
|
56
56
|
marginInlineEnd: theme.spacing(-1),
|
|
57
|
+
opacity: disabled ? 0.6 : 1,
|
|
57
58
|
'& .MuiSvgIcon-root': {
|
|
58
59
|
fontSize: 30
|
|
59
60
|
},
|
|
@@ -60,9 +60,9 @@ import { maskFileName } from '../../../utils';
|
|
|
60
60
|
import API from '../../../api';
|
|
61
61
|
import { DeleteFileStatus, FileStatus, ICONS_NAMES, MAX_FILE_SIZE_FOUR_MB, VALID_FILE_FORMATS, FileRemoveType } from '../../../constants';
|
|
62
62
|
import CheckIcon from '../../shared/CheckIcon';
|
|
63
|
-
var BoxStyled = styled(Box)(function (_a) {
|
|
64
|
-
var theme = _a.theme;
|
|
65
|
-
return (__assign(__assign({ direction: theme.direction }, theme.typography.subtitle2), { color: theme.palette.primary.main, fontWeight: theme.typography.fontWeightBold, background: theme.palette.background.default, padding: theme.spacing(0, 2.5, 0), width: '88%', wordBreak: 'break-all', display: 'flex', justifyContent: 'space-between' }));
|
|
63
|
+
var BoxStyled = styled(Box, { shouldForwardProp: function (prop) { return prop !== 'readOnly'; } })(function (_a) {
|
|
64
|
+
var theme = _a.theme, readOnly = _a.readOnly;
|
|
65
|
+
return (__assign(__assign(__assign({ direction: theme.direction }, theme.typography.subtitle2), { color: theme.palette.primary.main, fontWeight: theme.typography.fontWeightBold, background: theme.palette.background.default, padding: theme.spacing(0, 2.5, 0), width: '88%', wordBreak: 'break-all', display: 'flex', justifyContent: 'space-between' }), (readOnly && { opacity: '0.6' })));
|
|
66
66
|
});
|
|
67
67
|
var UploadBoxStyled = styled(Box, { shouldForwardProp: function (prop) { return !['uploading', 'readOnly'].includes(prop.toString()); } })(function (_a) {
|
|
68
68
|
var theme = _a.theme, uploading = _a.uploading, readOnly = _a.readOnly;
|
|
@@ -253,12 +253,12 @@ var FileUpload = function (_a) {
|
|
|
253
253
|
}, [name]);
|
|
254
254
|
var canDownloadFile = fileId && status !== FileStatus.DOWNLOADING;
|
|
255
255
|
var canDeleteFile = status !== FileStatus.UPLOADING && status !== FileStatus.DOWNLOADING;
|
|
256
|
-
return (_jsx(Collapse, __assign({ in: show }, { children: _jsx(Box, __assign({ sx: { pointerEvents: isSubmitting ? 'none' : 'auto' } }, { children: _jsxs(InputContainerStyled, __assign({ sx: __assign({ borderTop: "1px solid ".concat(alpha(theme.palette.divider, 0.8)), borderBottom: "1px solid ".concat(alpha(theme.palette.divider, 0.8)) }, sx) }, { children: [_jsxs(BoxStyled, { children: [_jsxs(Box, __assign({ sx: {
|
|
256
|
+
return (_jsx(Collapse, __assign({ in: show }, { children: _jsx(Box, __assign({ sx: { pointerEvents: isSubmitting ? 'none' : 'auto' } }, { children: _jsxs(InputContainerStyled, __assign({ sx: __assign({ borderTop: "1px solid ".concat(alpha(theme.palette.divider, 0.8)), borderBottom: "1px solid ".concat(alpha(theme.palette.divider, 0.8)) }, sx) }, { children: [_jsxs(BoxStyled, __assign({ readOnly: readOnly }, { children: [_jsxs(Box, __assign({ sx: {
|
|
257
257
|
display: 'flex',
|
|
258
258
|
flexDirection: 'column',
|
|
259
259
|
padding: theme.spacing(1.5, 0, 1.5),
|
|
260
260
|
width: '100%'
|
|
261
|
-
} }, { children: [_jsxs(Box, __assign({ sx: { display: 'flex', flexDirection: 'row', cursor: canDownloadFile ? 'pointer' : 'auto' }, onClick: canDownloadFile ? function () { return downloadFile(); } : undefined }, { children: [_jsx(Icon, { src: ICONS_NAMES.DOC_ICON }), _jsx(Text, { children: name && maskFileName(name) })] })), _jsx(Box, __assign({ sx: { display: 'flex', flexDirection: 'row', justifyContent: 'center' } }, { children: _jsx(Collapse, __assign({ in: !!error, timeout: 400 }, { children: _jsxs(WarningContainer, { children: [_jsx(WarningIconStyled, { src: ICONS_NAMES.WARNING_ICON }), _jsx(Text, { children: t(error) })] }) })) }))] })), _jsx(ProgressBoxStyled, { children: getProgressComponent() })] }), _jsx(UploadBoxStyled, __assign({ readOnly: readOnly, uploading: status === FileStatus.UPLOADING || status === FileStatus.DOWNLOADING, onClick: function () {
|
|
261
|
+
} }, { children: [_jsxs(Box, __assign({ sx: { display: 'flex', flexDirection: 'row', cursor: canDownloadFile ? 'pointer' : 'auto' }, onClick: canDownloadFile ? function () { return downloadFile(); } : undefined }, { children: [_jsx(Icon, { src: ICONS_NAMES.DOC_ICON }), _jsx(Text, { children: name && maskFileName(name) })] })), _jsx(Box, __assign({ sx: { display: 'flex', flexDirection: 'row', justifyContent: 'center' } }, { children: _jsx(Collapse, __assign({ in: !!error, timeout: 400 }, { children: _jsxs(WarningContainer, { children: [_jsx(WarningIconStyled, { src: ICONS_NAMES.WARNING_ICON }), _jsx(Text, { children: t(error) })] }) })) }))] })), _jsx(ProgressBoxStyled, { children: getProgressComponent() })] })), _jsx(UploadBoxStyled, __assign({ readOnly: readOnly, uploading: status === FileStatus.UPLOADING || status === FileStatus.DOWNLOADING, onClick: function () {
|
|
262
262
|
if (readOnly)
|
|
263
263
|
return;
|
|
264
264
|
canDeleteFile && handleDeleteFile();
|
|
@@ -11,7 +11,7 @@ var __assign = (this && this.__assign) || function () {
|
|
|
11
11
|
};
|
|
12
12
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
13
13
|
import React from 'react';
|
|
14
|
-
import { styled } from '@mui/material/styles';
|
|
14
|
+
import { styled, alpha } from '@mui/material/styles';
|
|
15
15
|
import { ScreenContainer } from '../../shared/Containers';
|
|
16
16
|
import Box from '@mui/material/Box';
|
|
17
17
|
import { InputLabelStyled } from '../../shared/Input/Input';
|
|
@@ -38,13 +38,13 @@ var LabelContainerStyled = styled(Box)(function (_a) {
|
|
|
38
38
|
padding: theme.spacing(0, 2.5, 1.25, 2.5)
|
|
39
39
|
});
|
|
40
40
|
});
|
|
41
|
-
var BoxStyled = styled(Box)(function (_a) {
|
|
42
|
-
var theme = _a.theme;
|
|
43
|
-
return (__assign(__assign({ direction: theme.direction }, theme.typography.subtitle2), { color: theme.palette.primary.main, fontWeight: theme.typography.fontWeightBold, background: theme.palette.background.default, padding: theme.spacing(1.5, 2.5, 1.5), width: '88%', wordBreak: 'break-all', display: 'flex', justifyContent: 'space-between' }));
|
|
41
|
+
var BoxStyled = styled(Box, { shouldForwardProp: function (prop) { return prop !== 'readOnly'; } })(function (_a) {
|
|
42
|
+
var theme = _a.theme, readOnly = _a.readOnly;
|
|
43
|
+
return (__assign(__assign(__assign({ direction: theme.direction }, theme.typography.subtitle2), { color: theme.palette.primary.main, fontWeight: theme.typography.fontWeightBold, background: theme.palette.background.default, padding: theme.spacing(1.5, 2.5, 1.5), width: '88%', wordBreak: 'break-all', display: 'flex', justifyContent: 'space-between' }), (readOnly && { opacity: '0.6' })));
|
|
44
44
|
});
|
|
45
|
-
var UploadBoxStyled = styled(Box)(function (_a) {
|
|
46
|
-
var theme = _a.theme;
|
|
47
|
-
return (__assign(__assign({}, theme.typography.caption), { background: theme.palette.primary.main, color: theme.palette.common.white, fontWeight: theme.typography.fontWeightRegular, cursor: 'pointer', width: '12%', display: 'flex', justifyContent: 'center', alignItems: 'center' }));
|
|
45
|
+
var UploadBoxStyled = styled(Box, { shouldForwardProp: function (prop) { return prop !== 'readOnly'; } })(function (_a) {
|
|
46
|
+
var theme = _a.theme, readOnly = _a.readOnly;
|
|
47
|
+
return (__assign(__assign(__assign({}, theme.typography.caption), { background: theme.palette.primary.main, color: theme.palette.common.white, fontWeight: theme.typography.fontWeightRegular, cursor: 'pointer', width: '12%', display: 'flex', justifyContent: 'center', alignItems: 'center' }), (readOnly && { background: alpha(theme.palette.primary.main, 0.5), cursor: 'default' })));
|
|
48
48
|
});
|
|
49
49
|
var ClearIconStyled = styled(ClearIcon)(function (_a) {
|
|
50
50
|
var theme = _a.theme;
|
|
@@ -60,9 +60,9 @@ import { maskFileName } from '../../../utils';
|
|
|
60
60
|
import API from '../../../api';
|
|
61
61
|
import { DeleteFileStatus, FileStatus, ICONS_NAMES, MAX_FILE_SIZE_FOUR_MB, VALID_FILE_FORMATS } from '../../../constants';
|
|
62
62
|
import CheckIcon from '../../shared/CheckIcon';
|
|
63
|
-
var BoxStyled = styled(Box)(function (_a) {
|
|
64
|
-
var theme = _a.theme;
|
|
65
|
-
return (__assign(__assign({ direction: theme.direction }, theme.typography.subtitle2), { color: theme.palette.primary.main, fontWeight: theme.typography.fontWeightBold, background: theme.palette.background.default, padding: theme.spacing(0, 2.5, 0), width: '88%', wordBreak: 'break-all', display: 'flex', justifyContent: 'space-between' }));
|
|
63
|
+
var BoxStyled = styled(Box, { shouldForwardProp: function (prop) { return prop !== 'readOnly'; } })(function (_a) {
|
|
64
|
+
var theme = _a.theme, readOnly = _a.readOnly;
|
|
65
|
+
return (__assign(__assign(__assign({ direction: theme.direction }, theme.typography.subtitle2), { color: theme.palette.primary.main, fontWeight: theme.typography.fontWeightBold, background: theme.palette.background.default, padding: theme.spacing(0, 2.5, 0), width: '88%', wordBreak: 'break-all', display: 'flex', justifyContent: 'space-between' }), (readOnly && { opacity: '0.6' })));
|
|
66
66
|
});
|
|
67
67
|
var UploadBoxStyled = styled(Box, { shouldForwardProp: function (prop) { return !['uploading', 'readOnly'].includes(prop.toString()); } })(function (_a) {
|
|
68
68
|
var theme = _a.theme, uploading = _a.uploading, readOnly = _a.readOnly;
|
|
@@ -259,12 +259,12 @@ var UploadFile = function (_a) {
|
|
|
259
259
|
}, []);
|
|
260
260
|
var canDownloadFile = uploadedFile.fileId && status !== FileStatus.DOWNLOADING;
|
|
261
261
|
var canDeleteFile = !isAnyFileDoingDeleteUploadDownload;
|
|
262
|
-
return (_jsx(Box, __assign({ sx: { pointerEvents: isSubmitting ? 'none' : 'auto' } }, { children: _jsxs(InputContainerStyled, __assign({ sx: __assign({ borderTop: "1px solid ".concat(alpha(theme.palette.divider, 0.8)) }, sx) }, { children: [_jsxs(BoxStyled, { children: [_jsxs(Box, __assign({ sx: {
|
|
262
|
+
return (_jsx(Box, __assign({ sx: { pointerEvents: isSubmitting ? 'none' : 'auto' } }, { children: _jsxs(InputContainerStyled, __assign({ sx: __assign({ borderTop: "1px solid ".concat(alpha(theme.palette.divider, 0.8)) }, sx) }, { children: [_jsxs(BoxStyled, __assign({ readOnly: readOnly }, { children: [_jsxs(Box, __assign({ sx: {
|
|
263
263
|
display: 'flex',
|
|
264
264
|
flexDirection: 'column',
|
|
265
265
|
padding: theme.spacing(1.5, 0, 1.5),
|
|
266
266
|
width: '100%'
|
|
267
|
-
} }, { children: [_jsxs(Box, __assign({ sx: { display: 'flex', flexDirection: 'row', cursor: canDownloadFile ? 'pointer' : 'auto' }, onClick: canDownloadFile ? function () { return downloadFile(); } : undefined }, { children: [_jsx(Icon, { src: ICONS_NAMES.DOC_ICON }), _jsx(Text, { children: maskFileName(name) })] })), _jsx(Box, __assign({ sx: { display: 'flex', flexDirection: 'row', justifyContent: 'center' } }, { children: _jsx(Collapse, __assign({ in: !!error, timeout: 400 }, { children: _jsxs(WarningContainer, { children: [_jsx(WarningIconStyled, { src: ICONS_NAMES.WARNING_ICON }), _jsx(Text, { children: t(error) })] }) })) }))] })), _jsx(ProgressBoxStyled, { children: getProgressComponent() })] }), _jsx(UploadBoxStyled, __assign({ readOnly: readOnly, uploading: status === FileStatus.UPLOADING || (!!isAnyFileDoingDeleteUploadDownload && deleteStatus !== DeleteFileStatus.DELETING), onClick: function () {
|
|
267
|
+
} }, { children: [_jsxs(Box, __assign({ sx: { display: 'flex', flexDirection: 'row', cursor: canDownloadFile ? 'pointer' : 'auto' }, onClick: canDownloadFile ? function () { return downloadFile(); } : undefined }, { children: [_jsx(Icon, { src: ICONS_NAMES.DOC_ICON }), _jsx(Text, { children: maskFileName(name) })] })), _jsx(Box, __assign({ sx: { display: 'flex', flexDirection: 'row', justifyContent: 'center' } }, { children: _jsx(Collapse, __assign({ in: !!error, timeout: 400 }, { children: _jsxs(WarningContainer, { children: [_jsx(WarningIconStyled, { src: ICONS_NAMES.WARNING_ICON }), _jsx(Text, { children: t(error) })] }) })) }))] })), _jsx(ProgressBoxStyled, { children: getProgressComponent() })] })), _jsx(UploadBoxStyled, __assign({ readOnly: readOnly, uploading: status === FileStatus.UPLOADING || (!!isAnyFileDoingDeleteUploadDownload && deleteStatus !== DeleteFileStatus.DELETING), onClick: function () {
|
|
268
268
|
if (readOnly)
|
|
269
269
|
return;
|
|
270
270
|
canDeleteFile && handleDeleteFile(index);
|
|
@@ -19,14 +19,11 @@ import CheckBox from '../../../../components/CheckBox';
|
|
|
19
19
|
import Text from '../../../../components/Text';
|
|
20
20
|
import Warning from '../../../../components/Warning';
|
|
21
21
|
import Collapse from '../../../../components/Collapse';
|
|
22
|
-
var ConfirmContainerStyled = styled(Box)(function (_a) {
|
|
23
|
-
var theme = _a.theme;
|
|
24
|
-
return ({
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
alignItems: 'center',
|
|
28
|
-
padding: theme.spacing(0, 2.5, 0, 2.5)
|
|
29
|
-
});
|
|
22
|
+
var ConfirmContainerStyled = styled(Box, { shouldForwardProp: function (prop) { return prop !== 'readOnly'; } })(function (_a) {
|
|
23
|
+
var theme = _a.theme, readOnly = _a.readOnly;
|
|
24
|
+
return (__assign({ display: 'flex', flexDirection: 'row', alignItems: 'center', padding: theme.spacing(0, 2.5, 0, 2.5) }, (readOnly && {
|
|
25
|
+
opacity: '0.6'
|
|
26
|
+
})));
|
|
30
27
|
});
|
|
31
28
|
var TextStyled = styled(Text)(function (_a) {
|
|
32
29
|
var theme = _a.theme;
|
|
@@ -64,6 +61,6 @@ var ConfirmPolicy = function (_a) {
|
|
|
64
61
|
return;
|
|
65
62
|
confirmControl.field.onChange(checked);
|
|
66
63
|
};
|
|
67
|
-
return (_jsxs(ScreenContainer, { children: [_jsxs(ConfirmContainerStyled, { children: [_jsx(CheckboxStyled, { disableRipple: true, disableFocusRipple: true, focusRipple: false, checked: confirmChecked, onChange: handleConfirmCheckedChange }), _jsx(TextStyled, { children: t('tax_confirm_information') })] }), _jsx(CollapseStyled, __assign({ in: !!warningMessage }, { children: _jsx(Warning, __assign({ warningType: 'alert' }, { children: warningMessage && t(warningMessage) })) }))] }));
|
|
64
|
+
return (_jsxs(ScreenContainer, { children: [_jsxs(ConfirmContainerStyled, __assign({ readOnly: readOnly }, { children: [_jsx(CheckboxStyled, { disableRipple: true, disableFocusRipple: true, focusRipple: false, checked: confirmChecked, onChange: handleConfirmCheckedChange }), _jsx(TextStyled, { children: t('tax_confirm_information') })] })), _jsx(CollapseStyled, __assign({ in: !!warningMessage }, { children: _jsx(Warning, __assign({ warningType: 'alert' }, { children: warningMessage && t(warningMessage) })) }))] }));
|
|
68
65
|
};
|
|
69
66
|
export default ConfirmPolicy;
|
package/build/utils/string.d.ts
CHANGED
|
@@ -42,7 +42,7 @@ export declare const getRequestHeaders: (deviceInfo: DeviceInfo) => {
|
|
|
42
42
|
};
|
|
43
43
|
export declare const removeRequestHeaders: () => void;
|
|
44
44
|
export declare const getBaseUrl: () => string;
|
|
45
|
-
export declare const getScreenNameBasedOnFlow: (flow: string, isAuthorizedUser?: boolean) => "CONNECT_NID_STEP" | "" | "BUSINESS_BUSINESS_TYPE_STEP" | "INDIVIDUAL_PERSONAL_INDIVIDUAL_INFO_STEP" | "INDIVIDUAL_LIST_STEP" | "BANK_BANK_DETAILS_STEP" | "TAX_TAX_DETAILS_STEP";
|
|
45
|
+
export declare const getScreenNameBasedOnFlow: (flow: string, isAuthorizedUser?: boolean) => "CONNECT_NID_STEP" | "" | "BUSINESS_BUSINESS_TYPE_STEP" | "INDIVIDUAL_PERSONAL_INDIVIDUAL_INFO_STEP" | "INDIVIDUAL_LIST_STEP" | "BANK_BANK_DETAILS_STEP" | "TAX_TAX_DETAILS_STEP" | "ENTITY_NAME_STEP" | "BRAND_INFO_STEP";
|
|
46
46
|
export declare const getEighteenYearsAgo: () => string;
|
|
47
47
|
export declare const isKW: (flag: string) => boolean;
|
|
48
48
|
export declare const isSA: (flag: string) => boolean;
|
package/build/utils/string.js
CHANGED
|
@@ -188,6 +188,12 @@ export var getScreenNameBasedOnFlow = function (flow, isAuthorizedUser) {
|
|
|
188
188
|
if (flow === FlowsTypes.TAX) {
|
|
189
189
|
return 'TAX_TAX_DETAILS_STEP';
|
|
190
190
|
}
|
|
191
|
+
if (flow === FlowsTypes.BRAND) {
|
|
192
|
+
return 'BRAND_INFO_STEP';
|
|
193
|
+
}
|
|
194
|
+
if (flow === FlowsTypes.ENTITY) {
|
|
195
|
+
return 'ENTITY_NAME_STEP';
|
|
196
|
+
}
|
|
191
197
|
return '';
|
|
192
198
|
};
|
|
193
199
|
export var getEighteenYearsAgo = function () {
|