Lint fixes

This commit is contained in:
Cmdr McDonald
2017-01-24 11:41:50 +00:00
parent fdb931fe00
commit 50e1f7d4df
3 changed files with 9 additions and 10 deletions

View File

@@ -25,11 +25,11 @@ const SIZE_RANGE = 0.55;
* @return {Number} Normalized value * @return {Number} Normalized value
*/ */
function normalizePercent(val) { function normalizePercent(val) {
if (val === '' || isNaN(val)) { if (val === '' || isNaN(val)) {
return 0; return 0;
} }
val = Math.round(val * 1000) / 1000; val = Math.round(val * 1000) / 1000;
return val >= 100 ? 100 : val; return val >= 100 ? 100 : val;
} }
/** /**
@@ -38,7 +38,7 @@ function normalizePercent(val) {
* @return {Number} Rounded value * @return {Number} Rounded value
*/ */
function nearestQtrPct(val) { function nearestQtrPct(val) {
return Math.round(val * 4) / 4; return Math.round(val * 4) / 4;
} }
/** /**
@@ -46,7 +46,7 @@ function nearestQtrPct(val) {
* @param {SyntheticEvent} e Event * @param {SyntheticEvent} e Event
*/ */
function selectAll(e) { function selectAll(e) {
e.target.select(); e.target.select();
} }
/** /**

View File

@@ -40,7 +40,7 @@ export default class ModalHelp extends TranslatedComponent {
return <div className='modal' onClick={ (e) => e.stopPropagation() }> return <div className='modal' onClick={ (e) => e.stopPropagation() }>
<h2>{translate(this.props.title || 'Help')}</h2> <h2>{translate(this.props.title || 'Help')}</h2>
<div dangerouslySetInnerHTML={{__html: text}} /> <div dangerouslySetInnerHTML={{ __html: text }} />
<button className='r dismiss cap' onClick={this.context.hideModal}>{translate('close')}</button> <button className='r dismiss cap' onClick={this.context.hideModal}>{translate('close')}</button>
</div>; </div>;
} }

View File

@@ -294,12 +294,11 @@ export default class OutfittingPage extends Page {
case 69: // 'e' case 69: // 'e'
if (e.ctrlKey || e.metaKey) { // CTRL/CMD + e if (e.ctrlKey || e.metaKey) { // CTRL/CMD + e
e.preventDefault(); e.preventDefault();
console.log('Export')
this._exportBuild(); this._exportBuild();
} }
break; break;
}
} }
}
/** /**
* Render the Page * Render the Page