-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
98 lines (83 loc) · 3.89 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Basic Page Needs
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<meta charset="utf-8">
<title>Cloak panel</title>
<!-- Templates -->
<script id="info-panel-template" type="text/x-handlebars-template">
<div class="info-panel" id="info-panel-{{UID}}">
<h5>{{UID}}</h5>
<div class="body">
Sessions cap: {{SessionsCap}}<br>
Upload bandwidth: {{UpRate}} bytes/s<br>
Download bandwidth: {{DownRate}} bytes/s<br>
Upload credit: {{UpCredit}} bytes<br>
Download credit: {{DownCredit}} bytes<br>
User expiry: {{ExpiryTime}}<br>
</div>
<input type="button" class="button delete" value="delete" onclick="deleteUser('{{UID}}')">
</div>
</script>
<script id="info-panel-add-button-template" type="text/x-handlebars-template">
<div class="info-panel add-button-panel" onclick="showAddUser()">
+
</div>
</script>
<script id="info-panel-add-user-template" type="text/x-handlebars-template">
<div class="info-panel add-user-panel">
<input class="u-full-width" id="UIDInput" placeholder="UID">
<input class="u-full-width" id="SessionsCapInput" placeholder="Sessions cap">
<input class="u-full-width" id="UpRateInput" placeholder="Upload bandwidth (MiBytes/s)">
<input class="u-full-width" id="DownRateInput" placeholder="Download bandwidth (MiBytes/s)">
<input class="u-full-width" id="UpCreditInput" placeholder="Upload credit (MiB)">
<input class="u-full-width" id="DownCreditInput" placeholder="Download credit (MiB)">
<input class="u-full-width" id="ExpiryTimeInput" placeholder="User expiry (Unix timestamp)">
<input class="button-primary" type="submit" value="Add" onclick="addUser()">
</div>
</script>
<script src="script/handlebars.js"></script>
<script src="script/endpoint.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<!-- Mobile Specific Metas
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- FONT
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<link href="https://fonts.googleapis.com/css?family=Ubuntu:400,500&display=swap" rel="stylesheet">
<!-- CSS
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<link rel="stylesheet" href="css/custom.css">
<link rel="stylesheet" href="css/normalize.css">
<link rel="stylesheet" href="css/skeleton.css">
</head>
<body>
<!-- Primary Page Layout
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
<div class="container">
<div class="row">
<div class="column" style="margin-top: 10%">
<h4>Cloak Server Control Panel</h4>
</div>
</div>
<div class="row">
<label for="baseUrl">API Base</label>
</div>
<div class="row">
<div class="nine columns">
<input class="u-full-width" type="url" value="127.0.0.1:8080" id="baseUrl">
</div>
<div class="three columns">
<input type="button" value="List" onclick="listAllUsers()">
</div>
</div>
<div class="column">
<div class="flex-container">
</div>
</div>
</div>
<!-- End Document
–––––––––––––––––––––––––––––––––––––––––––––––––– -->
</body>
</html>