aboutsummaryrefslogtreecommitdiff
path: root/views/stats.pug
diff options
context:
space:
mode:
authormehekj <mehek.jethani@gmail.com>2023-04-19 22:25:36 -0400
committermehekj <mehek.jethani@gmail.com>2023-04-19 22:25:36 -0400
commite80fda22e5c244bc6039f851bc84656afdd601cb (patch)
tree7665ae0ebd8e85e5b18da7d4369e40d680ef5c4f /views/stats.pug
parent8c5e898b89a6634f54a3961ba3693948c7d991d6 (diff)
parent0a66b0f369a13d5f399bf125727aff73cd6fd1b4 (diff)
Merge branch 'master' into schema-mehek
Diffstat (limited to 'views/stats.pug')
-rw-r--r--views/stats.pug30
1 files changed, 30 insertions, 0 deletions
diff --git a/views/stats.pug b/views/stats.pug
new file mode 100644
index 000000000..16c28087e
--- /dev/null
+++ b/views/stats.pug
@@ -0,0 +1,30 @@
+extends ./layout
+
+//- stats.pug is the frontend for the stats page
+block content
+ style
+ include ./stylesheets/authentication.css
+ include ./stylesheets/statsview.css
+ script(src=`http://localhost:4321/socket.io/socket.io.js`)
+ script
+ include ./resources/statsviewcontroller.js
+ script.
+ var socket = io.connect("http://localhost:4321");
+ socket.on("connect", () => console.log("connected to socket"));
+
+ socket.on("a2cf757f-abd7-537b-953e-ef2f4f798f7e", (data) => handleStatsUpdate(data));
+ .outermost
+ .stats-container
+ h1 Dash Stats
+
+ p(class="stats-content" id="connection-count") Current Connections: #{numConnections}
+ div(class="stats-content stats-server-status-container")
+ p Server Status:
+ div(id="stats-traffic-message" class="stats-server-status-item stats-server-status-" + serverTraffic)
+ p #{serverTrafficMessage}
+ div(class="stats-content stats-connected-users")
+ p Connected Users:
+ ul(id="connected-user-list")
+
+
+ \ No newline at end of file