Skip to content

Feature/on reset #388

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 9 commits into from
Jul 12, 2020
Prev Previous commit
Next Next commit
update reset message
Signed-off-by: shmck <shawn.j.mckay@gmail.com>
  • Loading branch information
ShMcK committed Jul 12, 2020
commit 605bafa0276bf130363c44c2ffb19fb36cf3b014
7 changes: 5 additions & 2 deletions web-app/src/containers/Tutorial/components/Reset.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import * as React from 'react'
import { Dialog } from '@alifd/next'
import Button from '../../../components/Button'
import Markdown from '../../../components/Markdown'

interface Props {
onReset(): void
Expand All @@ -26,7 +27,6 @@ const Reset = (props: Props) => {
<Button type="secondary" onClick={() => setModalState('confirm')}>
Reset
</Button>
{/* TODO improve reset message */}
<Dialog
title="Reset"
visible={modalState === 'confirm'}
Expand All @@ -35,7 +35,10 @@ const Reset = (props: Props) => {
onClose={onClose}
footerActions={['ok', 'cancel']}
>
Are you sure?
<Markdown>
{`Are you sure you want to reset your progress?
Resetting progress will remove the commits you have made and replace them with the tutorial commit timeline. Your code may look different after resetting.`}
</Markdown>
</Dialog>
<Dialog
title="Resetting..."
Expand Down
2 changes: 1 addition & 1 deletion web-app/src/containers/Tutorial/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ const TutorialPage = (props: PageProps) => {
)}

{/* Center */}
<div>
<div style={{}}>
<Reset onReset={onReset} />
</div>

Expand Down