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

Commit

Permalink
Kelp GUI: Welcome modal should not show quit button in kaas mode
Browse files Browse the repository at this point in the history
  • Loading branch information
nikhilsaraf committed Apr 17, 2021
1 parent 3c47994 commit 4db12f8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion gui/web/src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ class App extends Component {
render={(props) => <NewBot {...props} baseUrl={baseUrl} enablePubnetBots={enablePubnetBots}/>}
/>
</Router>
<Welcome quitFn={this.quit}/>
<Welcome quitFn={this.quit} showQuitButton={this.showQuitButton()}/>
</div>
);
}
Expand Down
6 changes: 5 additions & 1 deletion gui/web/src/components/molecules/Welcome/Welcome.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,10 @@ class Welcome extends Component {
</div>
</div>
);
let quitButton = (<Button eventName="welcome-quit" variant="faded" onClick={this.quit}>Quit</Button>);
if (!this.props.showQuitButton) {
quitButton = "";
}
const page2 = (
<div className={styles.window}>
{kelpLogo}
Expand Down Expand Up @@ -110,7 +114,7 @@ class Welcome extends Component {

<div className={styles.footer}>
<Button eventName="welcome-accept" variant="faded" onClick={this.accept}>Accept</Button>
<Button eventName="welcome-quit" variant="faded" onClick={this.quit}>Quit</Button>
{quitButton}
</div>
</div>
</div>
Expand Down

0 comments on commit 4db12f8

Please sign in to comment.