Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Panel: Only apply active state to button styled links.

commit 901586662ae96d1e7a8ec529043f43c978818f5f 1 parent ab3c819
@jaspermdegroot jaspermdegroot authored
Showing with 6 additions and 4 deletions.
  1. +6 −4 js/widgets/panel.js
View
10 js/widgets/panel.js
@@ -207,10 +207,12 @@ $.widget( "mobile.panel", $.mobile.widget, {
if ( this.href.split( "#" )[ 1 ] === self._panelID && self._panelID !== undefined ) {
e.preventDefault();
var $link = $( this );
- $link.addClass( $.mobile.activeBtnClass );
- self.element.one( "panelopen panelclose", function() {
- $link.removeClass( $.mobile.activeBtnClass );
- });
+ if ( $link.is( ":jqmData(role='button')" ) ) {
+ $link.addClass( $.mobile.activeBtnClass );
+ self.element.one( "panelopen panelclose", function() {
+ $link.removeClass( $.mobile.activeBtnClass );
+ });
+ }
self.toggle();
return false;
}
Please sign in to comment.
Something went wrong with that request. Please try again.