RsD0p9BK
1/21/2014 - 11:20 AM

rs-carousel.c

  # jquery.rs.carousel
  if $(".rs-carousel").length
    $.when(
      $.getScript "/templates/gantry/js/jquery.ui.widget.js"
      $.getScript "/templates/gantry/js/jquery.rs.carousel.js"
      $.getScript "/templates/gantry/js/jquery.rs.carousel-autoscroll.js"
      $.getScript "/templates/gantry/js/jquery.rs.carousel-continuous.js"
    ).done ->
      $(".rs-carousel").carousel
        autoScroll: true
        continuous: true
        itemsPerTransition: 1
        pagination: false
        pause: 5000
        insertPrevAction: ->
          $("<a href=\"#\" class=\"rs-carousel-action-prev\"></a>").appendTo $(this).parent()

        insertNextAction: ->
          $("<a href=\"#\" class=\"rs-carousel-action-next\"></a>").appendTo $(this).parent()
  # jquery.rs.carousel