Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix accessibility issues shown in chrome lighthouse audit #118

Merged
merged 1 commit into from
Oct 12, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,16 @@
}
.subtitle {
font-size: 14px;
color: #777;
color: #6e6e6e;
}
.addnew {
font-size: 12px;
text-decoration: none;
color: #3498db;
color: #2373a8;
padding: 5px;
}
.addnew:hover {
border-bottom: 1px solid #3498db;
border-bottom: 1px solid #2373a8;
}
.addnewplus {
font-size: 21px;
Expand Down
10 changes: 5 additions & 5 deletions src/components/ColorList/ColorList.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,14 @@ const ColorList = ({colors,
pickerStatus
}) => {
return (
<div>
<ul className="color-list">
{colors.map(colorItem =>
<li
className="color-list__item"
key={colorItem.color}
>
<button
<button title="Select background color"
onClick={(e) => {
e.preventDefault();
onColorChange(colorItem.color, true); // Pass true to hide picker on color change
Expand All @@ -32,7 +33,8 @@ const ColorList = ({colors,
<ReactTooltip place="top" type="dark" effect="solid"/>
</li>
)}
<button
</ul>
<button
onClick={(e) => {
e.preventDefault();

Expand All @@ -42,9 +44,7 @@ const ColorList = ({colors,
}}
data-tip={pickerStatus ? 'Close' : 'Choose a custom color'}
className='color-list__button picker'><span>{pickerStatus ? 'X' : '#'}</span></button>
</ul>


</div>
);
};

Expand Down