[wp-trac] [WordPress Trac] #22087: Twenty Twelve: accessibility sweep

WordPress Trac noreply at wordpress.org
Fri Oct 26 18:00:14 UTC 2012


#22087: Twenty Twelve: accessibility sweep
---------------------------+------------------
 Reporter:  lancewillett   |       Owner:
     Type:  defect (bug)   |      Status:  new
 Priority:  normal         |   Milestone:  3.5
Component:  Bundled Theme  |     Version:
 Severity:  normal         |  Resolution:
 Keywords:  needs-patch    |
---------------------------+------------------
Changes (by pauljadam):

 * cc: pauljadam (added)
 * type:  enhancement => defect (bug)


Comment:

 Skip link broken in webkit.

 This jQuery code will fix it.

 {{{


         // Set tabindex on the main and section divs so IE knows they are
 focusable, and so Webkit browsers will focus() them.
         $('#main').attr('tabindex', -1);

         var is_webkit =
 navigator.userAgent.toLowerCase().indexOf('webkit') > -1;
         var is_opera = navigator.userAgent.toLowerCase().indexOf('opera')
 > -1;

         // If Webkit, set focus to it.
         $("a[href^='#']").click(function(event){
                 var clickAnchor="#"+this.href.split('#')[1];
                 if(is_webkit || is_opera)
                 {
                         $(clickAnchor).focus();
                 }
         });

 }}}

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/22087#comment:5>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list