lundi 6 juin 2016

ember liquid-teather transitions.js

I am using ember liquid-teather - http://ift.tt/1VICl58

The code I have used is from the example under 'Animation With Context'.

The modal works, but there is no nice transitions as am getting an error in the console re the transitions.js file.

See my transitions code below:

export default function(){
  this.transition(
    target('modal-dialog'),
    this.toValue(({ index: newIndex }, { index: oldIndex }) => newIndex > oldIndex),
    this.use('tether', ['to-left', options]),
    this.reverse('tether', ['to-right', options])
  );

  this.transition(
    target('modal-dialog'),
    this.toValue(({ index }) => index === 1),
    this.use('tether', 'fade', 'fade')
  );

  this.transition(
    target('modal-dialog'),
    this.toValue(({ index }) => !index),
    this.use('tether', 'fade', 'fade')
  );
}

The error is: target not defined.

How do I define target?

Thank you in advance! :-)




Aucun commentaire:

Enregistrer un commentaire