diff --git a/pages/liquidity/index.tsx b/pages/liquidity/index.tsx
index ad841e5b..dcf4c82a 100644
--- a/pages/liquidity/index.tsx
+++ b/pages/liquidity/index.tsx
@@ -16,17 +16,15 @@ import useGetLpTokens from 'hooks/useGetLpTokens';
import { useRouter } from 'next/router';
import { useContext, useState } from 'react';
import SEO from '../../src/components/SEO';
+import { DEFAULT_SLIPPAGE_INPUT_VALUE } from 'components/Settings/MaxSlippageSettings';
const PageWrapper = styled(AutoColumn)`
position: relative;
- background: ${({ theme }) => `linear-gradient(${theme.palette.customBackground.bg2}, ${
- theme.palette.customBackground.bg2
- }) padding-box,
- linear-gradient(150deg, rgba(136,102,221,1) 0%, rgba(${
- theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
- }) 35%, rgba(${
- theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
- }) 65%, rgba(136,102,221,1) 100%) border-box`};
+ background: ${({ theme }) => `linear-gradient(${theme.palette.customBackground.bg2}, ${theme.palette.customBackground.bg2
+ }) padding-box,
+ linear-gradient(150deg, rgba(136,102,221,1) 0%, rgba(${theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
+ }) 35%, rgba(${theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
+ }) 65%, rgba(136,102,221,1) 100%) border-box`};
border: 1px solid transparent;
border-radius: 16px;
padding: 32px;
@@ -108,7 +106,7 @@ export default function LiquidityPage() {
Your liquidity
-
+
List of your liquidity positions
diff --git a/src/components/Liquidity/Add/AddLiquidityComponent.tsx b/src/components/Liquidity/Add/AddLiquidityComponent.tsx
index 96f55667..cd1bfa46 100644
--- a/src/components/Liquidity/Add/AddLiquidityComponent.tsx
+++ b/src/components/Liquidity/Add/AddLiquidityComponent.tsx
@@ -38,14 +38,11 @@ import AddModalHeader from './AddModalHeader';
export const PageWrapper = styled('main')`
position: relative;
- background: ${({ theme }) => `linear-gradient(${theme.palette.customBackground.bg2}, ${
- theme.palette.customBackground.bg2
- }) padding-box,
- linear-gradient(150deg, rgba(136,102,221,1) 0%, rgba(${
- theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
- }) 35%, rgba(${
- theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
- }) 65%, rgba(136,102,221,1) 100%) border-box`};
+ background: ${({ theme }) => `linear-gradient(${theme.palette.customBackground.bg2}, ${theme.palette.customBackground.bg2
+ }) padding-box,
+ linear-gradient(150deg, rgba(136,102,221,1) 0%, rgba(${theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
+ }) 35%, rgba(${theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
+ }) 65%, rgba(136,102,221,1) 100%) border-box`};
border: 1px solid transparent;
border-radius: 16px;
padding: 32px;
diff --git a/src/components/Liquidity/AddRemoveHeader.tsx b/src/components/Liquidity/AddRemoveHeader.tsx
index 0c5cd3f6..2fca843c 100644
--- a/src/components/Liquidity/AddRemoveHeader.tsx
+++ b/src/components/Liquidity/AddRemoveHeader.tsx
@@ -19,6 +19,7 @@ import Link from 'next/link';
import { ReactNode } from 'react';
import { ArrowLeft, Settings } from 'react-feather';
import { flexRowNoWrap } from 'themes/styles';
+import { DEFAULT_SLIPPAGE_INPUT_VALUE } from 'components/Settings/MaxSlippageSettings';
// import Row, { RowBetween } from '../Row'
// import SettingsTab from '../Settings'
@@ -30,7 +31,7 @@ const Tabs = styled('div')`
justify-content: space-evenly;
`;
-const StyledHistoryLink = styled(Link)<{ flex?: string }>`
+const StyledHistoryLink = styled(Link) <{ flex?: string }>`
flex: ${({ flex }) => flex ?? 'none'};
`;
@@ -107,7 +108,7 @@ export function AddRemoveTabs({
{children}
-
+
diff --git a/src/components/Liquidity/Remove/RemoveLiquidityComponent.tsx b/src/components/Liquidity/Remove/RemoveLiquidityComponent.tsx
index 591ad4dd..0f0eaabb 100644
--- a/src/components/Liquidity/Remove/RemoveLiquidityComponent.tsx
+++ b/src/components/Liquidity/Remove/RemoveLiquidityComponent.tsx
@@ -32,14 +32,11 @@ import { AddRemoveTabs } from '../AddRemoveHeader';
export const PageWrapper = styled('main')`
position: relative;
- background: ${({ theme }) => `linear-gradient(${theme.palette.customBackground.bg2}, ${
- theme.palette.customBackground.bg2
- }) padding-box,
- linear-gradient(150deg, rgba(136,102,221,1) 0%, rgba(${
- theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
- }) 35%, rgba(${
- theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
- }) 65%, rgba(136,102,221,1) 100%) border-box`};
+ background: ${({ theme }) => `linear-gradient(${theme.palette.customBackground.bg2}, ${theme.palette.customBackground.bg2
+ }) padding-box,
+ linear-gradient(150deg, rgba(136,102,221,1) 0%, rgba(${theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
+ }) 35%, rgba(${theme.palette.mode == 'dark' ? '33,29,50,1' : '255,255,255,1'
+ }) 65%, rgba(136,102,221,1) 100%) border-box`};
border: 1px solid transparent;
border-radius: 16px;
padding: 32px;
@@ -57,13 +54,13 @@ export const PageWrapper = styled('main')`
}
`;
-const StyledTokenName = styled('span')<{ active?: boolean }>`
+const StyledTokenName = styled('span') <{ active?: boolean }>`
${({ active }) => (active ? ' margin: 0 0.25rem 0 0.25rem;' : ' margin: 0 0.25rem 0 0.25rem;')}
color: ${({ theme }) => theme.palette.custom.textPrimary};
font-size: 20px;
`;
-const Container = styled('div')<{ transparent?: boolean }>`
+const Container = styled('div') <{ transparent?: boolean }>`
border-radius: 16px;
padding: 1.25rem;
border: 1px solid ${({ theme }) => theme.palette.custom.textSecondary};
@@ -390,8 +387,8 @@ export default function RemoveLiquidityComponent() {
>
{currencyA && currencyA.code && currencyA.code.length > 20
? currencyA.code.slice(0, 4) +
- '...' +
- currencyA.code.slice(currencyA.code.length - 5, currencyA.code.length)
+ '...' +
+ currencyA.code.slice(currencyA.code.length - 5, currencyA.code.length)
: currencyA?.code}
{isLoadingPairInfo ? (
@@ -412,8 +409,8 @@ export default function RemoveLiquidityComponent() {
>
{currencyB && currencyB.code && currencyB.code.length > 20
? currencyB.code.slice(0, 4) +
- '...' +
- currencyB.code.slice(currencyB.code.length - 5, currencyB.code.length)
+ '...' +
+ currencyB.code.slice(currencyB.code.length - 5, currencyB.code.length)
: currencyB?.code}
{isLoadingPairInfo ? (
@@ -438,7 +435,7 @@ export default function RemoveLiquidityComponent() {
- Slippage Tolerance 0.5%
+ Slippage Tolerance {allowedSlippage}%
{!sorobanContext.address ? (
setConnectWalletModalOpen(true)}>{error}
) : (
diff --git a/src/components/Settings/MaxSlippageSettings/index.tsx b/src/components/Settings/MaxSlippageSettings/index.tsx
index 77facf7f..54314a22 100644
--- a/src/components/Settings/MaxSlippageSettings/index.tsx
+++ b/src/components/Settings/MaxSlippageSettings/index.tsx
@@ -13,7 +13,7 @@ enum SlippageError {
const Option = styled(Row, {
shouldForwardProp: (prop) => prop !== 'isActive',
-})<{ isActive: boolean }>`
+}) <{ isActive: boolean }>`
width: auto;
cursor: pointer;
padding: 6px 12px;
@@ -37,7 +37,7 @@ const NUMBER_WITH_MAX_TWO_DECIMAL_PLACES = /^(?:\d+(?:\.\d{0,2})?|\.\d{0,2})?$/;
const MINIMUM_RECOMMENDED_SLIPPAGE = 0.05;
const MAXIMUM_RECOMMENDED_SLIPPAGE = 1;
-export const DEFAULT_SLIPPAGE_INPUT_VALUE = 0.5;
+export const DEFAULT_SLIPPAGE_INPUT_VALUE = 1;
export default function MaxSlippageSettings({ autoSlippage }: { autoSlippage: number }) {
const theme = useTheme();
@@ -193,7 +193,7 @@ export default function MaxSlippageSettings({ autoSlippage }: { autoSlippage: nu
transaction
) : (
- Your transaction may be frontrun and result in an unfavorable trade.
+ Your transaction may be frontrun and result in an unfavorable trade.
)}
diff --git a/src/components/Settings/MenuButton/index.tsx b/src/components/Settings/MenuButton/index.tsx
index 39a3f5e5..32eb6aef 100644
--- a/src/components/Settings/MenuButton/index.tsx
+++ b/src/components/Settings/MenuButton/index.tsx
@@ -4,13 +4,14 @@ import { styled, useMediaQuery, useTheme } from 'soroswap-ui';
import { Settings } from 'react-feather';
import settingsIcon from '../../../assets/svg/settingsIcon.svg';
import Image from 'next/image';
+import { DEFAULT_SLIPPAGE_INPUT_VALUE } from '../MaxSlippageSettings';
const Icon = styled(Settings)`
height: 24px;
width: 24px;
`;
-const Button = styled('button')<{ isActive: boolean }>`
+const Button = styled('button') <{ isActive: boolean }>`
border: none;
background-color: transparent;
margin: 0;
@@ -43,7 +44,7 @@ const ButtonContent = () => {
const theme = useTheme();
const isMobile = useMediaQuery(theme.breakpoints.down('md'));
- if (userSlippageTolerance === 0.5) {
+ if (userSlippageTolerance === DEFAULT_SLIPPAGE_INPUT_VALUE) {
return (