Skip to content

Commit 723782d

Browse files
committed
Tabs: Added tab hover and focus support. For #3651 Update markup to new UI CSS Framework specs
1 parent ba704e3 commit 723782d

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

ui/ui.tabs.js

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,24 @@ $.widget("ui.tabs", {
7878

7979
var self = this, o = this.options;
8080

81+
this.$lis
82+
.hover(
83+
function() {
84+
$(this).addClass('ui-state-hover');
85+
},
86+
function() {
87+
$(this).removeClass('ui-state-hover');
88+
}
89+
);
90+
91+
this.$tabs
92+
.focus(function() {
93+
$(this).parent().addClass('ui-state-focus');
94+
})
95+
.blur(function() {
96+
$(this).parent().removeClass('ui-state-focus');
97+
})
98+
8199
this.$tabs.each(function(i, a) {
82100
// inline tab
83101
if (a.hash && a.hash.replace('#', '')) // Safari 2 reports '#' for an empty hash

0 commit comments

Comments
 (0)