improve accessibility

* add 'aria-label' into some elements without the label
* add 'aris-label' into some visual elements
* replace some 'a' elements have a button action to 'button'
This commit is contained in:
Tada, Tadashi
2021-04-30 17:23:48 +09:00
parent 87846e6cda
commit 27f02c2dc9
6 changed files with 17 additions and 17 deletions
+4 -4
View File
@@ -3,14 +3,14 @@
<span style="color:#eee;margin-left:10px;">
Font Size:
<a data-no-turbolink='true' href="/dashboard/home?font=8pt" style="font-size:10pt;color:#eee;">A</a>
<a data-no-turbolink='true' href="/dashboard/home?font=200%25" style="font-size:18pt;color:#eee;">A</a>
<a data-no-turbolink='true' href="/dashboard/home?font=8pt" style="font-size:10pt;color:#eee" aria-label="small font">A</a>
<a data-no-turbolink='true' href="/dashboard/home?font=200%25" style="font-size:18pt;color:#eee;" aria-label="large font">A</a>
</span>
<div class="user-profile">
<a data-toggle="dropdown" class="dropdown-toggle">
<button data-toggle="dropdown" class="dropdown-toggle">
<img src=" <%= image_path('profile_color.jpg')%>" alt="profile">
</a>
</button>
<span class="caret"></span>
<ul class="dropdown-menu pull-right">
<li>
+3 -3
View File
@@ -2,17 +2,17 @@
<% name = name.to_sym %>
<% if name == :error %>
<div class="alert alert-error">
<a class="close" data-dismiss="alert" href="#">×</a>
<a class="close" aria-label="dismiss" data-dismiss="alert" href="#">×</a>
<%= content_tag :div, msg, :id => "flash_notice" %>
</div>
<% elsif name == :success %>
<div class="alert alert-success">
<a class="close" data-dismiss="alert" href="#">×</a>
<a class="close" aria-label="dismiss" data-dismiss="alert" href="#">×</a>
<%= content_tag :div, msg, :id => "flash_notice" %>
</div>
<% elsif name == :info %>
<div class="alert alert-info">
<a class="close" data-dismiss="alert" href="#">×</a>
<a class="close" aria-label="dismiss" data-dismiss="alert" href="#">×</a>
<%= content_tag :div, msg, :id => "flash_notice" %>
</div>
<% end %>