--- a/client/src/components/SessionForm.js Wed Jul 18 17:32:09 2018 +0200
+++ b/client/src/components/SessionForm.js Tue Aug 14 20:34:50 2018 +0200
@@ -1,7 +1,7 @@
import React, { Component } from 'react';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
-import { Panel, FormGroup, ControlLabel, FormControl, Collapse } from 'react-bootstrap';
+import { Collapse } from 'react-bootstrap';
import '../App.css';
import * as sessionsActions from '../actions/sessionsActions';
import * as authActions from '../actions/authActions';
@@ -55,40 +55,42 @@
}
return (
- <Panel>
- <form onSubmit={ e => { e.preventDefault() } }>
- <FormGroup>
- <ControlLabel>Title</ControlLabel>
- <FormControl
- name="title"
- defaultValue={ this.props.currentSession.title }
- onChange={ this.onChange }
- type="text"
- placeholder="Enter a title"
- />
- </FormGroup>
- <FormGroup>
- <ControlLabel>Description</ControlLabel>
- <FormControl
- name="description"
- componentClass="textarea"
- defaultValue={ this.props.currentSession.description }
- onChange={ this.onChange }
- placeholder="Enter a description"
- />
- </FormGroup>
- <FormGroup>
- <ControlLabel>Group</ControlLabel>
- <p>{this.props.currentSession.group}</p>
- </FormGroup>
- <FormGroup>
- <ControlLabel onClick={this.toggleProtocol}>Protocol {this.state.protocolOpen?<span className="material-icons protocol-toggle"></span>:<span className="material-icons protocol-toggle"></span>}</ControlLabel>
- <Collapse in={this.state.protocolOpen}>
- <pre>{JSON.stringify(this.props.currentSession.protocol, null, 2)}</pre>
- </Collapse>
- </FormGroup>
- </form>
- </Panel>
+ <div className="panel-default">
+ <div class="panel-body">
+ <form onSubmit={ e => { e.preventDefault() } }>
+ <div className="form-group">
+ <label className="control-label">Titre</label>
+ <input className="form-control"
+ name="title"
+ defaultValue={ this.props.currentSession.title }
+ onChange={ this.onChange }
+ type="text"
+ placeholder="Entrez un titre"
+ />
+ </div>
+ <div className="form-group">
+ <label className="control-label">Description</label>
+ <input className="form-control"
+ type="textarea"
+ name="description"
+ defaultValue={ this.props.currentSession.description }
+ onChange={ this.onChange }
+ placeholder="Entrez une description"
+ />
+ </div>
+ <div className="form-group">
+ <label className="control-label">Group</label>
+ <p>{this.props.currentSession.group}</p>
+ </div>
+ <div className="form-group">
+ <label className="control-label" onClick={this.toggleProtocol}>Protocol {this.state.protocolOpen?<span className="material-icons protocol-toggle"></span>:<span className="material-icons protocol-toggle"></span>}</label>
+ <Collapse in={this.state.protocolOpen}>
+ <pre>{JSON.stringify(this.props.currentSession.protocol, null, 2)}</pre>
+ </Collapse>
+ </div>
+ </form>
+ </div>
+ </div>
);
}
}