Skip to content

Commit 9a87c1a

Browse files
MGaetan89scottgonzalez
authored andcommitted
Accordion: Fixed #7238 - Problem with accordion slide animation fixed width calculation
(cherry picked from commit 124cf3c)
1 parent 0fcf3d8 commit 9a87c1a

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

ui/jquery.ui.accordion.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -550,11 +550,11 @@ $.extend( $.ui.accordion, {
550550
// fix width before calculating height of hidden element
551551
var s = options.toShow;
552552
originalWidth = s[0].style.width;
553-
s.width( parseInt( s.parent().width(), 10 )
554-
- parseInt( s.css( "paddingLeft" ), 10 )
555-
- parseInt( s.css( "paddingRight" ), 10 )
556-
- ( parseInt( s.css( "borderLeftWidth" ), 10 ) || 0 )
557-
- ( parseInt( s.css( "borderRightWidth" ), 10) || 0 ) );
553+
s.width( s.parent().width()
554+
- parseFloat( s.css( "paddingLeft" ) )
555+
- parseFloat( s.css( "paddingRight" ) )
556+
- ( parseFloat( s.css( "borderLeftWidth" ) ) || 0 )
557+
- ( parseFloat( s.css( "borderRightWidth" ) ) || 0 ) );
558558

559559
$.each( fxAttrs, function( i, prop ) {
560560
hideProps[ prop ] = "hide";

0 commit comments

Comments
 (0)