js/components/carousel.js
function(start) {
        var itemsToShow = this.options.itemsToShow,
            length = this.items.length,
            stop = start + itemsToShow,
            set = $([]),
            tabs = this.tabs
                .removeClass('is-active')
                .aria('toggled', false);

        if (!tabs.length) {
            return;
        }

        if (this.options.infinite) {
            length = length - (itemsToShow * 2);
        }

        if (start >= 0) {
            set = set.add(tabs.slice(start, stop));
        } else {
            set = set.add(tabs.slice(0, stop));
            set = set.add(tabs.slice(start));
        }

        if (stop > length) {
            set = set.add(tabs.slice(0, stop - length));
        }

        set
            .addClass('is-active')
            .aria('toggled', true);
    }
function(start) {
        var itemsToShow = this.options.itemsToShow,
            length = this.items.length,
            stop = start + itemsToShow,
            set = $([]),
            tabs = this.tabs
                .removeClass('is-active')
                .aria('toggled', false);

        if (!tabs.length) {
            return;
        }

        if (this.options.infinite) {
            length = length - (itemsToShow * 2);
        }

        if (start >= 0) {
            set = set.add(tabs.slice(start, stop));
        } else {
            set = set.add(tabs.slice(0, stop));
            set = set.add(tabs.slice(start));
        }

        if (stop > length) {
            set = set.add(tabs.slice(0, stop - length));
        }

        set
            .addClass('is-active')
            .aria('toggled', true);
    }
function ( start ) { var itemsToShow = this . options . itemsToShow , length = this . items . length , stop = start + itemsToShow , set = $ ( [ ] ) , tabs = this . tabs . removeClass ( 'is-active' ) . aria ( 'toggled' , false ) ; if ( ! tabs . length ) { return ; } if ( this . options . infinite ) { length = length - ( itemsToShow * 2 ) ; } if ( start >= 0 ) { set = set . add ( tabs . slice ( start , stop ) ) ; } else { set = set . add ( tabs . slice ( 0 , stop ) ) ; set = set . add ( tabs . slice ( start ) ) ; } if ( stop > length ) { set = set . add ( tabs . slice ( 0 , stop - length ) ) ; } set . addClass ( 'is-active' ) . aria ( 'toggled' , true ) ; }
Update the active state for the tab indicators.

@param {Number} start
@private
Update the active state for the tab indicators .