Last active
December 14, 2016 00:17
-
-
Save Vheissu/43a18d196635de1211f2940814416bde to your computer and use it in GitHub Desktop.
Animation example
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
<template> | |
<require from="./styles.css"></require> | |
<div class="my-cool-element"> | |
<div class="au-animate"> | |
<h1>My element animates</h1> | |
</div> | |
</div> | |
</template> |
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
export class App { | |
} |
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
<!doctype html> | |
<html> | |
<head> | |
<title>Aurelia</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
</head> | |
<body aurelia-app="main"> | |
<h1>Loading...</h1> | |
<script src="https://jdanyow.github.io/rjs-bundle/node_modules/requirejs/require.js"></script> | |
<script src="https://jdanyow.github.io/rjs-bundle/config.js"></script> | |
<script src="https://jdanyow.github.io/rjs-bundle/bundles/aurelia.js"></script> | |
<script src="https://jdanyow.github.io/rjs-bundle/bundles/babel.js"></script> | |
<script> | |
require(['aurelia-bootstrapper']); | |
</script> | |
</body> | |
</html> |
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
export function configure(aurelia) { | |
aurelia.use.basicConfiguration(); | |
aurelia.start().then(() => aurelia.setRoot()); | |
} |
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
.my-cool-element > .au-enter { | |
opacity: 0 !important; | |
} | |
.my-cool-element > .au-enter-active { | |
-webkit-animation: fadeIn 2s; | |
animation: fadeIn 2s; | |
} | |
.my-cool-element > .au-leave-active { | |
-webkit-animation: fadeOut 2s; | |
animation: fadeOut 2s; | |
} | |
@-webkit-keyframes fadeIn { | |
0% { opacity: 0; } | |
100% { opacity: 1; } | |
} | |
@keyframes fadeIn { | |
0% { opacity: 0; } | |
100% { opacity: 1; } | |
} | |
@-webkit-keyframes fadeOut { | |
0% { opacity: 1; } | |
100% { opacity: 0; } | |
} | |
@keyframes fadeOut { | |
0% { opacity: 1; } | |
100% { opacity: 0; } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment