Skip to content
This repository has been archived by the owner on Dec 1, 2022. It is now read-only.

Commit

Permalink
Make back button work (#46)
Browse files Browse the repository at this point in the history
  • Loading branch information
flynnduism authored and itowlson committed Dec 3, 2018
1 parent 22aa5bd commit 20b26b7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion app/components/Installer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ export default class Installer extends React.Component<Properties, State, {}> {
<Segment>
<Step.Group>
<Step>
<Button secondary left onclick={() => this.goBack()}><Icon name="angle left"></Icon> Cancel </Button>
{this.goBackButton()}
<Button primary right onClick={() => this.install()}>Install</Button>
</Step>
{this.progress()}
Expand All @@ -219,6 +219,10 @@ export default class Installer extends React.Component<Properties, State, {}> {
);
}

goBackButton(): JSX.Element {
return (<Button secondary left onClick={() => this.goBack()}><Icon name="angle left"></Icon> Back</Button>);
}

private installationNameValidityPanel(): JSX.Element[] {
if (this.state.installationNameExists === undefined) {
return [(<Message info>Checking installation name...</Message>)];
Expand Down
6 changes: 5 additions & 1 deletion app/components/Report.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ export default class Report extends React.Component<Properties, State, {}> {
<Segment raised>
<Step.Group>
<Step>
<Button secondary left onclick={() => this.goBack()}><Icon name="angle left"></Icon> Cancel </Button>
{this.goBackButton()}
{this.postInstallPanel()}
{this.tryAgainButton()}
</Step>
Expand All @@ -46,6 +46,10 @@ export default class Report extends React.Component<Properties, State, {}> {
);
}

goBackButton(): JSX.Element {
return (<Button secondary left onClick={() => this.goBack()}><Icon name="angle left"></Icon> Back</Button>);
}

tryAgainButton(): JSX.Element | undefined {
if (this.props.succeeded) {
return undefined;
Expand Down

0 comments on commit 20b26b7

Please sign in to comment.