diff --git a/public/js/components/feature/Feature.jsx b/public/js/components/feature/Feature.jsx index 40b93747e3..bf3f8ac58e 100644 --- a/public/js/components/feature/Feature.jsx +++ b/public/js/components/feature/Feature.jsx @@ -3,8 +3,6 @@ var FeatureForm = require('./FeatureForm'); var LogEntryList = require('../log/LogEntryList'); var eventStore = require('../../stores/EventStore'); - - var Feature = React.createClass({ getInitialState: function() { return { @@ -34,7 +32,7 @@ var Feature = React.createClass({ }, archiveFeature: function() { - if (confirm("Are you sure you want to delete " + this.props.feature.name + "?")) { + if (window.confirm("Are you sure you want to delete " + this.props.feature.name + "?")) { this.props.onArchive(this.props.feature); } }, @@ -60,7 +58,8 @@ var Feature = React.createClass({ - + @@ -77,17 +76,25 @@ var Feature = React.createClass({
-
-
-
diff --git a/public/js/components/feature/FeatureForm.jsx b/public/js/components/feature/FeatureForm.jsx index 87898da5dc..da03d987b9 100644 --- a/public/js/components/feature/FeatureForm.jsx +++ b/public/js/components/feature/FeatureForm.jsx @@ -90,7 +90,10 @@ var FeatureForm = React.createClass({
- {this.renderStrategyOptions()}
@@ -100,8 +103,13 @@ var FeatureForm = React.createClass({
  • - - + +
@@ -138,7 +146,7 @@ var FeatureForm = React.createClass({ name={param.name} label={param.name} ref={param.name} - value={param.value} /> + value={param.value} />; }); }, diff --git a/public/js/components/log/LogEntry.jsx b/public/js/components/log/LogEntry.jsx index d246139c45..ac45d5f3b1 100644 --- a/public/js/components/log/LogEntry.jsx +++ b/public/js/components/log/LogEntry.jsx @@ -6,14 +6,14 @@ var DIFF_PREFIXES = { E: ' ', D: '-', N: '+' -} +}; var SPADEN_CLASS = { A: 'blue', // array edited E: 'blue', // edited D: 'negative', // deleted N: 'positive', // added -} +}; var LogEntry = React.createClass({ propTypes: { @@ -47,13 +47,15 @@ var LogEntry = React.createClass({ var prettyPrinted = JSON.stringify(localEventData, null, 2); - return ({prettyPrinted}) + return ({prettyPrinted}); }, renderEventDiff: function() { if (!this.props.showFullEvents && this.props.event.diffs) { var changes = this.props.event.diffs.map(this.buildDiff); - return ({changes.length === 0 ? '(no changes)' : changes}) + return ( + {changes.length === 0 ? '(no changes)' : changes} + ); } else { return this.renderFullEventData(); } @@ -71,15 +73,15 @@ var LogEntry = React.createClass({
); } else { - var spadenClass = SPADEN_CLASS[diff.kind] + var spadenClass = SPADEN_CLASS[diff.kind]; var prefix = DIFF_PREFIXES[diff.kind]; - change = (
{prefix} {key}: {JSON.stringify(diff.rhs)}
) + change = (
{prefix} {key}: {JSON.stringify(diff.rhs)}
); } - return (
{change}
) + return (
{change}
); } }); -module.exports = LogEntry; \ No newline at end of file +module.exports = LogEntry; diff --git a/public/js/components/strategy/Strategy.jsx b/public/js/components/strategy/Strategy.jsx index b8c383b2e6..a4ff93ddd5 100644 --- a/public/js/components/strategy/Strategy.jsx +++ b/public/js/components/strategy/Strategy.jsx @@ -7,7 +7,8 @@ var Strategy = React.createClass({ onRemove: function(event) { event.preventDefault(); - if (confirm("Are you sure you want to delete strategy '"+this.props.strategy.name+"'?")) { + if (window.confirm("Are you sure you want to delete strategy '"+ + this.props.strategy.name+"'?")) { this.props.onRemove(this.props.strategy); } }, @@ -17,7 +18,9 @@ var Strategy = React.createClass({
{this.props.strategy.name} - (remove)
+ (remove)
{this.props.strategy.description}
@@ -25,4 +28,4 @@ var Strategy = React.createClass({ } }); -module.exports = Strategy; \ No newline at end of file +module.exports = Strategy; diff --git a/public/js/components/strategy/StrategyForm.jsx b/public/js/components/strategy/StrategyForm.jsx index dd65827c04..5904c2801a 100644 --- a/public/js/components/strategy/StrategyForm.jsx +++ b/public/js/components/strategy/StrategyForm.jsx @@ -50,7 +50,6 @@ var StrategyForm = React.createClass({ onRemoveParam: function(event) { event.preventDefault(); - var id = this.state.parameters.length + 1; var params = this.state.parameters.slice(0, -1); this.setState({parameters: params}); @@ -118,7 +117,7 @@ var StrategyForm = React.createClass({
- ) + ); }); }, @@ -131,11 +130,15 @@ var StrategyForm = React.createClass({ if(this.state.parameters.length > 0) { return (
- - Remove parameter + + - Remove parameter +
); } } }); -module.exports = StrategyForm; \ No newline at end of file +module.exports = StrategyForm;