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
1e5519de
Unverified
Commit
1e5519de
authored
May 04, 2021
by
Ian Lapham
Committed by
GitHub
May 04, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add dark mdoe toggle, update some styles (#134)
parent
e8587396
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
7 deletions
+10
-7
index.tsx
src/components/Header/index.tsx
+6
-3
CTACards.tsx
src/pages/Pool/CTACards.tsx
+4
-4
No files found.
src/components/Header/index.tsx
View file @
1e5519de
...
...
@@ -4,7 +4,7 @@ import { Text } from 'rebass'
import
{
NavLink
}
from
'
react-router-dom
'
import
{
darken
}
from
'
polished
'
import
{
useTranslation
}
from
'
react-i18next
'
import
{
Moon
,
Sun
}
from
'
react-feather
'
import
styled
from
'
styled-components
'
import
Logo
from
'
../../assets/svg/logo.svg
'
...
...
@@ -272,7 +272,7 @@ export const StyledMenuButton = styled.button`
margin: 0;
padding: 0;
height: 35px;
background-color:
${({
theme
})
=>
theme
.
bg
3
}
;
background-color:
${({
theme
})
=>
theme
.
bg
2
}
;
margin-left: 8px;
padding: 0.15rem 0.5rem;
border-radius: 0.5rem;
...
...
@@ -305,7 +305,7 @@ export default function Header() {
const
userEthBalance
=
useETHBalances
(
account
?
[
account
]
:
[])?.[
account
??
''
]
// const [isDark] = useDarkModeManager()
const
[
darkMode
]
=
useDarkModeManager
()
const
[
darkMode
,
toggleDarkMode
]
=
useDarkModeManager
()
const
toggleClaimModal
=
useToggleSelfClaimModal
()
...
...
@@ -381,6 +381,9 @@ export default function Header() {
</
AccountElement
>
</
HeaderElement
>
<
HeaderElementWrap
>
<
StyledMenuButton
onClick=
{
()
=>
toggleDarkMode
()
}
>
{
darkMode
?
<
Moon
size=
{
20
}
/>
:
<
Sun
size=
{
20
}
/>
}
</
StyledMenuButton
>
<
Menu
/>
</
HeaderElementWrap
>
</
HeaderControls
>
...
...
src/pages/Pool/CTACards.tsx
View file @
1e5519de
...
...
@@ -21,15 +21,15 @@ const CTASection = styled.section`
const
CTA1
=
styled
(
ExternalLink
)
`
background-size: 40px 40px;
background-image: linear-gradient(to right,
#2d2d2d
1px, transparent 1px),
linear-gradient(to bottom,
#2d2d2d
1px, transparent 1px);
background-color:
${({
theme
})
=>
theme
.
bg
1
}
;
background-image: linear-gradient(to right,
${({
theme
})
=>
theme
.
bg3
}
1px, transparent 1px),
linear-gradient(to bottom,
${({
theme
})
=>
theme
.
bg3
}
1px, transparent 1px);
background-color:
${({
theme
})
=>
theme
.
bg
2
}
;
padding: 32px;
border-radius: 20px;
display: flex;
flex-direction: column;
justify-content: space-between;
border: 1px solid
${({
theme
})
=>
theme
.
bg
4
}
;
border: 1px solid
${({
theme
})
=>
theme
.
bg
3
}
;
* {
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