-
Notifications
You must be signed in to change notification settings - Fork 5
/
demo.html
151 lines (114 loc) · 3.87 KB
/
demo.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
<!doctype html>
<!--[if lt IE 7 ]> <html class="no-js ie6" lang="en"> <![endif]-->
<!--[if IE 7 ]> <html class="no-js ie7" lang="en"> <![endif]-->
<!--[if IE 8 ]> <html class="no-js ie8" lang="en"> <![endif]-->
<!--[if (gte IE 9)|!(IE)]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
<head>
<meta charset="utf-8">
<title>jQuery ViewMaster CSS3 Slideshow - Matthew Lein</title>
<meta name="description" content="">
<meta name="author" content="Matthew Lein">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="css/style.css?v=1">
<link rel="stylesheet" href="viewmaster/viewmaster.css">
<link href="http://fonts.googleapis.com/css?family=Lato:400,400italic" rel="stylesheet" type="text/css" >
<style>
h1, h2 {
font-family: 'Lato';
}
.description {
position: absolute;
top: 20px;
left: 20px;
padding: 15px;
background-color: #FFF;
width: 300px;
z-index: 30;
-webkit-border-radius: 7px;
-moz-border-radius: 7px;
border-radius: 7px;
-webkit-box-shadow: 1px 1px 3px rgba( 0, 0, 0, 0.7 );
-moz-box-shadow: 1px 1px 3px rgba( 0, 0, 0, 0.7 );
-o-box-shadow: 1px 1px 3px rgba( 0, 0, 0, 0.7 );
box-shadow: 1px 1px 3px rgba( 0, 0, 0, 0.7 );
}
.description h1 {
margin: -4px 0 0 0;
font-size: 25px;
}
.description h2 {
margin: 0;
margin-bottom: 10px;
font-size: 15px;
font-style: italic;
color: #555;
}
.description p {
margin: 0;
margin-bottom: 10px;
}
.description a {
text-decoration: none;
color: #2c5797;
}
.description a:hover {
text-decoration: underline;
}
.twitter-share-button {
position: absolute;
right: 18px;
top: 18px;
}
.downloadGithub {
color: #222;
padding-top: 5px;
padding-right: 10px;
padding-bottom: 5px;
padding-left: 10px;
margin: 0 0 10px 0;
display: inline-block;
text-decoration: none;
border:1px solid #C4C4C4;
border-radius: 4px;
-moz-border-radius: 4px;
background: #fcfff4; /* old browsers */
background: -moz-linear-gradient(top, #fcfff4 0%, #dfe5d7 40%, #b3bead 100%); /* firefox */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#fcfff4), color-stop(40%,#dfe5d7), color-stop(100%,#b3bead)); /* webkit */
}
.description .downloadGithub:hover {
text-decoration: none;
}
.downloadGithub:active {
background: -moz-linear-gradient(top, #b3bead 0%, #dfe5d7 40%, #fcfff4 100%); /* firefox */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#b3bead), color-stop(40%,#dfe5d7), color-stop(100%,#fcfff4));
}
</style>
</head>
<body>
<section class="description">
<hgroup>
<h1>jQuery ViewMaster</h1>
<h2>by Matthew Lein</h2>
</hgroup>
<a href="http://twitter.com/share" class="twitter-share-button" data-text="jQuery ViewMaster CSS3 Slideshow - Matthew Lein" data-count="none" data-via="matthewlein">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
<p>This is a slideshow demo I put together to try out some jQuery manipulation of CSS3 rotation and translation. It’s based on the old ViewMaster toy.</p>
<p>Use arrow keys or click any photo.<br>Best viewed in Chrome.</p>
<a href="https://github.com/matthewlein/jQuery-ViewMaster" class="downloadGithub">Download at GitHub</a>
<p>< <a href="http://matthewlein.com/experiments/">More of my experiments</a></p>
</section>
<!-- where I want the viewmaster slideshow -->
<section id="gallery">
</section>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.5.2/jquery.min.js"></script>
<script>window.jQuery || document.write("<script src='js/jquery-1.5.2.min.js'>\x3C/script>")</script>
<script src="viewmaster/jquery.viewmaster.js"></script>
<script>
$(document).ready(function() {
$('#gallery').viewMaster({
source : 'xml/data.xml',
arrows : false // hide arrows
})
});
</script>
</body>
</html>