ES6 rules
This commit is contained in:
@@ -12,7 +12,7 @@ function printData(data) {
|
||||
const printableData = Object.keys(data).map(key => `${key}: ${data[key]}`);
|
||||
|
||||
return (<textarea
|
||||
readOnly={true}
|
||||
readOnly
|
||||
onFocus={handleFocus}
|
||||
value={printableData.join('\n')}
|
||||
style={{
|
||||
|
@@ -22,7 +22,7 @@ const tabs = [
|
||||
];
|
||||
|
||||
function Tabs(props) {
|
||||
const tabLinks = tabs.map((tab, index) => {
|
||||
const tabLinks = tabs.map((tab) => {
|
||||
const tabClasses = classNames(
|
||||
'nav-tab',
|
||||
{ 'nav-tab-active': (props.tab === tab.name) }
|
||||
@@ -30,7 +30,7 @@ function Tabs(props) {
|
||||
|
||||
return (
|
||||
<Link
|
||||
key={`tab-${index}`}
|
||||
key={`tab-${tab.name}`}
|
||||
className={tabClasses}
|
||||
to={tab.link}
|
||||
>{ tab.label }</Link>
|
||||
|
@@ -1,11 +1,6 @@
|
||||
define([
|
||||
'react',
|
||||
'mailpoet',
|
||||
],
|
||||
(
|
||||
React,
|
||||
MailPoet
|
||||
) => {
|
||||
import React from 'react';
|
||||
import MailPoet from 'mailpoet';
|
||||
|
||||
const ListingBulkActions = React.createClass({
|
||||
getInitialState: function getInitialState() {
|
||||
return {
|
||||
@@ -96,10 +91,10 @@ define([
|
||||
onChange={this.handleChangeAction}
|
||||
>
|
||||
<option value="">{MailPoet.I18n.t('bulkActions')}</option>
|
||||
{ this.props.bulk_actions.map((action, index) => (
|
||||
{ this.props.bulk_actions.map(action => (
|
||||
<option
|
||||
value={action.name}
|
||||
key={`action-${index}`}
|
||||
key={`action-${action.name}`}
|
||||
>{ action.label }</option>
|
||||
)) }
|
||||
</select>
|
||||
@@ -116,5 +111,4 @@ define([
|
||||
},
|
||||
});
|
||||
|
||||
return ListingBulkActions;
|
||||
});
|
||||
export default ListingBulkActions;
|
||||
|
Reference in New Issue
Block a user