@@ -322,7 +322,7 @@ const CustomFormWizard = (props) => {
tncFlag = false
}
const preferLocale = locale === 'en' ? 'en': locale === 'zh-HK' ? 'zh_HK': 'zh-CN'
const preferLocale = locale === 'en' ? 'en' : locale === 'zh-HK' ? 'zh_HK' : 'zh-CN'
const formData = {
enName: iAmSmartData.enName,
chName: iAmSmartData.chName,
@@ -337,7 +337,7 @@ const CustomFormWizard = (props) => {
userAddress: JSON.stringify(userAddress),
captcha: base64Url,
checkCode: checkCode,
preferLocale:preferLocale
preferLocale: preferLocale
};
if (isValid) {
@@ -369,7 +369,7 @@ const CustomFormWizard = (props) => {
}
function handleCaptcha(captchaField) {
if (captchaField.length == 5 ){
if (captchaField.length == 5) {
return true
} else {
return false
@@ -437,7 +437,7 @@ const CustomFormWizard = (props) => {
<div style={{ borderBottom: "3px solid #1A4399", width: "100%", margin_right: "15px" }}>
<Typography display="inline" variant="h3" sx={{ color: '#1A4399' }}>
<FormattedMessage id="becomeNewPersonalUser" />
</Typography><img src={iAmSmartICon} alt="iAM Smart" width="50" />
</Typography>
</div>
<Typography mt={0.25} variant="h6" sx={{ color: '#f10000' }}>
@@ -507,61 +507,76 @@ const CustomFormWizard = (props) => {
<Typography variant="h5">
<FormattedMessage id="formAddress" />
<span style={{ color: '#f10000' }}>*</span>
{iAmSmartData.address1 !="" && iAmSmartData.address1 ==formik.values.address1 ? <img src={iAmSmartICon} alt="iAM Smart" width="25" /> : null}
</Typography>
</InputLabel>
<OutlinedInput
fullWidth
autoFocus
error={Boolean(formik.touched.address1 && formik.errors.address1)}
id="address1-signup"
value={formik.values.address1}
name="address1"
onChange={formik.handleChange}
placeholder={intl.formatMessage({ id: 'addressLine1' })}
onBlur={formik.handleBlur}
inputProps={{
onKeyDown: (e) => {
if (e.key === 'Enter') {
e.preventDefault();
}
},
}}
/>
<OutlinedInput
fullWidth
error={Boolean(formik.touched.address2 && formik.errors.address2)}
id="address2-signup"
value={formik.values.address2}
name="address2"
onBlur={formik.handleBlur}
onChange={formik.handleChange}
placeholder={intl.formatMessage({ id: 'addressLine2' })}
inputProps={{
onKeyDown: (e) => {
if (e.key === 'Enter') {
e.preventDefault();
}
},
}}
/>
<OutlinedInput
fullWidth
error={Boolean(formik.touched.address3 && formik.errors.address3)}
id="address3-signup"
value={formik.values.address3}
name="address3"
onBlur={formik.handleBlur}
onChange={formik.handleChange}
placeholder={intl.formatMessage({ id: 'addressLine3' })}
inputProps={{
onKeyDown: (e) => {
if (e.key === 'Enter') {
e.preventDefault();
}
},
}}
/>
<Stack direction="row" justifyContent="space-between" alignItems="baseline" sx={{ mb: { xs: -0.5, sm: 0.5 } }}>
<OutlinedInput
fullWidth
autoFocus
error={Boolean(formik.touched.address1 && formik.errors.address1)}
id="address1-signup"
value={formik.values.address1}
name="address1"
onChange={formik.handleChange}
placeholder={intl.formatMessage({ id: 'addressLine1' })}
onBlur={formik.handleBlur}
inputProps={{
onKeyDown: (e) => {
if (e.key === 'Enter') {
e.preventDefault();
}
},
}}
/>
{iAmSmartData.address1 != "" && iAmSmartData.address1 == formik.values.address1 ? <img src={iAmSmartICon} alt="iAM Smart" width="25" /> : null}
</Stack>
<Stack direction="column" justifyContent="space-between" alignItems="baseline" sx={{ mb: { xs: -0.5, sm: 0.5 } }}>
<OutlinedInput
fullWidth
error={Boolean(formik.touched.address2 && formik.errors.address2)}
id="address2-signup"
value={formik.values.address2}
name="address2"
onBlur={formik.handleBlur}
onChange={formik.handleChange}
placeholder={intl.formatMessage({ id: 'addressLine2' })}
inputProps={{
onKeyDown: (e) => {
if (e.key === 'Enter') {
e.preventDefault();
}
},
}}
/>
{iAmSmartData.address2 != "" && iAmSmartData.address2 == formik.values.address2 ? <img src={iAmSmartICon} alt="iAM Smart" width="25" /> : null}
</Stack>
<Stack direction="column" justifyContent="space-between" alignItems="baseline" sx={{ mb: { xs: -0.5, sm: 0.5 } }}>
<OutlinedInput
fullWidth
error={Boolean(formik.touched.address3 && formik.errors.address3)}
id="address3-signup"
value={formik.values.address3}
name="address3"
onBlur={formik.handleBlur}
onChange={formik.handleChange}
placeholder={intl.formatMessage({ id: 'addressLine3' })}
inputProps={{
onKeyDown: (e) => {
if (e.key === 'Enter') {
e.preventDefault();
}
},
}}
/>
{iAmSmartData.address3 != "" && iAmSmartData.address3 == formik.values.address3 ? <img src={iAmSmartICon} alt="iAM Smart" width="25" /> : null}
</Stack>
<Autocomplete
disablePortal
id="address4-combo"
@@ -640,7 +655,7 @@ const CustomFormWizard = (props) => {
<Typography variant="h5">
<FormattedMessage id="userContactEmail" />
<span style={{ color: '#f10000' }}>*</span>
{iAmSmartData.email && iAmSmartData.email ==formik.values.email ? <img src={iAmSmartICon} alt="iAM Smart" width="25" /> : null}
{iAmSmartData.email && iAmSmartData.email == formik.values.email ? <img src={iAmSmartICon} alt="iAM Smart" width="25" /> : null}
</Typography>
</InputLabel>
<OutlinedInput
@@ -722,7 +737,7 @@ const CustomFormWizard = (props) => {
<Typography variant="h5">
<FormattedMessage id="userContactNumber" />
<span style={{ color: '#f10000' }}>*</span>
{iAmSmartData.phone && iAmSmartData.phone ==formik.values.phone && iAmSmartData.phoneCountryCode ==formik.values.phoneCountryCode ? <img src={iAmSmartICon} alt="iAM Smart" width="25" /> : null}
{iAmSmartData.phone && iAmSmartData.phone == formik.values.phone && iAmSmartData.phoneCountryCode == formik.values.phoneCountryCode ? <img src={iAmSmartICon} alt="iAM Smart" width="25" /> : null}
</Typography>
</InputLabel>
<Stack direction="row">
@@ -870,7 +885,7 @@ const CustomFormWizard = (props) => {
<Grid item xs={12} md={12}>
<Grid container>
<Grid item xs={12} md={12}>
<Typography variant="h5" sx={{ textAlign: "left", borderRadius: "inherit", borderStyle: "solid", borderWidth: "1px", borderColor: "#0C489E" }}>
<Typography variant="h5" sx={{ textAlign: "left", borderRadius: "inherit", borderStyle: "solid", borderWidth: "1px", borderColor: "#0C489E" }}>
<div style={{ padding: 12 }} dangerouslySetInnerHTML={{ __html: intl.formatMessage({ id: "termsAndCon" }) }} />
</Typography>