]> git.immae.eu Git - github/shaarli/Shaarli.git/commitdiff
fix a11y
authorLuce Carević <lcarevic@access42.net>
Sat, 13 Jul 2019 16:56:43 +0000 (18:56 +0200)
committerLuce Carević <lcarevic@access42.net>
Sat, 13 Jul 2019 16:56:43 +0000 (18:56 +0200)
tpl/default/import.html
tpl/default/install.html
tpl/default/linklist.html
tpl/default/page.header.html
tpl/default/picwall.html
tpl/default/tag.cloud.html
tpl/default/tag.list.html

index 20f854d10d2f2be3736a55c4faea8ea4acfcf046..c41afcdbda76b69c43d7900ed08b092dc8649226 100644 (file)
@@ -69,7 +69,7 @@
         </div>
         <div class="pure-u-lg-2-3 pure-u-1">
           <div class="form-input">
-            <input type="text" name="default_tags" id="default_tags" placeholder="{'Tag'|t}">
+            <input type="text" name="default_tags" id="default_tags" aria-label="{'Tag'|t}" placeholder="{'Tag'|t}">
           </div>
         </div>
       </div>
index f0e7040e0545c56eefe78aaf42e6e58d71107486..c6f501f0aa25c30c1dae2df8bab256027d89b838 100644 (file)
@@ -17,7 +17,7 @@
     <h2 class="window-title">{'Install Shaarli'|t}</h2>
 
     <div class="center">
-      {'It looks like it\'s the first time you run Shaarli. Please configure it.'|t}
+      <p>{'It looks like it\'s the first time you run Shaarli. Please configure it.'|t}</p>
     </div>
 
     <div class="pure-g">
index a025d53ca2eca96c220b891587a346986b8276b2..b44d0783aa03f3e6aeebeb5c82cb28354c0c8d81 100644 (file)
 <div id="search-linklist" class="searchform-block search-linklist">
 
   <form method="GET" class="pure-form searchform" name="searchform">
-    <input type="text" tabindex="1" name="searchterm" class="searchterm" placeholder="{'Search text'|t}"
+    <input type="text" name="searchterm" class="searchterm" aria-label="{'Search text'|t}" placeholder="{'Search text'|t}"
            {if="!empty($search_term)"}
            value="{$search_term}"
            {/if}
     >
-    <input type="text" tabindex="2" name="searchtags" class="searchtags" placeholder="{'Filter by tag'|t}"
+    <input type="text" name="searchtags" class="searchtags" aria-label="{'Filter by tag'|t}" placeholder="{'Filter by tag'|t}"
            {if="!empty($search_tags)"}
            value="{$search_tags}"
            {/if}
     autocomplete="off" data-multiple data-autofirst data-minChars="1"
     data-list="{loop="$tags"}{$key}, {/loop}"
     >
-    <button type="submit" class="search-button"><i class="fa fa-search"></i></button>
+    <button type="submit" class="search-button" aria-label="{'Search'|t}"><i class="fa fa-search" aria-hidden="true"></i></button>
   </form>
 </div>
 
@@ -94,7 +94,7 @@
           {'tagged'|t}
           {loop="$exploded_tags"}
               <span class="label label-tag" title="{'Remove tag'|t}">
-                <a href="?removetag={function="urlencode($value)"}">{$value}<span class="remove"><i class="fa fa-times" aria-hidden="true"></i></span></a>
+                <a href="?removetag={function="urlencode($value)"}" aria-label="{'Remove tag'|t}">{$value}<span class="remove"><i class="fa fa-times" aria-hidden="true"></i></span></a>
               </span>
           {/loop}
         {/if}
             {if="$thumbnails_enabled && !empty($value.thumbnail)"}
               <div class="linklist-item-thumbnail" style="width:{$thumbnails_width}px;height:{$thumbnails_height}px;">
                 <div class="thumbnail">
-                  <a href="{$value.real_url}">
                   {ignore}RainTPL hack: put the 2 src on two different line to avoid path replace bug{/ignore}
                   <img data-src="{$value.thumbnail}#" class="b-lazy"
                     src=""
-                    alt="thumbnail" width="{$thumbnails_width}" height="{$thumbnails_height}" />
-                  </a>
+                    alt="" width="{$thumbnails_width}" height="{$thumbnails_height}" />
                 </div>
               </div>
             {/if}
             <h2>
               <a href="{$value.real_url}">
                 {if="strpos($value.url, $value.shorturl) === false"}
-                  <i class="fa fa-external-link"></i>
+                  <i class="fa fa-external-link" aria-hidden="true"></i>
                 {else}
-                  <i class="fa fa-sticky-note"></i>
+                  <i class="fa fa-sticky-note" aria-hidden="true"></i>
                 {/if}
 
                 <span class="linklist-link">{$value.title}</span>
           <div class="linklist-item-infos clear">
             {if="$value.tags"}
               <div class="linklist-item-tags">
-                <i class="fa fa-tags"></i>
+                <i class="fa fa-tags" aria-hidden="true"></i>
                 {$tag_counter=count($value.taglist)}
                 {loop="value.taglist"}
                   <span class="label label-tag" title="{$strAddTag}">
                     <div class="linklist-item-infos-controls-group pure-u-0 pure-u-lg-visible">
                       <span class="linklist-item-infos-controls-item ctrl-pin">
                         <span title="{$strSticky}" class="pin-link pinned-link pure-u-0 pure-u-lg-visible">
-                          <i class="fa fa-thumb-tack"></i>
+                          <i class="fa fa-thumb-tack" aria-hidden="true"></i>
                         </span>
                       </span>
                     </div>
                   {if="!$hide_timestamps || $is_logged_in"}
                     {$updated=$value.updated_timestamp ? $strEdited. format_date($value.updated) : $strPermalink}
                     <span class="linkdate" title="{$updated}">
