1
0
Fork 0
mirror of https://github.com/arangodb/kube-arangodb.git synced 2024-12-14 11:57:37 +00:00

Review comments

This commit is contained in:
Ewout Prangsma 2018-07-09 13:15:18 +02:00
parent bf29d7a6c0
commit de5cd8f60f
No known key found for this signature in database
GPG key ID: 4DBAD380D93D0698
3 changed files with 9 additions and 9 deletions

View file

@ -1,16 +1,16 @@
import React, { Component } from 'react';
import { Button, Container, Form, Icon, Message, Modal } from 'semantic-ui-react';
const LoginView = ({username, password, usernameChanged, passwordChanged, doLogin, error}) => (
const LoginView = ({username, password, onUsernameChanged, onPasswordChanged, doLogin, error}) => (
<Container>
<Form onSubmit={doLogin}>
<Form.Field>
<label>Name</label>
<input focus="true" value={username} onChange={(e) => usernameChanged(e.target.value)}/>
<input focus="true" value={username} onChange={(e) => onUsernameChanged(e.target.value)}/>
</Form.Field>
<Form.Field>
<label>Password</label>
<input type="password" value={password} onChange={(e) => passwordChanged(e.target.value)}/>
<input type="password" value={password} onChange={(e) => onPasswordChanged(e.target.value)}/>
</Form.Field>
</Form>
{(error) ? <Message error content={error}/> : null}
@ -36,8 +36,8 @@ class Login extends Component {
error={this.props.error}
username={this.state.username}
password={this.state.password}
usernameChanged={(v) => this.setState({username:v})}
passwordChanged={(v) => this.setState({password:v})}
onUsernameChanged={(v) => this.setState({username:v})}
onPasswordChanged={(v) => this.setState({password:v})}
doLogin={this.handleLogin}
/>
</Modal.Content>

View file

@ -19,7 +19,7 @@ const LoaderBox = styled('span')`
const MemberGroupsView = ({memberGroups, namespace}) => (
<div>
{memberGroups.map((item) => <MemberList
key={`server-group-${item.group}`}
key={item.group}
group={item.group}
members={item.members}
namespace={namespace}

View file

@ -152,8 +152,8 @@ function getStateColorDescription(stateColor) {
class DeploymentList extends Component {
state = {
items: undefined,
error: undefined,
items: null,
error: null,
loading: true
};
@ -168,7 +168,7 @@ class DeploymentList extends Component {
this.setState({
items: result.deployments,
loading: false,
error: undefined
error: null
});
} catch (e) {
this.setState({error: e.message, loading: false});