-
Notifications
You must be signed in to change notification settings - Fork 9
/
demo.html
46 lines (40 loc) · 918 Bytes
/
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
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Avatar Uploader</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<link rel="stylesheet" href="avatar.css">
<style>
.avatar-upload {
width: 200px;
height: 200px;
border-radius: 160px;
overflow: hidden;
}
.avatar-upload img {
max-width: 200px;
max-height: 200px;
}
</style>
</head>
<body>
<div class="avatar-upload">
<img src="placekitten.jpg">
</div>
<p><em>Click image to replace.</em></p>
<p><a href="http://github.com/danharper/avatar-uploader">Grab the Source!</a> by <a href="http://danharper.me">Dan Harper</a>.</p>
<script src="avatar.js"></script>
<script>
new window.AvatarUpload({
el: document.querySelector('.avatar-upload'),
uploadUrl: '',
uploadData: {
foo: 'bar',
bar: 'baz'
},
pretendUpload: true
})
</script>
</body>
</html>