Skip to content
Browse files

Accordion: Added ui-accordion-header-icon class to generated icons in…

… order to not interfere with any additional icons that users might add.
  • Loading branch information...
1 parent 002f9a2 commit f1ff9b8f4d027207ebebce09c784b986b10fcf3c @scottgonzalez scottgonzalez committed Feb 2, 2011
Showing with 7 additions and 7 deletions.
  1. +1 −1 themes/base/jquery.ui.accordion.css
  2. +6 −6 ui/jquery.ui.accordion.js
View
2 themes/base/jquery.ui.accordion.css
@@ -13,6 +13,6 @@
.ui-accordion .ui-accordion-header-active { border-bottom: 0 !important; }
.ui-accordion .ui-accordion-heading { display: block; font-size: 1em; padding: .5em .5em .5em .7em; }
.ui-accordion-icons .ui-accordion-heading { padding-left: 2.2em; }
-.ui-accordion .ui-accordion-header .ui-icon { position: absolute; left: .5em; top: 50%; margin-top: -8px; }
+.ui-accordion .ui-accordion-header .ui-accordion-header-icon { position: absolute; left: .5em; top: 50%; margin-top: -8px; }
.ui-accordion .ui-accordion-content { padding: 1em 2.2em; border-top: 0; margin-top: -2px; position: relative; top: 1px; margin-bottom: 2px; overflow: auto; display: none; zoom: 1; }
.ui-accordion .ui-accordion-content-active { display: block; }
View
12 ui/jquery.ui.accordion.js
@@ -98,17 +98,17 @@ $.widget( "ui.accordion", {
var icons = this.options.icons;
if ( icons ) {
$( "<span>" )
- .addClass( "ui-icon " + icons.header )
+ .addClass( "ui-accordion-header-icon ui-icon " + icons.header )
.prependTo( this.headers );
- this.active.children( ".ui-icon" )
+ this.active.children( ".ui-accordion-header-icon" )
.removeClass( icons.header )
.addClass( icons.activeHeader );
this.element.addClass( "ui-accordion-icons" );
}
},
_destroyIcons: function() {
- this.headers.children( ".ui-icon" ).remove();
+ this.headers.children( ".ui-accordion-header-icon" ).remove();
this.element.removeClass( "ui-accordion-icons" );
},
@@ -272,7 +272,7 @@ $.widget( "ui.accordion", {
this.active
.removeClass( "ui-state-active ui-corner-top" )
.addClass( "ui-state-default ui-corner-all" )
- .children( ".ui-icon" )
+ .children( ".ui-accordion-header-icon" )
.removeClass( this.options.icons.activeHeader )
.addClass( this.options.icons.header );
this.active.next().addClass( "ui-accordion-content-active" );
@@ -345,14 +345,14 @@ $.widget( "ui.accordion", {
active
.removeClass( "ui-state-active ui-corner-top" )
.addClass( "ui-state-default ui-corner-all" )
- .children( ".ui-icon" )
+ .children( ".ui-accordion-header-icon" )
.removeClass( options.icons.activeHeader )
.addClass( options.icons.header );
if ( !clickedIsActive ) {
clicked
.removeClass( "ui-state-default ui-corner-all" )
.addClass( "ui-state-active ui-corner-top" )
- .children( ".ui-icon" )
+ .children( ".ui-accordion-header-icon" )
.removeClass( options.icons.header )
.addClass( options.icons.activeHeader );
clicked

0 comments on commit f1ff9b8

Please sign in to comment.
Something went wrong with that request. Please try again.