Skip to content

Commit

Permalink
imagebackground
Browse files Browse the repository at this point in the history
  • Loading branch information
skylarbarrera authored and jinchung committed Aug 23, 2023
1 parent 5ca13d0 commit 1dcb682
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 11 deletions.
6 changes: 3 additions & 3 deletions src/components/PromoSheet.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useCallback, useEffect, useReducer } from 'react';
import { ImageSourcePropType, StatusBar } from 'react-native';
import { ImageSourcePropType, StatusBar, ImageBackground } from 'react-native';
import LinearGradient from 'react-native-linear-gradient';
import MaskedView from '@react-native-masked-view/masked-view';
import { SheetActionButton, SheetHandle, SlackSheet } from '@/components/sheet';
Expand Down Expand Up @@ -118,7 +118,7 @@ export function PromoSheet({
testID={campaignKey}
>
{/* @ts-ignore */}
<Box as={ImgixImage} height="full" source={backgroundImage}>
<Box as={ImageBackground} height="full" source={backgroundImage}>
<Rows>
<Row>
<Stack space={{ custom: isSmallPhone ? 46 : 54 }}>
Expand All @@ -129,7 +129,7 @@ export function PromoSheet({
>
{/* @ts-ignore */}
<Box
as={ImgixImage}
as={ImageBackground}
height={{
custom: deviceWidth / headerImageAspectRatio,
}}
Expand Down
15 changes: 7 additions & 8 deletions src/screens/hardware-wallets/PairHardwareWalletAgainSheet.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {
} from '@/navigation/HardwareWalletTxNavigator';
import { TryAgainButton } from './components/TryAgainButton';
import { useMMKVBoolean } from 'react-native-mmkv';
import { ImageBackground } from 'react-native';

const INDICATOR_SIZE = 9;

Expand Down Expand Up @@ -124,24 +125,22 @@ export const PairHardwareWalletAgainSheet = () => {
</Inset>
</Box>
<Box marginTop={{ custom: -70 }} style={{ zIndex: -99 }}>
<ImgixImage
source={(isDarkMode ? gridDotsDark : gridDotsLight) as Source}
<ImageBackground
source={isDarkMode ? gridDotsDark : gridDotsLight}
style={{
width: GRID_DOTS_SIZE,
height: GRID_DOTS_SIZE,
alignItems: 'center',
justifyContent: 'center',
}}
size={GRID_DOTS_SIZE}
>
<ImgixImage
source={ledgerNano as Source}
<ImageBackground
source={ledgerNano}
style={{
width: LEDGER_NANO_WIDTH,
height: LEDGER_NANO_HEIGHT,
alignItems: 'center',
}}
size={LEDGER_NANO_HEIGHT}
>
<Box
height={{ custom: 36 }}
Expand Down Expand Up @@ -204,8 +203,8 @@ export const PairHardwareWalletAgainSheet = () => {
</Box>
</Inline>
</Box>
</ImgixImage>
</ImgixImage>
</ImageBackground>
</ImageBackground>
</Box>
{hardwareTXError && (
<Box position="absolute" bottom={{ custom: 20 }} width="full">
Expand Down

0 comments on commit 1dcb682

Please sign in to comment.