'use strict';

(function () {

  var step1 = document.getElementById('step1'),
  step3 = document.getElementById('step3'),
  end = step3.querySelector('#end-conversion'),
  undo = step3.querySelector('#undo-conversion'),
  close = new BusinessEvent('app.close');

  end.addEventListener('click', function (e) {
    e.preventDefault();
    //window.close();
    close.trigger();
    Animation.currentToRight(step3, step3, step1);
  });

  undo.addEventListener('click', function (e) {
    Animation.currentToLeft(step3, step3, step3.nextElementSibling);
  });
}());
