Created
October 9, 2014 15:04
-
-
Save faust45/d9cf902a1a89b8a29f62 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
| render: function() { | |
| var channel = getChannel("changed:score"); | |
| var inputs = _.map(this.props.end_scores, function(es) { | |
| var channelScore = comp(channel, withId(es.id), value("score")); | |
| var classes = cx({ | |
| 'end-hammer': es.isHammer, | |
| }); | |
| return ( | |
| <td className={classes}> | |
| <input | |
| className="string optional form-control score" | |
| type="text" | |
| maxLength="1" | |
| max="8" | |
| tabIndex={es.tabindex} | |
| autofocus="autofocus" | |
| defaultValue={es.score} | |
| onBlur={channelScore} /> | |
| </td> | |
| ) | |
| }); | |
| return ( | |
| <tr> | |
| <td className={this.props.color+"-rock"}> | |
| <b>{this.props.team} {this.props.first_hammer && "*"}</b> | |
| </td> | |
| {inputs} | |
| <td>{this.props.total}</td> | |
| </tr> | |
| ) | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment