adds text for screen readers on toggle comments

This commit is contained in:
Alberto Garcia Cabeza
2016-12-05 14:26:54 +01:00
parent dd406cfeb0
commit ae12848e23
4 changed files with 5 additions and 1 deletions

View File

@@ -74,7 +74,8 @@
<% if comment.children.size > 0 %>
<%= link_to "", class: "js-toggle-children relative", data: {'id': "#{dom_id(comment)}"} do %>
<span class="sr-only"><%= t("shared.show") %></span>
<span class="sr-only js-child-toggle" style="display: none;"><%= t("shared.show") %></span>
<span class="sr-only js-child-toggle"><%= t("shared.hide") %></span>
<span id="<%= dom_id(comment) %>_children_arrow" class="icon-arrow-down"></span> <%= t("comments.comment.responses", count: comment.children.size) %>
<% end %>
<% else %>