Created
June 25, 2018 07:41
-
-
Save kimroen/d98283f6b7070974cb9f638cfff12e24 to your computer and use it in GitHub Desktop.
Animated Beacon
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Component from '@ember/component'; | |
import move from 'ember-animated/motions/move'; | |
import scale from 'ember-animated-motions/scale'; | |
import { parallel } from 'ember-animated'; | |
export default Component.extend({ | |
showThing: false, | |
transition: function * ({ receivedSprites, sentSprites }) { | |
receivedSprites.forEach(parallel(scale, move)); | |
sentSprites.forEach(parallel(scale, move)); | |
}, | |
actions: { | |
launch() { | |
this.set('showThing', true); | |
}, | |
dismiss() { | |
this.set('showThing', false); | |
} | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle' | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"version": "0.14.1", | |
"EmberENV": { | |
"FEATURES": {} | |
}, | |
"options": { | |
"use_pods": false, | |
"enable-testing": false | |
}, | |
"dependencies": { | |
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.js", | |
"ember": "2.18.2", | |
"ember-template-compiler": "2.18.2", | |
"ember-testing": "2.18.2" | |
}, | |
"addons": { | |
"ember-data": "2.18.2", | |
"ember-animated": "*" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment