-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcreate-mode.js
More file actions
31 lines (26 loc) · 807 Bytes
/
create-mode.js
File metadata and controls
31 lines (26 loc) · 807 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
import React from 'react';
import ReactDOM from 'react-dom';
class CreateMode extends React.Component {
constructor(props) {
super(props);
this.state = { };
this._onGetStarted = this._onGetStarted.bind(this);
this._onTextChange = this._onTextChange.bind(this);
}
_onTextChange(e) {
this.setState({ text: e.target.value })
}
_onGetStarted() {
this.props.textPastedAndSubmitted(this.state.text);
}
render() {
return (
<div className="text-center">
<h1 className="header-main">1. Paste text to get started:</h1>
<textarea className="textarea block-s" onChange={this._onTextChange}/>
<button className="single-action-btn edit-action-btn" onClick={this._onGetStarted}>Next</button>
</div>
);
}
}
export default CreateMode;