Fix eslint6 jsx-a11y/no-static-element-interactions
[MAILPOET-1140]
This commit is contained in:
@@ -74,7 +74,11 @@ const ListingColumn = React.createClass({
|
||||
|
||||
if (this.props.column.sortable === true) {
|
||||
label = (
|
||||
<a onClick={this.handleSort}>
|
||||
<a
|
||||
onClick={this.handleSort}
|
||||
role="button"
|
||||
tabIndex={0}
|
||||
>
|
||||
<span>{ this.props.column.label }</span>
|
||||
<span className="sorting-indicator" />
|
||||
</a>
|
||||
@@ -84,6 +88,7 @@ const ListingColumn = React.createClass({
|
||||
}
|
||||
return (
|
||||
<th
|
||||
role="columnheader"
|
||||
className={classes}
|
||||
id={this.props.column.name}
|
||||
scope="col"
|
||||
|
@@ -90,6 +90,8 @@ const ListingItem = React.createClass({
|
||||
<span
|
||||
onClick={this.props.onRefreshItems}
|
||||
key={`action-${index}`} className={action.name}
|
||||
role="button"
|
||||
tabIndex={index}
|
||||
>
|
||||
{(!isFirst) ? ' | ' : ''}
|
||||
{ action.link(this.props.item) }
|
||||
|
@@ -127,12 +127,16 @@ class TemplateBox extends React.Component {
|
||||
<a
|
||||
className="button button-secondary"
|
||||
onClick={this.onPreview}
|
||||
role="button"
|
||||
tabIndex={0}
|
||||
>{MailPoet.I18n.t('preview')}</a>
|
||||
|
||||
<a
|
||||
className="button button-primary"
|
||||
data-automation-id={`select_template_${index}`}
|
||||
onClick={this.onSelect}
|
||||
role="button"
|
||||
tabIndex={0}
|
||||
> {MailPoet.I18n.t('select')} </a>
|
||||
</div>
|
||||
{ readonly === '1' ? false : deleteLink }
|
||||
|
@@ -81,7 +81,13 @@ define(
|
||||
description: MailPoet.I18n.t('regularNewsletterTypeDescription'),
|
||||
action: function () {
|
||||
return (
|
||||
<a className="button button-primary" data-automation-id="create_standard" onClick={this.createNewsletter.bind(null, 'standard')}>
|
||||
<a
|
||||
className="button button-primary"
|
||||
data-automation-id="create_standard"
|
||||
onClick={this.createNewsletter.bind(null, 'standard')}
|
||||
role="button"
|
||||
tabIndex={0}
|
||||
>
|
||||
{MailPoet.I18n.t('create')}
|
||||
</a>
|
||||
);
|
||||
@@ -107,7 +113,13 @@ define(
|
||||
description: MailPoet.I18n.t('postNotificationNewsletterTypeDescription'),
|
||||
action: function () {
|
||||
return (
|
||||
<a className="button button-primary" data-automation-id="create_notification" onClick={this.setupNewsletter.bind(null, 'notification')}>
|
||||
<a
|
||||
className="button button-primary"
|
||||
data-automation-id="create_notification"
|
||||
onClick={this.setupNewsletter.bind(null, 'notification')}
|
||||
role="button"
|
||||
tabIndex={0}
|
||||
>
|
||||
{MailPoet.I18n.t('setUp')}
|
||||
</a>
|
||||
);
|
||||
|
Reference in New Issue
Block a user