theseus/bundled-addons/screenshot/editor.css
Local Dev f8c58538d0 fix: use BCH-primary #0AC18E in light mode + strip Electron token from UA
Two related visibility fixes:

1) Light-mode --acid → #0AC18E (Bitcoin Cash brand primary, from
   whybitcoincash.com's palette per user). Direct swap from #088A66
   (darkened variant) to the on-brand primary. Applied across chrome /
   settings / error / home / approval / messages / bchwallet /
   siawallet / screenshot editor. Dark mode's #d6ff3d is unchanged.

2) User-Agent no longer includes 'theseus-navigator/<ver>' or
   'Electron/<ver>' tokens. Cloudflare's WAF was returning HTTP 503
   'Service Unavailable' to any request carrying those (verified
   directly against whybitcoincash.com — same URL, same headers, only
   the UA differed; plain Chrome UA got 200, Theseus UA got 503).
   Strip both tokens via a stockChromeUA() helper called from
   applyAcceptLanguage(), which whenReady already invokes at boot.
   Standard practice: Brave, Vivaldi, Slack all do the same.

Verified via CDP: navigator.userAgent now reports
  Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36
  (KHTML, like Gecko) Chrome/130.0.6723.191 Safari/537.36
— indistinguishable from stock Chrome.
2026-09-08 01:04:27 +02:00

90 lines
4.9 KiB
CSS

/* Screenshot editor — full-tab page. Matches the Theseus dark aesthetic
from the sidebar. Light-mode swap is symmetric. */
:root { color-scheme: light dark;
--bg:#0e131c; --panel:#141a24; --panel2:#191f2b; --line:rgba(255,255,255,.09);
--ink:#e7eaf1; --mut:#8b98a9; --dim:#5e6678; --acid:#d6ff3d;
--danger:#ff5b5b; --board:#0a0d13; }
@media (prefers-color-scheme: light) {
:root { --bg:#f8faff; --panel:#ffffff; --panel2:#eff3fb; --line:rgba(0,0,0,.10);
--ink:#1a1f2b; --mut:#5c6577; --dim:#8a93a5; --acid: #0AC18E;
--board:#dde3ee; }
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--ink);
font: 13px/1.5 system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
display: flex; flex-direction: column; overflow: hidden; }
/* Toolbar ---------------------------------------------------------------- */
.toolbar { display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
padding: 8px 10px; border-bottom: 1px solid var(--line);
background: var(--panel); user-select: none;
font: 12px ui-monospace, "Cascadia Code", Consolas, monospace; }
.toolbar .name { color: var(--dim); font-size: 11.5px; margin-right: 4px; overflow: hidden;
text-overflow: ellipsis; white-space: nowrap; max-width: 240px; }
.toolbar .sep { width: 1px; height: 22px; background: var(--line); margin: 0 4px; }
.toolbar .spacer { flex: 1; }
.tool { border: 1px solid var(--line); background: var(--panel2); color: var(--ink);
width: 30px; height: 30px; border-radius: 6px; cursor: pointer;
display: inline-flex; align-items: center; justify-content: center;
font: inherit; padding: 0; transition: background .1s, border-color .1s; }
.tool:hover { border-color: rgba(214,255,61,.5); }
.tool.active { background: rgba(214,255,61,.15); border-color: rgba(214,255,61,.7); color: var(--acid); }
.tool:disabled { opacity: .4; cursor: default; }
.tool svg { width: 16px; height: 16px; display: block; }
.tool.wide { width: auto; padding: 0 10px; gap: 6px; }
.tool.danger { color: var(--danger); }
.tool.danger:hover { border-color: rgba(255,91,91,.5); }
.swatch { width: 22px; height: 22px; border-radius: 50%; padding: 0;
border: 2px solid var(--line); cursor: pointer; }
.swatch.active { border-color: var(--acid); outline: 1px solid rgba(214,255,61,.35); outline-offset: 1px; }
.width { border: 1px solid var(--line); background: var(--panel2); color: var(--ink);
width: 30px; height: 30px; border-radius: 6px; cursor: pointer;
display: inline-flex; align-items: center; justify-content: center;
padding: 0; }
.width.active { border-color: rgba(214,255,61,.7); background: rgba(214,255,61,.15); }
.width .dot { border-radius: 50%; background: currentColor; color: var(--ink); }
.width.active .dot { color: var(--acid); }
.text-input {
position: absolute; z-index: 10;
background: rgba(20,26,36,.92); color: var(--ink); border: 1px solid var(--acid);
padding: 2px 6px; font: 15px/1.2 system-ui, sans-serif; outline: none;
border-radius: 3px; min-width: 80px;
}
/* Canvas board ----------------------------------------------------------- */
.board { flex: 1; overflow: auto; background: var(--board);
display: flex; align-items: flex-start; justify-content: center;
padding: 20px; }
.stage { position: relative; box-shadow: 0 0 0 1px var(--line), 0 8px 30px rgba(0,0,0,.35); }
.stage canvas { display: block; background: #fff; }
.stage canvas.draw { position: absolute; left: 0; top: 0; }
.stage canvas.overlay { position: absolute; left: 0; top: 0; pointer-events: none; }
/* When a drawing tool is active, put the drawing canvas above overlay */
.stage[data-tool="select"] canvas.draw { cursor: default; }
.stage[data-tool="crop"] canvas.draw { cursor: crosshair; }
.stage[data-tool="rect"] canvas.draw,
.stage[data-tool="ellipse"] canvas.draw,
.stage[data-tool="arrow"] canvas.draw,
.stage[data-tool="blur"] canvas.draw { cursor: crosshair; }
.stage[data-tool="pen"] canvas.draw { cursor: crosshair; }
.stage[data-tool="text"] canvas.draw { cursor: text; }
.hint { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%);
background: rgba(11,14,20,.9); border: 1px solid var(--line);
color: var(--ink); padding: 6px 10px; border-radius: 6px;
font-size: 12px; pointer-events: none; opacity: 0; transition: opacity .15s; }
.hint.on { opacity: 1; }
.toast { position: fixed; right: 16px; bottom: 16px;
background: rgba(214,255,61,.15); color: var(--acid);
border: 1px solid rgba(214,255,61,.5);
padding: 8px 12px; border-radius: 6px; font-size: 12.5px;
opacity: 0; transform: translateY(6px);
transition: opacity .2s, transform .2s; pointer-events: none; }
.toast.on { opacity: 1; transform: translateY(0); }
.toast.err { color: #ffb0b0; background: rgba(255,60,60,.15); border-color: rgba(255,60,60,.5); }