Skip to content

Commit

Permalink
adjusting pinEnter image style
Browse files Browse the repository at this point in the history
Signed-off-by: Caroline Lucas Calheirani <[email protected]>
  • Loading branch information
CarolineLCa committed Jan 29, 2024
1 parent 04b8be7 commit e56f810
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 15 deletions.
20 changes: 8 additions & 12 deletions packages/legacy/core/App/screens/PINEnter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ const PINEnter: React.FC<PINEnterProps> = ({ setAuthenticated, usage = PINEntryU
const [displayNotification, setDisplayNotification] = useState(false)
const [alertModalVisible, setAlertModalVisible] = useState<boolean>(false)
const [biometricsEnrollmentChange, setBiometricsEnrollmentChange] = useState<boolean>(false)
const { ColorPallet, TextTheme, Assets } = useTheme()
const { ColorPallet, TextTheme, Assets, PINEnterTheme } = useTheme()
const { ButtonLoading } = useAnimatedComponents()

const style = StyleSheet.create({
Expand All @@ -70,6 +70,12 @@ const PINEnter: React.FC<PINEnterProps> = ({ setAuthenticated, usage = PINEntryU
...TextTheme.popupModalText,
marginVertical: 5,
},
image: {
...PINEnterTheme.image,
height: Assets.img.logoSecondary.height,
width: Assets.img.logoSecondary.width,
resizeMode: Assets.img.logoSecondary.resizeMode,
},
})

// listen for biometrics error event
Expand Down Expand Up @@ -294,17 +300,7 @@ const PINEnter: React.FC<PINEnterProps> = ({ setAuthenticated, usage = PINEntryU
<StatusBar barStyle={StatusBarStyles.Light} />
<View style={style.screenContainer}>
<View style={style.contentContainer}>
<Image
source={Assets.img.logoSecondary.src}
style={{
height: Assets.img.logoSecondary.height,
width: Assets.img.logoSecondary.width,
resizeMode: Assets.img.logoSecondary.resizeMode,
alignSelf: 'center',
marginBottom: 20,
marginTop: 30,
}}
/>
<Image source={Assets.img.logoSecondary.src} style={style.image} />
{biometricsEnrollmentChange ? (
<>
<Text style={[TextTheme.normal, { alignSelf: 'center', textAlign: 'center' }]}>
Expand Down
9 changes: 8 additions & 1 deletion packages/legacy/core/App/theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -786,7 +786,12 @@ export const DialogTheme = {
const LoadingTheme = {
backgroundColor: ColorPallet.brand.modalPrimaryBackground,
}

const PINEnterTheme = {
image: {
alignSelf: 'center',
marginBottom: 20,
},
}
const PINInputTheme = {
cell: {
backgroundColor: ColorPallet.brand.secondaryBackground,
Expand Down Expand Up @@ -858,6 +863,7 @@ export interface ITheme {
OnboardingTheme: any
DialogTheme: any
LoadingTheme: any
PINEnterTheme: any
PINInputTheme: any
heavyOpacity: any
borderRadius: any
Expand All @@ -879,6 +885,7 @@ export const theme: ITheme = {
OnboardingTheme,
DialogTheme,
LoadingTheme,
PINEnterTheme,
PINInputTheme,
heavyOpacity,
borderRadius,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ exports[`displays a PIN Enter screen PIN Enter renders correctly 1`] = `
"alignSelf": "center",
"height": 120,
"marginBottom": 20,
"marginTop": 30,
"resizeMode": "contain",
"width": 120,
}
Expand Down Expand Up @@ -527,7 +526,6 @@ exports[`displays a PIN Enter screen PIN Enter renders correctly when logged out
"alignSelf": "center",
"height": 120,
"marginBottom": 20,
"marginTop": 30,
"resizeMode": "contain",
"width": 120,
}
Expand Down

0 comments on commit e56f810

Please sign in to comment.