Cosmetic refactoring
Этот коммит содержится в:
@@ -2,16 +2,23 @@
|
|||||||
// See License.txt for license information.
|
// See License.txt for license information.
|
||||||
|
|
||||||
module.exports = React.createClass({
|
module.exports = React.createClass({
|
||||||
|
displayName: 'SettingsItemMin',
|
||||||
|
propTypes: {
|
||||||
|
title: React.PropTypes.string,
|
||||||
|
disableOpen: React.PropTypes.bool,
|
||||||
|
updateSection: React.PropTypes.func,
|
||||||
|
describe: React.PropTypes.string
|
||||||
|
},
|
||||||
render: function() {
|
render: function() {
|
||||||
var editButton = '';
|
var editButton = '';
|
||||||
if(!this.props.disableOpen) {
|
if (!this.props.disableOpen) {
|
||||||
editButton = <li className="col-sm-2 section-edit"><a className="section-edit theme" href="#" onClick={this.props.updateSection}>Edit</a></li>;
|
editButton = <li className='col-sm-2 section-edit'><a className='section-edit theme' href='#' onClick={this.props.updateSection}>Edit</a></li>;
|
||||||
}
|
}
|
||||||
return (
|
return (
|
||||||
<ul className="section-min">
|
<ul className='section-min'>
|
||||||
<li className="col-sm-10 section-title">{this.props.title}</li>
|
<li className='col-sm-10 section-title'>{this.props.title}</li>
|
||||||
{editButton}
|
{editButton}
|
||||||
<li className="col-sm-7 section-describe">{this.props.describe}</li>
|
<li className='col-sm-7 section-describe'>{this.props.describe}</li>
|
||||||
</ul>
|
</ul>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user