Skip to content

Commit

Permalink
feat: move the pin rules below the pin input
Browse files Browse the repository at this point in the history
Signed-off-by: FarjadGov14 <[email protected]>
  • Loading branch information
FarjadGov14 committed Nov 14, 2024
1 parent 2397235 commit 600d001
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions packages/legacy/core/App/screens/PINCreate.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -281,24 +281,6 @@ const PINCreate: React.FC<PINCreateProps> = ({ setAuthenticated, explainedStatus
autoFocus={false}
inlineMessage={inlineMessageField1}
/>
{PINSecurity.displayHelper && (
<View style={{ marginBottom: 16 }}>
{PINOneValidations.map((validation, index) => {
return (
<View style={{ flexDirection: 'row' }} key={index}>
{validation.isInvalid ? (
<Icon name="clear" size={iconSize} color={ColorPallet.notification.errorIcon} />
) : (
<Icon name="check" size={iconSize} color={ColorPallet.notification.successIcon} />
)}
<Text style={[TextTheme.normal, { paddingLeft: 4 }]}>
{t(`PINCreate.Helper.${validation.errorName}`)}
</Text>
</View>
)
})}
</View>
)}
<PINInput
label={t('PINCreate.ReenterPIN', { new: updatePin ? t('PINCreate.NewPIN') + ' ' : '' })}
onPINChanged={(p: string) => {
Expand All @@ -321,6 +303,24 @@ const PINCreate: React.FC<PINCreateProps> = ({ setAuthenticated, explainedStatus
ref={PINTwoInputRef}
inlineMessage={inlineMessageField2}
/>
{PINSecurity.displayHelper && (
<View style={{ marginBottom: 16 }}>
{PINOneValidations.map((validation, index) => {
return (
<View style={{ flexDirection: 'row' }} key={index}>
{validation.isInvalid ? (
<Icon name="clear" size={iconSize} color={ColorPallet.notification.errorIcon} />
) : (
<Icon name="check" size={iconSize} color={ColorPallet.notification.successIcon} />
)}
<Text style={[TextTheme.normal, { paddingLeft: 4 }]}>
{t(`PINCreate.Helper.${validation.errorName}`)}
</Text>
</View>
)
})}
</View>
)}
{modalState.visible && (
<AlertModal
title={modalState.title}
Expand Down

0 comments on commit 600d001

Please sign in to comment.