From 6fec58ef80d6ebdc313b3aa206cd466b1861f898 Mon Sep 17 00:00:00 2001 From: Florian Schroedl Date: Thu, 19 Mar 2026 14:14:15 +0100 Subject: [PATCH] refactor: move scrollbar styles to global utilities Apply thin subtle scrollbars globally via utilities.css instead of only on .sidebar-content. Uses scrollbar-width/scrollbar-color for Firefox and ::-webkit-scrollbar for Chrome/Safari. Removes the now-redundant sidebar-specific scrollbar rules. --- src/ui/sidebar.css | 14 -------------- src/ui/utilities.css | 26 ++++++++++++++++++++++++++ 2 files changed, 26 insertions(+), 14 deletions(-) diff --git a/src/ui/sidebar.css b/src/ui/sidebar.css index 24473c2..cd87341 100644 --- a/src/ui/sidebar.css +++ b/src/ui/sidebar.css @@ -150,20 +150,6 @@ min-width: 0; } -/* Scrollbar styling */ -.sidebar-content::-webkit-scrollbar { - width: 4px; -} - -.sidebar-content::-webkit-scrollbar-track { - background: transparent; -} - -.sidebar-content::-webkit-scrollbar-thumb { - background: var(--bg-2); - border-radius: 9999px; -} - /* ── Sidebar Group ─────────────────────────────────────────────── */ .sidebar-group { diff --git a/src/ui/utilities.css b/src/ui/utilities.css index e445ba3..952ecce 100644 --- a/src/ui/utilities.css +++ b/src/ui/utilities.css @@ -62,3 +62,29 @@ white-space: nowrap; border: 0; } + +/* ── Scrollbars ────────────────────────────────────────────────── */ +/* Thin, subtle scrollbars everywhere. */ + +* { + scrollbar-width: thin; + scrollbar-color: var(--bg-2) transparent; +} + +::-webkit-scrollbar { + width: 4px; + height: 4px; +} + +::-webkit-scrollbar-track { + background: transparent; +} + +::-webkit-scrollbar-thumb { + background: var(--bg-2); + border-radius: 9999px; +} + +::-webkit-scrollbar-thumb:hover { + background: var(--fg-2); +}