-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexample.html
More file actions
42 lines (42 loc) · 1.31 KB
/
example.html
File metadata and controls
42 lines (42 loc) · 1.31 KB
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
<link rel="stylesheet" href="./dist/tp.style.css">
</head>
<body>
<section style="text-align:center">
<h1>Lorem ipsum dolor sit amet consectetur adipisicing elit. Et temporibus, hic consectetur quisquam accusantium nobis tenetur voluptates fugiat sunt laborum consequuntur, reprehenderit animi officia aut est cumque natus magni nisi.</h1>
</section>
<section style="text-align:center">
<button onclick="start()">start</button>
<button onclick="goto(10)">add 10</button>
<button onclick="goto(90)">add 10</button>
<button onclick="done()">done</button>
<button onclick="stop()">stop</button>
</section>
<script src="./dist/tp.js"></script>
<script>
const bar = new TP({
mount: 'body',
width: '2px',
color: ''
});
function start () {
bar.start();
}
function stop () {
bar.stop();
}
function goto(x) {
bar.goto(x);
}
function done () {
bar.done();
}
</script>
</body>
</html>