import uuid from 'uuid/v4';

export default class wsCarouselSlideController {
  $onInit = () => {
    this.uuid = uuid();
  }

  $postLink = () => {
    this.carouselCtrl.onSlideAdded(this.uuid);
  }

  $onDestroy = () => {
    this.carouselCtrl.onSlideRemoved(this.uuid);
  }

  getSlideClass = () => this.carouselCtrl.getSlideClass(this.uuid);
  amIActive = () => this.carouselCtrl.isSlideActive(this.uuid);
}
