Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
I
interface
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
LuckySwap
interface
Commits
374cc361
Unverified
Commit
374cc361
authored
Jun 16, 2021
by
Ian Lapham
Committed by
GitHub
Jun 16, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
small bg fixes (#1868)
parent
0198d0ba
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
9 deletions
+10
-9
index.tsx
src/components/NavigationTabs/index.tsx
+10
-5
index.tsx
src/pages/AddLiquidity/index.tsx
+0
-4
No files found.
src/components/NavigationTabs/index.tsx
View file @
374cc361
...
@@ -2,7 +2,7 @@ import React from 'react'
...
@@ -2,7 +2,7 @@ import React from 'react'
import
styled
from
'
styled-components/macro
'
import
styled
from
'
styled-components/macro
'
import
{
darken
}
from
'
polished
'
import
{
darken
}
from
'
polished
'
import
{
Trans
}
from
'
@lingui/macro
'
import
{
Trans
}
from
'
@lingui/macro
'
import
{
NavLink
,
Link
as
HistoryLink
}
from
'
react-router-dom
'
import
{
NavLink
,
Link
as
HistoryLink
,
useLocation
}
from
'
react-router-dom
'
import
{
Percent
}
from
'
@uniswap/sdk-core
'
import
{
Percent
}
from
'
@uniswap/sdk-core
'
import
{
ArrowLeft
}
from
'
react-feather
'
import
{
ArrowLeft
}
from
'
react-feather
'
...
@@ -90,24 +90,29 @@ export function FindPoolTabs({ origin }: { origin: string }) {
...
@@ -90,24 +90,29 @@ export function FindPoolTabs({ origin }: { origin: string }) {
export
function
AddRemoveTabs
({
export
function
AddRemoveTabs
({
adding
,
adding
,
creating
,
creating
,
positionID
,
defaultSlippage
,
defaultSlippage
,
positionID
,
}:
{
}:
{
adding
:
boolean
adding
:
boolean
creating
:
boolean
creating
:
boolean
positionID
?:
string
|
undefined
defaultSlippage
:
Percent
defaultSlippage
:
Percent
positionID
?:
string
|
undefined
})
{
})
{
const
theme
=
useTheme
()
const
theme
=
useTheme
()
// reset states on back
// reset states on back
const
dispatch
=
useAppDispatch
()
const
dispatch
=
useAppDispatch
()
const
location
=
useLocation
()
// detect if back should redirect to v3 or v2 pool page
const
poolLink
=
location
.
pathname
.
includes
(
'
add/v2
'
)
?
'
/pool/v2
'
:
'
/pool
'
+
(
!!
positionID
?
`/
${
positionID
.
toString
()}
`
:
''
)
return
(
return
(
<
Tabs
>
<
Tabs
>
<
RowBetween
style=
{
{
padding
:
'
1rem 1rem 0 1rem
'
}
}
>
<
RowBetween
style=
{
{
padding
:
'
1rem 1rem 0 1rem
'
}
}
>
<
HistoryLink
<
HistoryLink
to=
{
'
/pool
'
+
(
!!
positionID
?
`/${positionID.toString()}`
:
''
)
}
to=
{
poolLink
}
onClick=
{
()
=>
{
onClick=
{
()
=>
{
if
(
adding
)
{
if
(
adding
)
{
// not 100% sure both of these are needed
// not 100% sure both of these are needed
...
...
src/pages/AddLiquidity/index.tsx
View file @
374cc361
...
@@ -720,8 +720,6 @@ export default function AddLiquidity({
...
@@ -720,8 +720,6 @@ export default function AddLiquidity({
<
RowBetween
>
<
RowBetween
>
{
showApprovalA
&&
(
{
showApprovalA
&&
(
<
ButtonPrimary
<
ButtonPrimary
borderRadius=
"12px"
padding=
{
'
12px
'
}
onClick=
{
approveACallback
}
onClick=
{
approveACallback
}
disabled=
{
approvalA
===
ApprovalState
.
PENDING
}
disabled=
{
approvalA
===
ApprovalState
.
PENDING
}
width=
{
showApprovalB
?
'
48%
'
:
'
100%
'
}
width=
{
showApprovalB
?
'
48%
'
:
'
100%
'
}
...
@@ -737,8 +735,6 @@ export default function AddLiquidity({
...
@@ -737,8 +735,6 @@ export default function AddLiquidity({
)
}
)
}
{
showApprovalB
&&
(
{
showApprovalB
&&
(
<
ButtonPrimary
<
ButtonPrimary
borderRadius=
"12px"
padding=
{
'
12px
'
}
onClick=
{
approveBCallback
}
onClick=
{
approveBCallback
}
disabled=
{
approvalB
===
ApprovalState
.
PENDING
}
disabled=
{
approvalB
===
ApprovalState
.
PENDING
}
width=
{
showApprovalA
?
'
48%
'
:
'
100%
'
}
width=
{
showApprovalA
?
'
48%
'
:
'
100%
'
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment