From b1a5586c2546b17d53ff00a2125d86e3fdfe609c Mon Sep 17 00:00:00 2001 From: Falkan Date: Wed, 18 Mar 2026 19:13:48 -0400 Subject: [PATCH] fix: checkbox alignment, wording, and Dan Mode drag handle contrast --- data/units.json | 16 ++++++++-------- src/routes/admin/+page.svelte | 28 +++++++++++++++++++++++----- 2 files changed, 31 insertions(+), 13 deletions(-) diff --git a/data/units.json b/data/units.json index 4afe3ae..8afa22c 100644 --- a/data/units.json +++ b/data/units.json @@ -1,13 +1,5 @@ { "units": [ - { - "id": "dickload", - "label": "Dickload", - "labelPlural": "Dickloads", - "symbol": "dl", - "group": "dickloads", - "toBase": 1 - }, { "id": "pound", "label": "Pound", @@ -16,6 +8,14 @@ "group": "dickloads", "toBase": 0.038 }, + { + "id": "dickload", + "label": "Dickload", + "labelPlural": "Dickloads", + "symbol": "dl", + "group": "dickloads", + "toBase": 1 + }, { "id": "barrel", "label": "Barrel", diff --git a/src/routes/admin/+page.svelte b/src/routes/admin/+page.svelte index 52d6abf..8094326 100644 --- a/src/routes/admin/+page.svelte +++ b/src/routes/admin/+page.svelte @@ -863,7 +863,7 @@
@@ -912,7 +912,7 @@
@@ -1239,6 +1239,9 @@ width: 1rem; height: 1rem; margin: 0; + /* Pico adds margin-top to checkboxes — override so flex centering works */ + margin-top: 0 !important; + margin-bottom: 0 !important; } .form-msg { padding: 0.5rem 0.75rem; @@ -1300,21 +1303,36 @@ } .drag-handle { cursor: grab; - color: var(--pico-muted-color); + color: var(--pico-color); + opacity: 0.35; font-size: 0.9rem; padding: 0 0.1rem; flex-shrink: 0; user-select: none; line-height: 1; } + .drag-handle:hover { + opacity: 0.7; + } .drag-handle:active { cursor: grabbing; + opacity: 1; } - /* When the row has a primary-colored background, muted grey/orange disappears. - Force the handle to the primary inverse (white in normal themes, black in Dan). */ + /* On selected/drag-over rows the background changes — boost opacity so dots stay visible. */ .tree-unit-row.selected .drag-handle, .tree-unit-row.drag-over-unit .drag-handle { color: var(--pico-primary-inverse); + opacity: 0.6; + } + /* Dan Mode: handle is magenta at full blast; black on yellow selected rows. */ + :global([data-theme=dan]) .drag-handle { + color: #ff00ff; + opacity: 1; + } + :global([data-theme=dan]) .tree-unit-row.selected .drag-handle, + :global([data-theme=dan]) .tree-unit-row.drag-over-unit .drag-handle { + color: #000000; + opacity: 1; } .drag-over-unit { border-top: 2px solid var(--pico-primary);