Skip to content

Closes #95. Feature/launch page #135

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Mar 8, 2020
Merged
Prev Previous commit
Next Next commit
add beta badge
  • Loading branch information
ShMcK committed Mar 8, 2020
commit 18973c4c8061b05349fed3615e2ce94274b6f2eb
18 changes: 13 additions & 5 deletions web-app/src/containers/Launch/index.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import * as React from 'react'
import * as CR from 'typings'
import * as G from 'typings/graphql'
import { Badge } from '@alifd/next'
import { css, jsx } from '@emotion/core'
import Button from '../../components/Button'
import Card from '../../components/Card'
Expand All @@ -22,7 +23,7 @@ const styles = {
backgroundColor: '#EBEBEB',
fontSize: '1rem',
lineHeight: '1rem',
padding: '10px 1rem',
padding: '1rem',
},
title: {
fontSize: '4rem',
Expand All @@ -36,9 +37,14 @@ const styles = {
flexDirection: 'column' as 'column',
justifyContent: 'flex-start' as 'flex-start',
alignItems: 'center' as 'center',
padding: '1rem',
},
betaBadge: {
backgroundColor: '#6a67ce',
color: '#FFFFFF',
},
buttonContainer: {
margin: '1rem',
margin: '0.5rem',
},
}

Expand All @@ -51,19 +57,21 @@ interface Props {
export const LaunchPage = (props: Props) => (
<div css={styles.page}>
<div css={styles.header}>
<h1 css={styles.title}>CodeRoad</h1>
<Badge content="beta" style={styles.betaBadge}>
<span css={styles.title}>CodeRoad&nbsp;</span>
</Badge>
<h3 css={styles.subtitle}>Play Interactive Coding Tutorials in VSCode</h3>
</div>

<div css={styles.options}>
<div css={styles.buttonContainer}>
<Button size="large" type="primary" onClick={props.onNew} style={{ width: '8rem' }}>
<Button size="large" type="primary" onClick={props.onNew} style={{ width: '10rem' }}>
Start
</Button>
</div>
{props.tutorial && (
<div css={styles.buttonContainer}>
<Button size="large" onClick={props.onContinue} style={{ width: '8rem' }}>
<Button size="large" onClick={props.onContinue} style={{ width: '10rem' }}>
Continue
</Button>
</div>
Expand Down