-
Notifications
You must be signed in to change notification settings - Fork 77
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
870991e
commit 288cf43
Showing
2 changed files
with
219 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,181 @@ | ||
'use strict' | ||
|
||
// Packages | ||
import { remote, shell } from 'electron' | ||
import { Component } from 'react' | ||
import Link from 'next/link' | ||
|
||
// Layouts | ||
import Page from './../layouts/page' | ||
|
||
// Components | ||
import Row from './../components/row' | ||
import Hero from './../components/hero' | ||
|
||
class Settings extends Component { | ||
constructor() { | ||
super() | ||
|
||
this.openUrl = this.openUrl.bind(this) | ||
} | ||
|
||
openUrl(url) { | ||
shell.openExternal(url) | ||
} | ||
|
||
render() { | ||
const appVersion = remote && remote.app ? remote.app.getVersion() : '' | ||
return ( | ||
<Page> | ||
<Row> | ||
<section> | ||
<Hero type="Settings" /> | ||
|
||
<ul> | ||
<li> | ||
Import tasks <span>soon</span> | ||
</li> | ||
<li> | ||
Export tasks <span>soon</span> | ||
</li> | ||
<li> | ||
Clear history <span>soon</span> | ||
</li> | ||
<li> | ||
Cloud sync <span>soon</span> | ||
</li> | ||
<li> | ||
Create team <span>soon</span> | ||
</li> | ||
</ul> | ||
|
||
<footer> | ||
<Link href="/start" prefetch> | ||
<span>Back</span> | ||
</Link> | ||
|
||
<div> | ||
<p>© taskr {appVersion}</p> | ||
|
||
<ul> | ||
<li | ||
onClick={() => | ||
this.openUrl('https://github.com/bukinoshita/taskr') | ||
} | ||
> | ||
About | ||
</li> | ||
<li | ||
onClick={() => | ||
this.openUrl('https://github.com/bukinoshita/taskr') | ||
} | ||
> | ||
Github | ||
</li> | ||
<li | ||
onClick={() => | ||
this.openUrl( | ||
'https://github.com/bukinoshita/taskr/releases' | ||
) | ||
} | ||
> | ||
Releases | ||
</li> | ||
</ul> | ||
</div> | ||
</footer> | ||
</section> | ||
</Row> | ||
|
||
<style jsx>{` | ||
section { | ||
display: flex; | ||
flex-direction: column; | ||
jutify-content: space-between; | ||
min-height: 500px; | ||
} | ||
ul { | ||
flex-basis: 340px; | ||
} | ||
li { | ||
cursor: pointer; | ||
color: rgba(255, 255, 255, 0.65); | ||
height: 60px; | ||
line-height: 60px; | ||
font-size: 12px; | ||
border-bottom: 1px solid rgba(255, 255, 255, 0.2); | ||
transition: 0.2s; | ||
} | ||
li:hover { | ||
padding-left: 5px; | ||
color: white; | ||
} | ||
span { | ||
color: white; | ||
border: 1px solid white; | ||
margin-left: 5px; | ||
font-size: 10px; | ||
padding: 0 2px 1px; | ||
} | ||
footer div { | ||
display: flex; | ||
justify-content: space-between; | ||
align-items: center; | ||
} | ||
footer span { | ||
display: block; | ||
width: 100%; | ||
color: #aaa; | ||
height: 36px; | ||
font-weight: 600; | ||
font-size: 10px; | ||
cursor: pointer; | ||
text-transform: uppercase; | ||
letter-spacing: 2px; | ||
text-align: center; | ||
transition: 0.2s all; | ||
margin: 0; | ||
padding: 0; | ||
border: 0; | ||
} | ||
footer span:hover { | ||
color: white; | ||
} | ||
footer p { | ||
color: white; | ||
font-size: 12px; | ||
opacity: 0.75; | ||
font-weight: 600; | ||
} | ||
footer ul { | ||
flex-basis: auto; | ||
} | ||
footer li { | ||
display: inline-block; | ||
border-bottom: 0; | ||
height: auto; | ||
line-height: auto; | ||
font-size: 12px; | ||
margin-left: 8px; | ||
} | ||
footer li:hover { | ||
padding-left: 0; | ||
} | ||
`}</style> | ||
</Page> | ||
) | ||
} | ||
} | ||
|
||
export default Settings |