0

I have already read all the questions about this but stills happening to me. In my html i'm using angular with carousel and my problem is that in the las item, it doesn't cycle anymore. It does work if i click left button but not with the right button. This is my code

<div id="filters-carousel" data-interval="false" class="container-fluid carousel slide issue-div-wrapper" data-ride="carousel">
  <div class="container filters-carousel carousel-inner issue-div" role="listbox" ng-show="filterContent['{{key}}']" ng-repeat="(key, values) in filterContent.filters">
    <ul class="item" ng-class="{active : $index == 0}" ng-repeat="v in values" ng-if="$index % 8 === 0">
      <li ng-repeat="v in values.slice($index, $index + 8)" ng-class="{active: filterContent.isSelectedValue(key, v)}" ng-click="filterContent.addFilter(key, v)">
        <a  class="issue-btn btn-default">{{v}}</a>
      </li>
    </ul>
  </div>
  <!-- Controls -->
  <a class="left carousel-control" href="#filters-carousel" role="button" data-slide="prev">
    <span class="glyphicon glyphicon glyphicon-menu-left" aria-hidden="true"></span>
  </a>
  <a class="right carousel-control" href="#filters-carousel" role="button" data-slide="next">
    <span class="glyphicon glyphicon glyphicon-menu-right" aria-hidden="true"></span>
  </a>
</div>
johnny 5
  • 19,893
  • 50
  • 121
  • 195
Phoenix_uy
  • 3,173
  • 9
  • 53
  • 100

1 Answers1

0

I don't know if mark as duplicate of the following link, are you using ngAnimate?

Take a look at: angularjs corousel stops working

It's a compatibility problem between ui.bootstrap and ngAnimate .... https://github.com/angular-ui/bootstrap/issues/1350

And here too: https://github.com/angular-ui/bootstrap/issues/1565

But someone posted his solution:

app.config(
    ['$animateProvider',
    function ($animateProvider) {
        $animateProvider.classNameFilter(/carousel/);
    }]);

This means ngAnimate is disabled for all elements in the application with the carousel class.

Could be your problem? Hope it helps!

Community
  • 1
  • 1
JP. Aulet
  • 4,375
  • 4
  • 26
  • 39
  • Nothing in their code seems to point to them using ui.bootstrap so this probably isn't the issue. – Matthew Green Apr 11 '16 at 18:38
  • I have added that angular code without luck.. the carousel stills working the same as my problem. I'm using regular bootstrap (i don't know what's ui.bootstrap, i think it's an angular provider?) – Phoenix_uy Apr 11 '16 at 18:49