forked from xoxco/Rainbow-Text
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexample.html
27 lines (18 loc) · 1.05 KB
/
example.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js"></script>
<script src="http://xoxco.com/projects/code/rainbow/rainbow.js"></script>
<script>
$(function() {
$('#foo').rainbow({animate:true,animateInterval:100,colors:['#FF0000','#f26522','#fff200','#00a651','#28abe2','#2e3192','#6868ff']});
$('#bar').rainbow({animate:true,animateInterval:50,pauseLength:500,pad:true,colors:['rgb(153, 204, 255);','rgb(173, 224, 255);','rgb(193, 244, 255);','rgb(213, 264, 255);','rgb(193, 244, 255);','rgb(173, 224, 255);','rgb(153, 204, 255);']});
$('#baz').rainbow({animate:true,animateInterval:10,colors:['#FF0000','#f26522','#fff200','#00a651','#28abe2','#2e3192','#6868ff']});
});
</script>
<style>
h1 { font-size: 60px;}
</style>
<h3>Demo</h3>
<h1 id="foo">RAINBOW!!!</h1>
<h1 id="bar">METALLIC SHINY!!</h1>
<h1 id="baz">TEXT!!!!!</h1>
<p><a href="#" onclick="$('h1').pauseRainbow();">Pause Animation</a></p>
<p><a href="#" onclick="$('h1').resumeRainbow();">Resume Animation</a></p>