Last active
August 29, 2015 14:22
-
-
Save adg29/1e7460829be46be22035 to your computer and use it in GitHub Desktop.
vivus.js SVG animation from file
This file contains hidden or 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> | |
<meta charset="utf-8"> | |
<title> | |
vivus.js SVG animation from file | |
</title> | |
<style> | |
body { | |
color: #eee; | |
background-color: #2d1b27; | |
} | |
#viv-container { | |
width: 25%; | |
margin: auto; | |
} | |
p { | |
font-family: "Avenir", "Gill Sans", "Futura", "Helvetica Neue", sans-serif; | |
font-size: 1.5em; | |
font-weight: 100; | |
margin: 0; | |
padding: 0; | |
} | |
blockquote { | |
text-align: center; | |
} | |
</style> | |
<script src="http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script> | |
<script src="http://rawgit.com/maxwellito/vivus/a2787d1cf76b36f391ccb1a168878e0e2a835678/dist/vivus.js"></script> | |
<script> | |
$(function(){ | |
var viv = new Vivus($('#viv-container')[0], | |
{ | |
type: 'oneByOne' | |
, duration: 100 | |
, file: 'bad-trip.svg' | |
// , file: 'obturateur.svg' | |
// , file: 'left-hands.svg' | |
// , file: 'http://rawgit.com/adg29/1e7460829be46be22035/raw/494de785a8083c074971c0ea336cf8b1fb5b7201/left-hands.svg' | |
// , file: 'http://rawgit.com/adg29/1e7460829be46be22035/raw/688bf2471f000fcef239061266c4ae01776b803b/obturateur.svg' | |
}); | |
}); | |
</script> | |
<body> | |
<div id="viv-container"></div> | |
</body> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment