Replaced anchor by span to prevent accessibility error

This commit is contained in:
Alejandro Celaya 2018-08-20 10:04:17 +02:00
parent 84d012d7af
commit d84bf01937
2 changed files with 2 additions and 2 deletions

View file

@ -36,7 +36,7 @@
margin-left: 8px;
}
.react-tagsinput-tag a::before {
.react-tagsinput-tag span::before {
content: "\2715";
color: #fff;
}

View file

@ -20,7 +20,7 @@ export default function TagsSelector({ tags, onChange, placeholder, colorGenerat
return (
<span key={key} style={{ backgroundColor: colorGenerator.getColorForKey(tag) }} {...other}>
{getTagDisplayValue(tag)}
{!disabled && <a className={classNameRemove} onClick={() => onRemove(key)}> </a>}
{!disabled && <span className={classNameRemove} onClick={() => onRemove(key)} />}
</span>
)
};