Skip to content

fix(ui): stop tour button overlapping status pill + add theme switcher#22

Open
psigho wants to merge 1 commit into
elder-plinius:mainfrom
psigho:fix/ui-theme-switcher
Open

fix(ui): stop tour button overlapping status pill + add theme switcher#22
psigho wants to merge 1 commit into
elder-plinius:mainfrom
psigho:fix/ui-theme-switcher

Conversation

@psigho

@psigho psigho commented Jul 5, 2026

Copy link
Copy Markdown

What

Two small War Room UI fixes, both in docs/index.html.

1. Guided-tour button overlapping the status pill

The floating "guided tour" relaunch button (#t3mpTourRelaunch) is position: fixed pinned bottom-left (left: 18px), which lands directly on top of the sidebar's "Connected" status pill and hides its first character (it renders as a green "?" over onnected). Moved it to bottom-right — the conventional help-FAB corner, where it collides with nothing.

2. Theme switcher

Added a THEME swatch row in the sidebar footer with four themes:

Theme Accent
Storm (default) teal/green — the existing look, visually unchanged
Ember amber
Crimson red
Void violet

The choice persists in localStorage (t3mp3st_theme) and is applied by a tiny <head> script before first paint, so there's no flash of the default theme on reload.

How

The dominant "hacker green" (#00ff88) was hardcoded ~300× and tied to no variable, so a naive theme only recolored the logo. To make themes reskin the whole UI, the brand colors (#00ff88 / #2fffd2 / #00d4ff and their rgba() forms) were converted to CSS variables — only inside <style> and inline style="..." attributes, where var() is valid.

Deliberately left as literals:

  • Bare JS string literals (e.g. el.style.color = '#00ff88', color maps, color === '#00ff88' comparisons) — many are semantic status colors (green = ready, red = error) that should stay fixed, and some feed color-comparison logic.
  • 2 SVG fill= presentation attributesvar() is invalid there.

Storm keeps its original two-tone green/teal identity via :root; the alternates retint --brand / --accent / --cyan (plus -rgb triplets for the rgba() usages) from a single data-theme attribute on <html>.

Verification

  • All four themes resolve their variables; default Storm is pixel-unchanged.
  • Overlap fix holds in every theme (tour button and status pill no longer intersect).
  • No JS logic changed — the page renders and every script runs unchanged; no console errors.
  • Scoped to one file (docs/index.html).

Known cosmetic leftovers (intentional)

  • The top-right ENGAGE button and a few status dots stay green (bare-JS semantic colors).
  • The Crimson HUNT button gradient has one unmapped stop (#00aa66), so it's briefly two-tone.

Both are safe to leave; happy to chase 100% coverage if wanted.

Two War Room UI fixes (docs/index.html):

1. The floating "guided tour" relaunch button (#t3mpTourRelaunch) was
   position:fixed pinned bottom-left, landing on top of the sidebar
   "Connected" status pill and hiding its first character. Moved it to
   bottom-right (the conventional help-FAB corner) so it collides with
   nothing.

2. Added a theme switcher in the sidebar footer with four themes: Storm
   (the existing teal/green default, visually unchanged), Ember (amber),
   Crimson (red), and Void (violet). The choice persists in localStorage
   and is applied before first paint to avoid a flash of the default theme.

   To make themes reskin the whole UI rather than only the ~87 var(--accent)
   sites, the dominant hardcoded brand colors (#00ff88 / #2fffd2 / #00d4ff
   and their rgba() forms) were converted to CSS variables -- but only
   inside <style> and inline style="..." attributes, where var() is valid.
   Bare JS string literals and SVG fill= attributes are left as-is; most are
   semantic status colors (green=ready, red=error) that should stay fixed.

No JS logic changed; the page renders and all scripts run unchanged.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@psigho psigho force-pushed the fix/ui-theme-switcher branch from f72976e to c6253a9 Compare July 8, 2026 14:32
@jmagly

jmagly commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Reviewed — sound. The tour-button fix (left:18pxright:18px, moving it off the status pill) is correct and minimal, and the theme switcher is well-built: pre-paint no-flash script, idempotent build guard, aria-labels, unique ids, and alt themes only re-tint the accent family so danger/warning semantics stay put. The ~130 scattered hunks are genuine #hexvar() theming substitutions (semantically identical in the default theme), not reformatting churn.

Two cosmetic nits, non-blocking: a few var(--x, var(--x)) self-referential fallbacks fell out of the literal replacement (harmless since the var is always defined in :root), and some inline onmouseover handlers still hardcode green so they briefly flash under Ember/Crimson/Void. Also note it appends its <script> right before </body> — the same anchor #59 uses — so whichever of #22/#59 lands second needs a trivial rebase (keep both blocks). Merge.

@jmagly

jmagly commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Please rebase this branch onto current main and resubmit it as a UI-only theme/tour fix.

The UI change is not reviewable in the current branch because it also carries unrelated stale-base removals around Gemini/provider config and tests.

Suggested agent repair path:

  1. Recreate/rebase from current main.
  2. Reapply only the docs/index.html theme/tour changes.
  3. Do not touch provider config, Gemini support, env templates, or unrelated tests.
  4. Run a static parse check for extracted page scripts.
  5. Confirm git diff --name-status upstream/main...HEAD is limited to the UI file(s).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants