Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

sergioramos/carousel

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

deprecated

carousel

image carousel demo

installation

for component:

$ component install ramitos/carousel

usage

var carousel = require('carousel');
var cats = carousel(document.getElementById('carousel-container'));

setInterval(function () {
  var height = Math.floor(Math.random() * 500) + 100;
  var width = Math.floor(Math.random() * 500) + 100;
  var url = "http://placekitten.com/g/" + width + "/" + height;
  carousel.add(url);
}, 1000)

api

void add(url: string)

add an image url to the carousel

number image()

retrieve the selected image position

void disable()

disable all carousel controls

void enable()

enable all carousel controls

license

MIT