Add user prop to CommentEditor
This commit is contained in:
parent
90d1e1a040
commit
3ffd391cb0
@ -1,5 +1,5 @@
|
||||
import React from 'react'
|
||||
import {Control, Field, Input as I, Label} from 'bloomer'
|
||||
import {Control, Field, Input as I, Heading} from 'bloomer'
|
||||
import {IconType} from 'react-icons'
|
||||
|
||||
export interface IInputProps {
|
||||
@ -24,7 +24,7 @@ export class Input extends React.PureComponent<IInputProps> {
|
||||
const {Icon} = this.props
|
||||
return (
|
||||
<Field>
|
||||
<Label>{this.props.label}</Label>
|
||||
<Heading>{this.props.label}</Heading>
|
||||
<Control hasIcons>
|
||||
<I
|
||||
className='input'
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
import React from 'react'
|
||||
import {FaUser, FaLock} from 'react-icons/fa'
|
||||
import {INewUser, IUser} from '@rondo/common'
|
||||
import {Input} from '../components/Input'
|
||||
import {Redirect} from '../components/Redirect'
|
||||
@ -21,6 +22,7 @@ export class RegisterForm extends React.PureComponent<IRegisterFormProps> {
|
||||
<form onSubmit={this.props.onSubmit}>
|
||||
<p className='error'>{this.props.error}</p>
|
||||
<Input
|
||||
Icon={FaUser}
|
||||
label='Email'
|
||||
name='username'
|
||||
type='email'
|
||||
@ -30,6 +32,7 @@ export class RegisterForm extends React.PureComponent<IRegisterFormProps> {
|
||||
required
|
||||
/>
|
||||
<Input
|
||||
Icon={FaLock}
|
||||
label='Password'
|
||||
name='password'
|
||||
type='password'
|
||||
@ -56,12 +59,14 @@ export class RegisterForm extends React.PureComponent<IRegisterFormProps> {
|
||||
placeholder='First name'
|
||||
required
|
||||
/>
|
||||
<input
|
||||
className='button is-primary'
|
||||
name='submit'
|
||||
type='submit'
|
||||
value='Log In'
|
||||
/>
|
||||
<div className='text-center'>
|
||||
<input
|
||||
className='button is-primary'
|
||||
name='submit'
|
||||
type='submit'
|
||||
value='Register'
|
||||
/>
|
||||
</div>
|
||||
</form>
|
||||
)
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user