-
Notifications
You must be signed in to change notification settings - Fork 55
/
index.html
49 lines (49 loc) · 1.06 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
<title>Touch API Test</title>
<style>
body {
position: absolute;
margin: 0;
left: 0;
top: 0;
width: 100%;
height: 100%;
font-family: sans-serif;
font-size: 13px;
padding: 1em;
box-sizing: border-box;
}
h1 {
margin-top: 0;
color: #ccc;
}
canvas {
position: absolute;
width: 100%;
height: 100%;
left: 0;
top: 0;
}
#info {
z-index: 1;
position: absolute;
bottom: 1em;
}
</style>
</head>
<body>
<h1>Demo of Apple Pencil / 3D touch API</h1>
<div id="force"></div>
<div id="touches"></div>
<canvas>Sorry, your browser is too old for this demo.</canvas>
<div id="info">
<a href="https://github.com/quietshu/apple-pencil-safari-api-test" target="_blank">GitHub</a>
<button onclick="undoDraw()">Undo</button>
</div>
<script src="index.js"></script>
</body>
</html>