Skip to content

Commit 87d862b

Browse files
authored
Merge pull request #1680 from QuickSwap/dev2
2 parents 6d29b42 + 28eba17 commit 87d862b

File tree

5 files changed

+39
-9
lines changed

5 files changed

+39
-9
lines changed

src/assets/images/algebra-logo.png

-1.29 KB
Loading

src/pages/PoolsPage/PoolsPage.tsx

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ import { HypeLabAds } from 'components';
2020
import LockLiquidity from './lpLock/LockLiquidity';
2121
import { useParams } from 'react-router-dom';
2222
import { SingleTokenSupplyLiquidity } from './SingleToken/SupplyLiquidity';
23+
import AlgebraLogo from 'assets/images/algebra-logo.png';
2324

2425
const YourLiquidityPools = lazy(() => import('./YourLiquidityPools'));
2526
const MyLiquidityPoolsV3 = lazy(() => import('./v3/MyLiquidityPoolsV3'));
@@ -77,7 +78,7 @@ const PoolsPage: React.FC = () => {
7778
}, [showPools]);
7879

7980
return (
80-
<Box width='100%' mb={3}>
81+
<Box mb={3} p={3}>
8182
{isMobile ? (
8283
<>
8384
<Box mt={2} className='pageHeading'>
@@ -92,6 +93,19 @@ const PoolsPage: React.FC = () => {
9293
</Box>
9394
)}
9495
</Box>
96+
<Box
97+
style={{
98+
display: 'flex',
99+
alignItems: 'center',
100+
gap: '4px',
101+
justifyContent: 'end',
102+
}}
103+
>
104+
<p>
105+
<span>{t('poweredBy')}</span>
106+
</p>
107+
<img src={AlgebraLogo} alt='poweredby' style={{ width: '72px' }} />
108+
</Box>
95109
{showVersion && (
96110
<Box my={2}>
97111
<VersionToggle />
@@ -108,6 +122,18 @@ const PoolsPage: React.FC = () => {
108122
</Box>
109123
)}
110124
</Box>
125+
<Box
126+
style={{
127+
display: 'flex',
128+
alignItems: 'center',
129+
gap: '4px',
130+
}}
131+
>
132+
<p>
133+
<span>{t('poweredBy')}</span>
134+
</p>
135+
<img src={AlgebraLogo} alt='poweredby' style={{ width: '72px' }} />
136+
</Box>
111137
</Box>
112138
)}
113139
{/* <Box margin='24px auto'>

src/pages/PoolsPage/v3/SupplyLiquidityV3/containers/AddLiquidityButton/index.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,7 @@ export function AddLiquidityButton({
286286
amountToWrap,
287287
wrappingETH,
288288
]);
289+
console.log('------isReady:', isReady)
289290

290291
const onAddLiquidity = () => {
291292
if (expertMode) {

src/pages/PoolsPage/v3/SupplyLiquidityV3/containers/EnterAmounts/index.tsx

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import { useActiveWeb3React } from 'hooks';
1313
import { useUSDCValue } from 'hooks/v3/useUSDCPrice';
1414
import {
1515
NONFUNGIBLE_POSITION_MANAGER_ADDRESSES,
16+
NONFUNGIBLE_POSITION_V4_MANAGER_ADDRESSES,
1617
UNI_NFT_POSITION_MANAGER_ADDRESS,
1718
} from 'constants/v3/addresses';
1819
import { halfAmountSpend, maxAmountSpend } from 'utils/v3/maxAmountSpend';
@@ -26,6 +27,7 @@ import { GlobalConst } from 'constants/index';
2627
import { useTranslation } from 'react-i18next';
2728
import { getGammaPairsForTokens } from 'utils';
2829
import { useSteerPeripheryContract } from 'hooks/useContract';
30+
import { useIsV4 } from 'state/application/hooks';
2931

3032
interface IEnterAmounts {
3133
currencyA: Currency | undefined;
@@ -42,6 +44,7 @@ export function EnterAmounts({
4244
}: IEnterAmounts) {
4345
const { t } = useTranslation();
4446
const { chainId } = useActiveWeb3React();
47+
const { isV4 } = useIsV4();
4548
const preset = useActivePreset();
4649

4750
const { independentField, typedValue } = useV3MintState();
@@ -133,8 +136,10 @@ export function EnterAmounts({
133136
if (mintInfo.feeTier && mintInfo.feeTier.id.includes('uni')) {
134137
return UNI_NFT_POSITION_MANAGER_ADDRESS[chainId];
135138
}
136-
return NONFUNGIBLE_POSITION_MANAGER_ADDRESSES[chainId];
137-
}, [chainId, mintInfo.feeTier]);
139+
return isV4
140+
? NONFUNGIBLE_POSITION_V4_MANAGER_ADDRESSES[chainId]
141+
: NONFUNGIBLE_POSITION_MANAGER_ADDRESSES[chainId];
142+
}, [chainId, mintInfo.feeTier, isV4]);
138143

139144
const steerPeripheryContract = useSteerPeripheryContract();
140145
const [approvalA, approveACallback] = useApproveCallback(

src/pages/SwapPage/SwapMain.tsx

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -283,12 +283,10 @@ const SwapMain: React.FC = () => {
283283
justifyContent: 'end',
284284
}}
285285
>
286-
<p style={{ fontSize: '12px' }}>Powered by</p>
287-
<img
288-
src={AlgebraLogo}
289-
alt='poweredby'
290-
style={{ width: '26%', marginBottom: '2px' }}
291-
/>
286+
<p>
287+
<span>{t('poweredBy')}</span>
288+
</p>
289+
<img src={AlgebraLogo} alt='poweredby' style={{ width: '72px' }} />
292290
</Box>
293291
)}
294292
</Box>

0 commit comments

Comments
 (0)