11/**
22* @ngdoc overview
33* @name ui.bootstrap.carousel
4- *
4+ *
55* @description
66* AngularJS version of an image carousel.
77*
@@ -32,10 +32,10 @@ angular.module('ui.bootstrap.carousel', ['ui.bootstrap.transition'])
3232 }
3333 function goNext ( ) {
3434 //If we have a slide to transition from and we have a transition type and we're allowed, go
35- if ( self . currentSlide && angular . isString ( direction ) && ! $scope . noTransition && nextSlide . $element ) {
35+ if ( self . currentSlide && angular . isString ( direction ) && ! $scope . noTransition && nextSlide . $element ) {
3636 //We shouldn't do class manip in here, but it's the same weird thing bootstrap does. need to fix sometime
3737 nextSlide . $element . addClass ( direction ) ;
38- nextSlide . $element [ 0 ] . offsetWidth = nextSlide . $element [ 0 ] . offsetWidth ; //force reflow
38+ var reflow = nextSlide . $element [ 0 ] . offsetWidth ; //force reflow
3939
4040 //Set all other slides to stop doing their stuff for the new transition
4141 angular . forEach ( slides , function ( slide ) {
@@ -74,7 +74,7 @@ angular.module('ui.bootstrap.carousel', ['ui.bootstrap.transition'])
7474
7575 $scope . next = function ( ) {
7676 var newIndex = ( currentIndex + 1 ) % slides . length ;
77-
77+
7878 //Prevent this user-triggered transition from occurring if there is already one in progress
7979 if ( ! $scope . $currentTransition ) {
8080 return self . select ( slides [ newIndex ] , 'next' ) ;
@@ -83,7 +83,7 @@ angular.module('ui.bootstrap.carousel', ['ui.bootstrap.transition'])
8383
8484 $scope . prev = function ( ) {
8585 var newIndex = currentIndex - 1 < 0 ? slides . length - 1 : currentIndex - 1 ;
86-
86+
8787 //Prevent this user-triggered transition from occurring if there is already one in progress
8888 if ( ! $scope . $currentTransition ) {
8989 return self . select ( slides [ newIndex ] , 'prev' ) ;
@@ -300,7 +300,7 @@ function CarouselDemoCtrl($scope) {
300300 var lastValue = scope . active = getActive ( scope . $parent ) ;
301301 scope . $watch ( function parentActiveWatch ( ) {
302302 var parentActive = getActive ( scope . $parent ) ;
303-
303+
304304 if ( parentActive !== scope . active ) {
305305 // we are out of sync and need to copy
306306 if ( parentActive !== lastValue ) {
0 commit comments