-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathindex.html
90 lines (83 loc) · 2.49 KB
/
index.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
<!DOCTYPE html>
<html>
<head>
<title>simple-gallery grid-layout example</title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script src="../../jqueryui-widget.min.js"></script>
<script src="../../simple-gallery.min.js"></script>
<style>
#images {
float:left;
margin-right:10px;
}
#images img {
width:150px;
padding:5px;
}
#full {
float:left;
width:470px;
height:333px;
}
.selected {
background-color:gray;
}
#caption {
clear:left;
}
</style>
</head>
<body>
<div id="images">
<div class="row">
<img src="../images/img1.jpg" title="image 1" />
<img src="../images/img2.jpg" title="image 2" />
<img src="../images/img3.jpg" title="image 3" />
</div>
<div class="row">
<img src="../images/img4.jpg" title="image 4" />
<img src="../images/img5.jpg" title="image 5" />
<img src="../images/img6.jpg" title="image 6" />
</div>
<div class="row">
<img src="../images/img7.jpg" title="image 7" />
<img src="../images/img8.jpg" title="image 8" />
<img src="../images/img9.jpg" title="image 9" />
</div>
</div>
<div id="full"></div>
<p id="caption"></p>
<script>
$('#full').gallery({
source: "#images img",
easing: "linear",
waitTime: 2000,
changeTime: 400,
showCaptions: true,
captionTarget: "#caption"
});
$("#full").on({
mouseenter: function() {
$("#full").gallery("stopAnimation");
},
mouseleave: function() {
$("#full").gallery("resumeAnimation");
}
});
$("#full").on({
galleryimageload: function() {
console.log("new image loaded");
},
galleryclick: function() {
console.log("gallery source image clicked");
},
galleryanimationstop: function() {
console.log("gallery animation stopped");
},
galleryanimationresume: function() {
console.log("gallery animation resumed");
}
});
</script>
</body>
</html>