[wp-trac] [WordPress Trac] #20035: Tab styling for UI Tabs

WordPress Trac wp-trac at lists.automattic.com
Mon Feb 13 21:29:41 UTC 2012


#20035: Tab styling for UI Tabs
---------------------------+-----------------------------
 Reporter:  aaroncampbell  |      Owner:
     Type:  defect (bug)   |     Status:  new
 Priority:  normal         |  Milestone:  Awaiting Review
Component:  General        |    Version:  3.3
 Severity:  normal         |   Keywords:  has-patch
---------------------------+-----------------------------
 We include the jQuery UI tabs with the WP package now, but using to
 duplicate WP-style tabs requires some funky JS workarounds to add the `wp-
 tab-active` class to the tab instead of just the default `ui-tabs-
 selected` class.  Since there's no way to specify what class is used for
 the selected tab, I suggest we simply add support for the `ui-tabs-
 selected` class in our stylesheets.

 For those that need something sooner, you can use this to make your tabs
 use the default wp-admin styles:
 {{{
 jQuery(function($) {
         $( '.tabbed-content' ).tabs();
         $( '.tabbed-content' ).bind( 'tabsshow', function(event, ui) {
                 $( '.wp-tab-active' ).removeClass( 'wp-tab-active' );
                 $( '.ui-tabs-selected' ).addClass( 'wp-tab-active' );
         });
 });
 }}}

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/20035>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list