From 6818805da05c4b4f0ed55d93d3bfd1af171abe47 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Sat, 20 Nov 2021 00:48:28 +0100 Subject: Fix stats. --- public/style.css | 19 +++++++++++++------ server.js | 2 +- views/about.ejs | 6 ++++-- views/join.ejs | 2 +- 4 files changed, 19 insertions(+), 10 deletions(-) diff --git a/public/style.css b/public/style.css index 89ba3b2..1b9481c 100644 --- a/public/style.css +++ b/public/style.css @@ -47,24 +47,31 @@ table { min-width: min(50rem,100%); } table { border-collapse: collapse; } th { text-align: left; background-color: gainsboro; } th, td { border: 1px solid black; padding: 3px 1ex; } -th a, td:not(.command) a { text-decoration: none; color: black; } +th a:not(:hover), td:not(.command) a:not(:hover) { text-decoration: none; } td.body { white-space: pre-wrap; padding: 10px 10px; } input[type="text"], input[type="password"], textarea { padding: 5px; -} -button, input, select { margin: 5px 0; + border: 1px solid black; } button, select { margin: 5px 10px 5px 0; padding: 1px 10px; background-color: gainsboro; vertical-align: top; + border: 2px outset white; + outline: 1px solid black; +} +button:enabled:active:hover, select:active { + border: 2px inset white; + padding: 2px 9px 0px 11px; +} +button:disabled { + color: gray; + border: 2px solid gainsboro; + outline: 1px solid gray; } -button:disabled { color: gray; border: 2px solid gainsboro; outline: 1px solid gray; } -button:enabled, select { border: 2px outset white; outline: 1px solid black; } -button:enabled:active:hover, select:active { border: 2px inset white; padding: 2px 9px 0px 11px; } td.is_active { background-color: lemonchiffon; } p.error { color: brown; font-style: italic; white-space: pre-wrap; } diff --git a/server.js b/server.js index a531778..ed2ba1c 100644 --- a/server.js +++ b/server.js @@ -1742,7 +1742,7 @@ io.on('connection', (socket) => { const QUERY_STATS = db.prepare(` SELECT title_id, scenario, result, count(*) AS count FROM game_full_view - WHERE status=2 AND private=0 + WHERE status=2 AND is_solo=0 GROUP BY title_name, scenario, result `); diff --git a/views/about.ejs b/views/about.ejs index b934c50..4418d52 100644 --- a/views/about.ejs +++ b/views/about.ejs @@ -1,5 +1,7 @@ -<%- include('header', { title: "Rally the Troops!" }) %> - +<%- include('header', { title: "Rally the Troops!" }) -%> +

Rally the Troops! is created and maintained by Tor Andersson. diff --git a/views/join.ejs b/views/join.ejs index b4e4718..e2c626f 100644 --- a/views/join.ejs +++ b/views/join.ejs @@ -2,7 +2,7 @@ -- cgit v1.2.3