forked from jmico/beekeeper
-
Notifications
You must be signed in to change notification settings - Fork 0
/
client.html
68 lines (60 loc) · 1.62 KB
/
client.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
<!DOCTYPE HTML>
<html>
<head>
<title>JSON-RPC over MQTT example</title>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<script language="Javascript" type="text/javascript" defer src="https://unpkg.com/[email protected]/dist/mqtt.min.js"></script>
<script language="Javascript" type="text/javascript" defer src="js/config.js"></script>
<script language="Javascript" type="text/javascript" defer src="js/beekeeper.js"></script>
<script language="Javascript" type="text/javascript" defer src="js/calculator.js"></script>
<style type="text/css">
body {
padding: 40px;
font-size: 11pt;
font-family: sans-serif;
}
#expr {
font-size: 14pt; font-family: sans-serif;
width: 380px;
color: #000000;
padding: 6px;
padding-left: 12px;
margin: 6px;
border: solid 2px #6699CC;
border-radius: 6px;
}
#send {
font-size: 12pt; font-family: sans-serif;
width: 80px;
color: #000000;
padding: 6px;
margin: 6px;
border: solid 2px #6699CC;
background-color: #6699CC;
border-radius: 6px;
}
#result {
font-size: 16pt; font-family: sans-serif;
width: 470px;
min-height: 28px;
margin: 6px;
padding: 12px;
border: solid 1px #6699CC;
border-radius: 6px;
}
.result.success {
background-color: #A0FFA0;
}
.result.error {
background-color: #FFA0A0;
}
</style>
</head>
<body>
<input type="text" id="expr" value="2 + 2" />
<input type="button" id="send" value=" = " onclick="Calc.eval_expr()" />
<div id="result"></div>
<p> JSON-RPC traffic is being dumped to console.</br />
"Server error" means that the remote method died.</p>
</body>
</html>