From a3b2bef5c1af838ccc5a4ba128a41835b94993c9 Mon Sep 17 00:00:00 2001 From: PaulVua Date: Wed, 7 Jan 2026 14:48:34 +0100 Subject: [PATCH] Improve database page layout and highlight most recent data MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Layout improvements: - Reorganized cards to fit 3 across on large screens (col-lg-4) - View database, download data, and danger zone now on same row - Added h-100 class to cards for equal height - Made delete button larger and full-width for better visibility Button spacing: - Added mb-2 (margin-bottom) to all measurement trigger buttons - Improved vertical spacing for better readability Data visualization: - Added light green background (#d4edda) to first table row - First row now highlights the most recent data entry - Makes it easy to see the latest sensor reading at a glance 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 --- html/database.html | 61 +++++++++++++++++++++++----------------------- 1 file changed, 30 insertions(+), 31 deletions(-) diff --git a/html/database.html b/html/database.html index 8b56031..1de359e 100755 --- a/html/database.html +++ b/html/database.html @@ -26,6 +26,10 @@ .offcanvas-backdrop { z-index: 1040; } + /* Highlight most recent data row with light green background */ + .most-recent-row { + background-color: #d4edda !important; + } @@ -54,8 +58,8 @@
-
-
+
+
Consulter la base de donnée
@@ -67,23 +71,20 @@
- - - - - - - - - - - + + + + + + + +
-
-
+
+
Télécharger les données
@@ -94,32 +95,28 @@
- - - - - - - - - - + + + + + +
-
-
+
+
Zone dangereuse

Attention: Cette action est irréversible!

- + Note: Les tables de configuration et horodatage seront préservées.
-
+
@@ -346,9 +343,11 @@ function get_data_sqlite(table, limit, download , startDate = "", endDate = "") tableHTML += ``; // Loop through rows and create table rows - rows.forEach(row => { + rows.forEach((row, index) => { let columns = row.replace(/[()]/g, "").split(", "); // Remove parentheses and split - tableHTML += ""; + // Add special class to first row (most recent data) + const rowClass = index === 0 ? ' class="most-recent-row"' : ''; + tableHTML += ``; if (table === "data_NPM") { tableHTML += `