From 6b5eb0155cf97c193e366b94243fdf844930bf0d Mon Sep 17 00:00:00 2001 From: JJ Adonis Date: Tue, 16 Nov 2021 16:52:01 +0800 Subject: [PATCH] `dex` - lint (#1305) * bump loans to Beta * `hasBetaFeatures` flag * update snapshot * updates * updates * updates * updates * merge --- .../AppNavigator/screens/Dex/DexScreen.tsx | 38 ++++++++++++++----- 1 file changed, 28 insertions(+), 10 deletions(-) diff --git a/mobile-app/app/screens/AppNavigator/screens/Dex/DexScreen.tsx b/mobile-app/app/screens/AppNavigator/screens/Dex/DexScreen.tsx index 1a85653949..b4cb40014f 100644 --- a/mobile-app/app/screens/AppNavigator/screens/Dex/DexScreen.tsx +++ b/mobile-app/app/screens/AppNavigator/screens/Dex/DexScreen.tsx @@ -108,7 +108,8 @@ export function DexScreen (): JSX.Element { style={tailwind('flex flex-row px-4 py-3')} > - {translate('screens/DexScreen', 'Total Value Locked (USD)')} + {translate('screens/DexScreen', 'Total Value Locked (USD)')} , availablePairs: Array>, onAdd: (data: PoolPairData) => void, onRemove: (data: PoolPairData) => void }): JSX.Element { +}: { yourPairs: Array<{ type: string, data: WalletToken }>, availablePairs: Array>, onAdd: (data: PoolPairData) => void, onRemove: (data: PoolPairData) => void }): JSX.Element { return ( index.toString()} testID='your_liquidity_tab' - renderItem={({ item, index }: {item: {type: string, data: WalletToken}, index: number}): JSX.Element => { + renderItem={({ + item, + index + }: { item: { type: string, data: WalletToken }, index: number }): JSX.Element => { const { data: yourPair } = item const poolPairData = availablePairs.find(pr => pr.data.symbol === (yourPair as AddressToken).symbol) const mappedPair = poolPairData?.data @@ -273,7 +277,10 @@ function AvailablePoolPairCards ({ numColumns={1} keyExtractor={(_item, index) => index.toString()} testID='available_liquidity_tab' - renderItem={({ item, index }: {item: DexItem, index: number}): JSX.Element => { + renderItem={({ + item, + index + }: { item: DexItem, index: number }): JSX.Element => { const { data: pair } = item const [symbolA, symbolB] = (pair?.tokenA != null && pair?.tokenB != null) ? [pair.tokenA.displaySymbol, pair.tokenB.displaySymbol] @@ -297,7 +304,8 @@ function AvailablePoolPairCards ({ - + void, onRemove: () => void, symbol: string }): JSX.Element { - const { onAdd, onRemove, symbol } = props +function PoolPairActions (props: { onAdd: () => void, onRemove: () => void, symbol: string }): JSX.Element { + const { + onAdd, + onRemove, + symbol + } = props return (