From 94a0b46fb9e2a5148e8aeef8fdd4b80d3c7f0508 Mon Sep 17 00:00:00 2001 From: anti Date: Mon, 27 Apr 2026 10:12:55 -0400 Subject: [PATCH] chore: dashboard layout polish + sqlite_vec dependency MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Dashboard / Layout / index CSS — flexbox cleanup so the sidebar scrolls independently and dashboard panels fill available height without overflowing the viewport (min-height: 0 on the flex ancestors that were collapsing). * pyproject.toml — add sqlite_vec runtime dep (groundwork for an embeddings-backed feature ANTI is wiring up separately). --- decnet_web/src/components/Dashboard.css | 15 +++++++++++++++ decnet_web/src/components/Layout.css | 8 +++++++- decnet_web/src/index.css | 13 +++++++++---- pyproject.toml | 3 ++- 4 files changed, 33 insertions(+), 6 deletions(-) diff --git a/decnet_web/src/components/Dashboard.css b/decnet_web/src/components/Dashboard.css index 8b355c0a..76d744f4 100644 --- a/decnet_web/src/components/Dashboard.css +++ b/decnet_web/src/components/Dashboard.css @@ -2,6 +2,7 @@ display: flex; flex-direction: column; gap: 24px; + min-height: 100%; } /* Page header */ @@ -219,6 +220,7 @@ border: 1px solid var(--border-color); display: flex; flex-direction: column; + min-height: 0; } .section-header { @@ -258,12 +260,24 @@ display: grid; grid-template-columns: 2fr 1fr; gap: 16px; + flex: 1; + min-height: 0; +} + +.dash-grid > .logs-section .logs-table-container { + flex: 1; + max-height: none; } .dash-side { display: flex; flex-direction: column; gap: 16px; + min-height: 0; +} + +.dash-side > .logs-section { + flex: 1; } /* Attacker/siege rows */ @@ -363,6 +377,7 @@ overflow-x: auto; overflow-y: auto; max-height: 420px; + min-height: 0; } .logs-table { diff --git a/decnet_web/src/components/Layout.css b/decnet_web/src/components/Layout.css index 2ab89a85..8b383814 100644 --- a/decnet_web/src/components/Layout.css +++ b/decnet_web/src/components/Layout.css @@ -56,10 +56,16 @@ } .sidebar-nav { - flex-grow: 1; + flex: 1 1 0; + min-height: 0; + overflow-y: auto; padding: 20px 0; } +.sidebar-footer { + flex-shrink: 0; +} + .nav-item { display: flex; align-items: center; diff --git a/decnet_web/src/index.css b/decnet_web/src/index.css index 84ddf449..a8e53f63 100644 --- a/decnet_web/src/index.css +++ b/decnet_web/src/index.css @@ -211,7 +211,12 @@ input:focus { } /* ── Scrollbar ─────────────────────────────────── */ -::-webkit-scrollbar { width: 8px; height: 8px; } -::-webkit-scrollbar-track { background: var(--bg); } -::-webkit-scrollbar-thumb { background: var(--panel); border: 1px solid var(--border); } -::-webkit-scrollbar-thumb:hover { background: var(--border); } +* { + scrollbar-width: thin; + scrollbar-color: var(--accent) transparent; +} +::-webkit-scrollbar { width: 4px; height: 4px; } +::-webkit-scrollbar-track { background: transparent; } +::-webkit-scrollbar-thumb { background: var(--accent); border: none; border-radius: 2px; opacity: 0.6; } +::-webkit-scrollbar-thumb:hover { background: var(--accent); opacity: 1; } +::-webkit-scrollbar-corner { background: transparent; } diff --git a/pyproject.toml b/pyproject.toml index 5275c8af..c62ebbd2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -38,7 +38,8 @@ dependencies = [ "python-multipart>=0.0.20", "httpx>=0.28.1", "requests>=2.33.1", - "slowapi>=0.1.9" + "slowapi>=0.1.9", + "sqlite_vec>=0.1.9" ] [project.optional-dependencies]