-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
50 lines (49 loc) · 1.29 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
<!DOCTYPE html>
<html>
<head>
<script src="components/platform/platform.js"></script>
<link rel="import" href="elements/pl-push-node.html">
<link rel="import" href="elements/pl-html-visualizer.html">
<style>
#visBox {
width: 1000px;
height: 1000px;
overflow: hidden;
background-color: #EFE;
-webkit-user-select: none;
}
#visBox pl-html-visualizer {
width: 100px;
height: 50px;
font-size: 10px;
}
</style>
</head>
<body>
<div id='visBox'>
<pl-html-visualizer name="timer">
<pl-timer period='1000'></pl-timer>
</pl-html-visualizer>
<pl-html-visualizer name='passthrough' x='150' y='30'>
<pl-passthrough></pl-passthrough>
</pl-html-visualizer>
<pl-html-visualizer name='timer2' x='150' y='90'>
<pl-timer id='t2' period='500'></pl-timer>
</pl-html-visualizer>
<pl-html-visualizer x='300' y='60'>
<pl-adder></pl-adder>
</pl-html-visualizer>
</div>
</body>
<script>
var passthrough = document.querySelector('pl-passthrough');
var timer = document.querySelector('pl-timer');
var timer2 = document.querySelector('#t2');
var adder = document.querySelector('pl-adder');
adder.addEventListener('ready', function() {
passthrough.in = timer.time;
adder.a = passthrough.out;
adder.b = timer2.time;
});
</script>
</html>