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
73580de9
Unverified
Commit
73580de9
authored
Aug 24, 2020
by
Moody Salem
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
improvement(swap): show add a send only for expert mode
parent
e32fd3a8
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
32 additions
and
42 deletions
+32
-42
index.tsx
src/components/CurrencyInputPanel/index.tsx
+12
-14
index.tsx
src/pages/Swap/index.tsx
+20
-22
components.tsx
src/theme/components.tsx
+0
-6
No files found.
src/components/CurrencyInputPanel/index.tsx
View file @
73580de9
...
...
@@ -7,7 +7,7 @@ import CurrencySearchModal from '../SearchModal/CurrencySearchModal'
import
CurrencyLogo
from
'
../CurrencyLogo
'
import
DoubleCurrencyLogo
from
'
../DoubleLogo
'
import
{
RowBetween
}
from
'
../Row
'
import
{
TYPE
,
CursorPointer
}
from
'
../../theme
'
import
{
TYPE
}
from
'
../../theme
'
import
{
Input
as
NumericalInput
}
from
'
../NumericalInput
'
import
{
ReactComponent
as
DropDown
}
from
'
../../assets/images/dropdown.svg
'
...
...
@@ -170,19 +170,17 @@ export default function CurrencyInputPanel({
{
label
}
</
TYPE
.
body
>
{
account
&&
(
<
CursorPointer
>
<
TYPE
.
body
onClick=
{
onMax
}
color=
{
theme
.
text2
}
fontWeight=
{
500
}
fontSize=
{
14
}
style=
{
{
display
:
'
inline
'
}
}
style=
{
{
display
:
'
inline
'
,
cursor
:
'
pointer
'
}
}
>
{
!
hideBalance
&&
!!
currency
&&
selectedCurrencyBalance
?
'
Balance:
'
+
selectedCurrencyBalance
?.
toSignificant
(
6
)
:
'
-
'
}
</
TYPE
.
body
>
</
CursorPointer
>
)
}
</
RowBetween
>
</
LabelRow
>
...
...
src/pages/Swap/index.tsx
View file @
73580de9
...
...
@@ -41,7 +41,7 @@ import {
useUserDeadline
,
useUserSlippageTolerance
}
from
'
../../state/user/hooks
'
import
{
CursorPointer
,
LinkStyledButton
,
TYPE
}
from
'
../../theme
'
import
{
LinkStyledButton
,
TYPE
}
from
'
../../theme
'
import
{
maxAmountSpend
}
from
'
../../utils/maxAmountSpend
'
import
{
computeTradePriceBreakdown
,
warningSeverity
}
from
'
../../utils/prices
'
import
AppBody
from
'
../AppBody
'
...
...
@@ -285,7 +285,6 @@ export default function Swap() {
id=
"swap-currency-input"
/>
<
CursorPointer
>
<
AutoColumn
justify=
"space-between"
>
<
AutoRow
justify=
"space-between"
style=
{
{
padding
:
'
0 1rem
'
}
}
>
<
ArrowWrapper
clickable
>
...
...
@@ -298,14 +297,13 @@ export default function Swap() {
color=
{
currencies
[
Field
.
INPUT
]
&&
currencies
[
Field
.
OUTPUT
]
?
theme
.
primary1
:
theme
.
text2
}
/>
</
ArrowWrapper
>
{
recipient
===
null
&&
!
showWrap
?
(
{
recipient
===
null
&&
!
showWrap
&&
isExpertMode
?
(
<
LinkStyledButton
id=
"add-recipient-button"
onClick=
{
()
=>
onChangeRecipient
(
''
)
}
>
+ Add a send (optional)
</
LinkStyledButton
>
)
:
null
}
</
AutoRow
>
</
AutoColumn
>
</
CursorPointer
>
<
CurrencyInputPanel
value=
{
formattedAmounts
[
Field
.
OUTPUT
]
}
onUserInput=
{
handleTypeOutput
}
...
...
src/theme/components.tsx
View file @
73580de9
...
...
@@ -148,12 +148,6 @@ export const Spinner = styled.img`
height: 16px;
`
export
const
CursorPointer
=
styled
.
div
`
:hover {
cursor: pointer;
}
`
const
BackArrowLink
=
styled
(
StyledInternalLink
)
`
color:
${({
theme
})
=>
theme
.
text1
}
;
`
...
...
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