mirror of
https://github.com/roleypoly/roleypoly-v1.git
synced 2025-06-17 02:29:10 +00:00
absolutely massive typescript porting time
This commit is contained in:
parent
01f238f515
commit
30d08a630f
159 changed files with 2563 additions and 3861 deletions
53
packages/roleypoly-ui/components/header/unauth.tsx
Normal file
53
packages/roleypoly-ui/components/header/unauth.tsx
Normal file
|
@ -0,0 +1,53 @@
|
|||
// @flow
|
||||
import * as React from 'react'
|
||||
import HeaderBarCommon, { Logotype, type CommonProps } from './common'
|
||||
import styled from 'styled-components'
|
||||
import Link from 'next/link'
|
||||
|
||||
const LogoBox = styled.a`
|
||||
flex: 1;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
cursor: pointer;
|
||||
`
|
||||
|
||||
const LoginButton = styled.a`
|
||||
cursor: pointer;
|
||||
background-color: transparent;
|
||||
display: block;
|
||||
padding: 0.3em 1em;
|
||||
border-radius: 2px;
|
||||
border: 1px solid transparent;
|
||||
transition: all 0.3s ease-in-out;
|
||||
|
||||
&:hover {
|
||||
transform: translateY(-1px);
|
||||
box-shadow: 0 1px 2px rgba(0, 0, 0, 0.75);
|
||||
background-color: var(--c-green);
|
||||
border-color: rgba(0, 0, 0, 0.25);
|
||||
text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.25);
|
||||
}
|
||||
|
||||
&:active {
|
||||
transform: translateY(0);
|
||||
box-shadow: none;
|
||||
}
|
||||
`
|
||||
|
||||
const HeaderBarUnauth: React.StatelessFunctionalComponent<CommonProps> = (props) => (
|
||||
<HeaderBarCommon {...props}>
|
||||
<>
|
||||
<Link href='/' prefetch>
|
||||
<LogoBox>
|
||||
<Logotype />
|
||||
</LogoBox>
|
||||
</Link>
|
||||
<Link href='/auth/login' prefetch>
|
||||
<LoginButton>Sign in →</LoginButton>
|
||||
</Link>
|
||||
</>
|
||||
</HeaderBarCommon>
|
||||
)
|
||||
|
||||
export default HeaderBarUnauth
|
Loading…
Add table
Add a link
Reference in a new issue