-                      <i class="fa fa-clock-o"></i>
+                      <i class="fa fa-clock-o" aria-hidden="true"></i>
                       {$value.created|format_date}
                       {if="$value.updated_timestamp"}*{/if}
                       &middot;
               </div><div
                 {ignore}do not add space or line break between these div - Firefox issue{/ignore}
                 class="linklist-item-infos-url pure-u-lg-5-12 pure-u-1">
-                <a href="{$value.real_url}" title="{$value.title}">
+                <a href="{$value.real_url}" aria-label="{$value.title}" title="{$value.title}">
                   <i class="fa fa-link" aria-hidden="true"></i> {$value.url}
                 </a>
                 <div class="linklist-item-buttons pure-u-0 pure-u-lg-visible">
index 93825fb5880f7a14b2863a4ee724c62f9b38c4a9..4f063dc303f9c182347b2c17ad4a0a7d33d10bbe 100644 (file)
   {if="!$is_logged_in"}
     <form method="post" name="loginform">
       <div class="subheader-form header-login-form" id="header-login-form">
-        <input type="text" name="login" placeholder="{'Username'|t}" >
-        <input type="password" name="password" placeholder="{'Password'|t}" >
+        <input type="text" name="login" aria-label="{'Username'|t}" placeholder="{'Username'|t}" >
+        <input type="password" name="password" aria-label="{'Password'|t}" placeholder="{'Password'|t}" >
         <div class="remember-me">
           <input type="checkbox" name="longlastingsession" id="longlastingsession" checked>
           <label for="longlastingsession">{'Remember me'|t}</label>
index dd8c17fc308e397628f7742b89e920f6a30970df..73359949ce433cb96dc0e6510c56e6e22933602c 100644 (file)
@@ -32,9 +32,9 @@
         {/loop}
       </div>
 
-      <div id="picwall-container" class="picwall-container">
+      <div id="picwall-container" class="picwall-container" role="list">
         {loop="$linksToDisplay"}
-          <div class="picwall-pictureframe">
+          <div class="picwall-pictureframe" role="listitem">
             {ignore}RainTPL hack: put the 2 src on two different line to avoid path replace bug{/ignore}
             <img data-src="{$value.thumbnail}#" class="b-lazy"
                  src=""
index bedf3f8cbdc48badba69a568f2e5b71cd33a3d70..b9c0b16211d53660388eda9a5105e86933236a7b 100644 (file)
       <div class="pure-u-1 pure-u-lg-1-2">
         <form method="GET">
           <input type="hidden" name="do" value="tagcloud">
-          <input type="text" name="searchtags" placeholder="{'Filter by tag'|t}"
+          <input type="text" name="searchtags" aria-label="{'Filter by tag'|t}" placeholder="{'Filter by tag'|t}"
                  {if="!empty($search_tags)"}
                     value="{$search_tags}"
                  {/if}
           autocomplete="off" data-multiple data-autofirst data-minChars="1"
           data-list="{loop="$tags"}{$key}, {/loop}"
           >
-          <button type="submit" class="search-button"><i class="fa fa-search"></i></button>
+          <button type="submit" class="search-button" aria-label="{'Search'|t}"><i class="fa fa-search" aria-hidden="true"></i></button>
         </form>
       </div>
       <div class="pure-u-lg-1-4"></div>
index 41eab246896b6d932644bb39ca9dcdb6dbf7c8a8..d5777465ce3177e62fc59f52c0cd70506e32306b 100644 (file)
       <div class="pure-u-1 pure-u-lg-1-2">
         <form method="GET">
           <input type="hidden" name="do" value="taglist">
-          <input type="text" name="searchtags" placeholder="{'Filter by tag'|t}"
+          <input type="text" name="searchtags" aria-label="{'Filter by tag'|t}" placeholder="{'Filter by tag'|t}"
                  {if="!empty($search_tags)"}
                  value="{$search_tags}"
                  {/if}
           autocomplete="off" data-multiple data-autofirst data-minChars="1"
           data-list="{loop="$tags"}{$key}, {/loop}"
           >
-          <button type="submit" class="search-button"><i class="fa fa-search"></i></button>
+          <button type="submit" class="search-button" aria-label="{'Search'|t}"><i class="fa fa-search" aria-hidden="true"></i></button>
         </form>
       </div>
       <div class="pure-u-lg-1-4"></div>
@@ -50,9 +50,9 @@
         <div class="tag-list-item pure-g" data-tag="{$key}">
           <div class="pure-u-1">
             {if="$is_logged_in===true"}
-              <a href="#" class="delete-tag"><i class="fa fa-trash"></i></a>&nbsp;&nbsp;
-              <a href="?do=changetag&fromtag={$key|urlencode}" class="rename-tag">
-                <i class="fa fa-pencil-square-o {$key}"></i>
+              <a href="#" class="delete-tag" aria-label="{'Delete'|t}"><i class="fa fa-trash" aria-hidden="true"></i></a>&nbsp;&nbsp;
+              <a href="?do=changetag&fromtag={$key|urlencode}" class="rename-tag" aria-label="{'Rename tag'|t}">
+                <i class="fa fa-pencil-square-o {$key}" aria-hidden="true"></i>
               </a>
             {/if}
 
@@ -66,7 +66,7 @@
           {if="$is_logged_in===true"}
             <div class="rename-tag-form pure-u-1">
               <input type="text" name="{$key}" value="{$key}" class="rename-tag-input" />
-              <a href="#" class="validate-rename-tag"><i class="fa fa-check"></i></a>
+              <a href="#" class="validate-rename-tag"><i class="fa fa-check" aria-hidden="true"></i></a>
             </div>
           {/if}
         </div>