This commit is contained in:
Max Lynch
2015-08-31 15:58:49 -05:00
parent dc27c46b81
commit b2cc8e7a19

View File

@ -54,8 +54,6 @@ export class Slides extends Ion {
super(elementRef, config);
}
onInit() {
//this.getNativeElement().classList.add('swiper-container');
var options = util.defaults({
pagination: '.swiper-pagination',
paginationClickable: true,
@ -64,11 +62,13 @@ export class Slides extends Ion {
var swiper = new Swiper(this.getNativeElement().children[0], options);
console.log('Build swiper', swiper, options);
this.swiper = swiper;
}
/**
* Update the underlying slider implementation. Call this if you've added or removed
* child slides.
*/
update() {
setTimeout(() => {
this.swiper.update();
@ -96,12 +96,10 @@ export class Slide {
* @param {ElementRef} elementRef TODO
*/
constructor(
//@Host() slides: Slides,
elementRef: ElementRef
) {
this.ele = elementRef.nativeElement;
this.ele.classList.add('swiper-slide');
//slides.add(this);
}
}