Created
March 14, 2016 14:45
-
-
Save iofjuupasli/0350c1bc9a6a31c1df8f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
return ( | |
<li className={classNames({ | |
completed: this.props.todo.completed, | |
editing: this.props.editing | |
})}> | |
<div className="view"> | |
<input | |
className="toggle" | |
type="checkbox" | |
checked={this.props.todo.completed} | |
onChange={this.props.onToggle} | |
/> | |
<label onDoubleClick={this.handleEdit}> | |
{this.props.todo.title} | |
</label> | |
<button className="destroy" onClick={this.props.onDestroy} /> | |
</div> | |
<input | |
ref="editField" | |
className="edit" | |
value={this.state.editText} | |
onBlur={this.handleSubmit} | |
onChange={this.handleChange} | |
onKeyDown={this.handleKeyDown} | |
/> | |
</li> | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment