nextcloud / photos

📸 Your memories under your control
GNU Affero General Public License v3.0
570 stars 62 forks source link

[BITV] 9.1.4.11/4.3 - Media files marked as selected - The checkboxes do not meet the contrast requirements for graphical informative elements depending on the background (1) #2160

Closed JuliaKirschenheuter closed 10 months ago

JuliaKirschenheuter commented 10 months ago

Blocked by

as the contrast ratio with the background is below 3:1. It is recommended to place these elements outside of images. The issue also affects unselected checkboxes (see screenshot)

image image

https://report.bitvtest.de/default-en/cbedb5ef-4815-4cba-a83d-995599c178c3.html#checkpoint-3dbfb7615a-v4-n3

susnux commented 10 months ago

Idea: add some blur background to ensure contrast, similar to the dashboard widgets

JuliaKirschenheuter commented 10 months ago

@artonge could you please help us with this ticket?

artonge commented 10 months ago

This was the original design. It got broken due to some change in @nc/vue internal. I should have set up visual tests :see_no_evil:.

Shall we go with that?

Before After
Unchecked & Picture hovered Screenshot from 2023-12-06 15-37-17
Unchecked & Checkbox hovered Screenshot from 2023-12-06 15-37-07
Checked & Checkbox hovered Screenshot from 2023-12-06 15-37-02
Checked Screenshot from 2023-12-06 15-37-22
artonge commented 10 months ago

PR: https://github.com/nextcloud/photos/pull/2182

JuliaKirschenheuter commented 10 months ago

Thank you @artonge!

"Unchecked & Picture hovered" and "Checked" still remaining not accessible ;(

I would suggest not to have special hover styles, because they are not relevant for a11y and leave everything only on checked and unchecked state, like:

Before After
Unchecked and Checkbox unhovered and hovered Screenshot from 2023-12-06 15-37-07
Checked and Checkbox unhovered and hovered Screenshot from 2023-12-06 15-37-02

Focus state have to have a double outline (black and white) like on most buttons:

Screenshot from 2023-12-13 17-20-18

In light theme background have to be not dark but light like:

Screenshot from 2023-12-13 17-16-45

@nimishavijay would you approve such solution?

artonge commented 10 months ago

I would suggest not to have special hover styles, because they are not relevant for a11y and leave everything only on checked and unchecked state, like:

That's what I ended up doing :), but I thought I updated the description :thinking:

nimishavijay commented 10 months ago

Sounds good to me as well. So when you hover over the picture, the checkbox with the background appears, and when you hover over the checkbox, it shows the normal hover feedback for a checkbox component. Would that work? :)