-
Notifications
You must be signed in to change notification settings - Fork 1
/
spike.html
executable file
·43 lines (32 loc) · 1.07 KB
/
spike.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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
<!DOCTYPE html>
<html>
<head>
<title>Presenter</title>
<script src="javascripts/jquery.min.js" type="text/javascript"></script>
<script src="javascripts/jquery.easing.1.3.js"></script>
</head>
<body style="margin:0;padding:0">
<div id="cont" style="overflow:hidden;background-color: #eee;min-height:100%">
<div id="slide1" class="slide">
hai
</div>
<div id="slide2" style="display:none" class="slide">
<h1>LOL SLIDE 2</h1>
<p>more stuff</p>
</div>
</div>
<script>
max = 0;
$("#cont .slide").each(function() {
if($(this).height() > max)
max = $(this).height()
});
$(".slide").css({ height: max })
$("#cont").css({ position: 'relative', "height": max })
window.setTimeout(function() {
$("#slide1").css({ position: 'absolute' }).animate({top: -200}, 500)
$("#slide2").css({ position: 'absolute', top: 200, display: 'block' }).animate({top: 0}, 500)
}, 1000)
</script>
</body>
</html>