From edaa2d2de8f92d80f1c61f5a62b295e708219355 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javi=20Mart=C3=ADn?= Date: Sat, 12 Jun 2021 00:13:45 +0200 Subject: [PATCH 1/2] Fix missing alt attribute in phases images An image without an alt text is invalid HTML and is confusing for screen reader users. This is just a quick patch which partially solves this problem. The image doesn't necessarily need to be a decorative one, so administrators should have the option to provide an alternative text for the images. --- app/components/budgets/phases_component.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/components/budgets/phases_component.html.erb b/app/components/budgets/phases_component.html.erb index 6e4b66bf0..8c881a4f1 100644 --- a/app/components/budgets/phases_component.html.erb +++ b/app/components/budgets/phases_component.html.erb @@ -55,7 +55,7 @@ <% if phase.image.present? %>
- <%= image_tag phase.image.attachment.url(:large) %> + <%= image_tag phase.image.attachment.url(:large), alt: "" %>
<% end %> From f3a3bf35f80c9474a3ec2b9e51db16d807f72df4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javi=20Mart=C3=ADn?= Date: Sat, 12 Jun 2021 01:20:18 +0200 Subject: [PATCH 2/2] Fix contrast in investment list The color we used offered a contrast of 3.94 against the background. The minimum requirement for AA level is a contrast of 4.5, and we usually aim for a contrast of 5 at least. So we're making the text slightly darker so it's easier to read. --- app/assets/stylesheets/budgets/investments-list.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/assets/stylesheets/budgets/investments-list.scss b/app/assets/stylesheets/budgets/investments-list.scss index a5d8b8973..8846ff592 100644 --- a/app/assets/stylesheets/budgets/investments-list.scss +++ b/app/assets/stylesheets/budgets/investments-list.scss @@ -62,7 +62,7 @@ .price-title, .supports-title { - color: #7b7b7b; + color: #696969; font-size: $small-font-size; text-transform: uppercase; width: 100%;