Advertisement
Guest User

Untitled

a guest
Apr 19th, 2015
190
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. import Ember from 'ember';
  2.  
  3. export default Ember.Component.extend({
  4. classNames: ['modal'],
  5.  
  6. didInsertElement: function() {
  7. var self = this.$();
  8. Ember.run.later(function() {
  9. self.toggleClass('open');
  10. });
  11. },
  12.  
  13. actions: {
  14. close: function() {
  15. debugger;
  16. var self = this.$();
  17. self.toggleClass('open');
  18. Ember.run.later(this, function() {
  19. this.send('dismissModal');
  20. }, 300);
  21. }
  22. }
  23. });
  24.  
  25.  
  26. {{#modal-window}}
  27. <div class="header">Welcome</div>
  28.  
  29. <div class="body modal-welcome">
  30. <p>Hammer time is a timer for for your github projects.</p>
  31. <p>
  32. Please log in with GitHub to continue. A popup will open.
  33. You may need to allow the popup and click the button again.
  34. </p>
  35. <button class="gh-login-btn" {{action 'close'}}>Login With Github</button>
  36. </div>
  37. {{/modal-window}}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement