Commit e10219b
fix(feedback-widget): dark-mode adaptation + clearer placeholder (#7282)
## Summary
- FeedbackWidget surfaces (main FAB, mini-FAB stack, "Thanks!" toast,
popover Paper + TextFields + toggle buttons + secondary text) now use
CSS theme tokens (`--bg-surface`, `--bg-elevated`, `--ink`,
`--ink-muted`, `--rule`) instead of MUI palette tokens, so they track
the active light/dark scheme.
- Placeholder copy changed from "Typo, weird chart, feature idea…" to
"Bug, idea, typo, anything…" — bugs are a reactable category (🪲 already
in the toggles) and the new wording reads less dismissive.
## Context
MUI's palette is hard-pinned to `mode: 'light'` in `app/src/main.tsx`;
dark mode runs only through CSS custom properties on `<html>`.
Components using MUI tokens like `background.default`, `text.primary`,
`background.paper`, `text.secondary`, `action.hover` therefore stay
cream-on-dark when the user enables dark mode. The FeedbackWidget was
such a component.
The structural cure (migrating the theme to `CssVarsProvider` with both
`colorSchemes`) is tracked separately in #7281. This PR is the local fix
for the widget so users on dark mode aren't blocked by the refactor.
## Verified
- Typecheck (`tsc --noEmit`) green
- Light mode: FAB + popover render unchanged from before
- Dark mode (Playwright + computed-style probe):
- `.MuiPopover-paper` → `rgb(36,36,32)` text `rgb(240,239,232)`
- FAB → `rgb(26,26,23)` icon `primary.main`
- Placeholder + secondary text use `--ink-muted`
- Toggle button border and selected state use `--rule` / `--bg-surface`
## Test plan
- [ ] Open `/` in light mode → click feedback FAB → expand → all four
reactions visible, placeholder reads "Bug, idea, typo, anything…"
- [ ] Switch to dark mode → FAB + quick stack appear as warm near-black
on dark page (not cream)
- [ ] Open detailed popover in dark → Paper, input border, placeholder,
toggle buttons, "Page:" footer all read on dark surface
- [ ] Submit a 👍 → "Thanks!" toast appears on the elevated surface (not
white)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 780a2e2 commit e10219b
1 file changed
Lines changed: 40 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
32 | | - | |
| 31 | + | |
| 32 | + | |
33 | 33 | | |
34 | | - | |
| 34 | + | |
35 | 35 | | |
36 | 36 | | |
37 | 37 | | |
| |||
288 | 288 | | |
289 | 289 | | |
290 | 290 | | |
291 | | - | |
| 291 | + | |
292 | 292 | | |
293 | 293 | | |
294 | 294 | | |
295 | 295 | | |
296 | | - | |
| 296 | + | |
297 | 297 | | |
298 | 298 | | |
299 | 299 | | |
| |||
361 | 361 | | |
362 | 362 | | |
363 | 363 | | |
364 | | - | |
| 364 | + | |
365 | 365 | | |
366 | | - | |
| 366 | + | |
367 | 367 | | |
368 | 368 | | |
369 | 369 | | |
| |||
384 | 384 | | |
385 | 385 | | |
386 | 386 | | |
387 | | - | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
388 | 416 | | |
389 | 417 | | |
390 | 418 | | |
391 | 419 | | |
392 | 420 | | |
393 | | - | |
| 421 | + | |
394 | 422 | | |
395 | 423 | | |
396 | 424 | | |
| |||
409 | 437 | | |
410 | 438 | | |
411 | 439 | | |
412 | | - | |
| 440 | + | |
413 | 441 | | |
414 | 442 | | |
415 | 443 | | |
| |||
446 | 474 | | |
447 | 475 | | |
448 | 476 | | |
449 | | - | |
| 477 | + | |
450 | 478 | | |
451 | 479 | | |
452 | 480 | | |
| |||
476 | 504 | | |
477 | 505 | | |
478 | 506 | | |
479 | | - | |
| 507 | + | |
480 | 508 | | |
481 | 509 | | |
482 | 510 | | |
| |||
0 commit comments