From e71cac9dd115a129288596e31dd866154cf3fcdb Mon Sep 17 00:00:00 2001 From: KoalaTrapLord <265133236+KoalaTrapLord@users.noreply.github.com> Date: Fri, 27 Mar 2026 01:57:37 -0400 Subject: [PATCH] =?UTF-8?q?feat(ui):=20add=20tooltips=20to=20all=20pages?= =?UTF-8?q?=20=E2=80=94=20distillation,=20simulator,=20coach,=20deckgenera?= =?UTF-8?q?tor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Move .tip-icon tooltip CSS from training.css into global.css so all pages share it - distillation.html: 8 param tooltips (Max Generations, Convergence Window, Supervised Epochs, Supervised LR, PPO Iterations, PPO Episodes/Iter, PPO LR, Min Win Rate Gate, Opponent, Playstyle) + ELO Ratings header - simulator.html: tooltips on Opponent, Games, Record turn logs, API Endpoint, Model, Temp, Timeout - coach.html: tooltips on Target Power Level, Meta Focus, Budget, Focus Areas, Find Similar Cards Results - deckgenerator.html: tooltips on Target Bracket, Use my collection, Smart Substitution, AI Model --- ui/global.css | 89 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) diff --git a/ui/global.css b/ui/global.css index 3f00b22..79acbab 100644 --- a/ui/global.css +++ b/ui/global.css @@ -864,3 +864,92 @@ body { .form-input:focus, .form-select:focus, .form-textarea:focus { box-shadow: 0 0 0 3px var(--accent-dim), inset 0 1px 3px rgba(0,0,0,0.1); } + + +/* ══════════════════════════════════════════════════════════════ + Tooltip System (.tip-icon + data-tip) + Shared across all pages — do not duplicate in page-specific CSS + ══════════════════════════════════════════════════════════════ */ + +.tip-icon { + display: inline-flex; + align-items: center; + justify-content: center; + width: 15px; + height: 15px; + border-radius: 50%; + background: var(--surface-3); + color: var(--text-secondary); + font-size: 10px; + font-weight: 700; + font-style: normal; + cursor: default; + position: relative; + vertical-align: middle; + margin-left: 4px; + flex-shrink: 0; + transition: background 0.15s, color 0.15s; + user-select: none; +} + +.tip-icon:hover { + background: var(--accent-dim); + color: var(--accent); +} + +.tip-icon::after { + content: attr(data-tip); + position: absolute; + bottom: calc(100% + 8px); + left: 50%; + transform: translateX(-50%); + background: var(--surface-0, #1a1a2e); + color: var(--text, #e0e0e0); + border: 1px solid var(--border, #333); + border-radius: var(--radius-md, 6px); + padding: 8px 12px; + font-size: 12px; + font-weight: 400; + line-height: 1.5; + white-space: normal; + width: 240px; + box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4); + pointer-events: none; + opacity: 0; + transition: opacity 0.15s ease; + z-index: 1000; + text-align: left; + text-transform: none; + letter-spacing: 0; +} + +.tip-icon::before { + content: ''; + position: absolute; + bottom: calc(100% + 3px); + left: 50%; + transform: translateX(-50%); + border: 5px solid transparent; + border-top-color: var(--border, #333); + pointer-events: none; + opacity: 0; + transition: opacity 0.15s ease; + z-index: 1001; +} + +.tip-icon:hover::after, +.tip-icon:hover::before { + opacity: 1; +} + +.tip-icon.tip-below::after { + bottom: auto; + top: calc(100% + 8px); +} + +.tip-icon.tip-below::before { + bottom: auto; + top: calc(100% + 3px); + border-top-color: transparent; + border-bottom-color: var(--border, #333); +}