[Glitch] Ensure tabIndex is number instead of string
Port ec0c104bf2
to glitch-soc
Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
@ -36,7 +36,7 @@ export default class ActionsModal extends ImmutablePureComponent {
|
||||
if (!contents) {
|
||||
contents = (
|
||||
<React.Fragment>
|
||||
{icon && <IconButton title={text} icon={icon} role='presentation' tabIndex='-1' inverted />}
|
||||
{icon && <IconButton title={text} icon={icon} role='presentation' tabIndex={-1} inverted />}
|
||||
<div>
|
||||
<div className={classNames({ 'actions-modal__item-label': !!meta })}>{text}</div>
|
||||
<div>{meta}</div>
|
||||
|
@ -32,7 +32,7 @@ const ColumnLink = ({ icon, text, to, onClick, href, method, badge, transparent,
|
||||
return onClick(e);
|
||||
};
|
||||
return (
|
||||
<a href='#' onClick={onClick && handleOnClick} className={className} title={text} {...other} tabIndex='0'>
|
||||
<a href='#' onClick={onClick && handleOnClick} className={className} title={text} {...other} tabIndex={0}>
|
||||
{iconElement}
|
||||
<span>{text}</span>
|
||||
{badgeElement}
|
||||
|
@ -140,8 +140,8 @@ class MediaModal extends ImmutablePureComponent {
|
||||
|
||||
const index = this.getIndex();
|
||||
|
||||
const leftNav = media.size > 1 && <button tabIndex='0' className='media-modal__nav media-modal__nav--left' onClick={this.handlePrevClick} aria-label={intl.formatMessage(messages.previous)}><Icon id='chevron-left' fixedWidth /></button>;
|
||||
const rightNav = media.size > 1 && <button tabIndex='0' className='media-modal__nav media-modal__nav--right' onClick={this.handleNextClick} aria-label={intl.formatMessage(messages.next)}><Icon id='chevron-right' fixedWidth /></button>;
|
||||
const leftNav = media.size > 1 && <button tabIndex={0} className='media-modal__nav media-modal__nav--left' onClick={this.handlePrevClick} aria-label={intl.formatMessage(messages.previous)}><Icon id='chevron-left' fixedWidth /></button>;
|
||||
const rightNav = media.size > 1 && <button tabIndex={0} className='media-modal__nav media-modal__nav--right' onClick={this.handleNextClick} aria-label={intl.formatMessage(messages.next)}><Icon id='chevron-right' fixedWidth /></button>;
|
||||
|
||||
const content = media.map((image) => {
|
||||
const width = image.getIn(['meta', 'original', 'width']) || null;
|
||||
|
@ -299,7 +299,7 @@ class OnboardingModal extends React.PureComponent {
|
||||
<div
|
||||
key={`dot-${i}`}
|
||||
role='button'
|
||||
tabIndex='0'
|
||||
tabIndex={0}
|
||||
data-index={i}
|
||||
onClick={this.handleDot}
|
||||
className={className}
|
||||
|
Reference in New Issue
Block a user