Skip to content

fix(app): keep workspace message text readable on accent themes - #51528

Open
Dante-dan wants to merge 3 commits into
anomalyco:v2from
Dante-dan:workspace-contrast
Open

Dante-dan wants to merge 3 commits into
anomalyco:v2from
Dante-dan:workspace-contrast

Conversation

@Dante-dan

@Dante-dan Dante-dan commented Sep 26, 2026 •

Copy link
Copy Markdown

Issue for this PR

Closes #50986

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Workspace user messages use the theme accent background, but paired it with a foreground meant for a different surface. One Dark Pro dark mode therefore rendered the message at about 1.1:1 contrast. I added an accent foreground token chosen against the resolved accent background and used it for the workspace message and mention prefix. This keeps the accent styling while choosing readable text for bright as well as dark accents. The selector and contrast diagnosis were documented in the issue discussion.

How did you verify your code works?

  • bun test src/theme/v2/resolve.test.ts in packages/ui: 84 passed, including all built-in themes in both color schemes and a custom theme fallback.
  • bun typecheck in packages/ui: passed.
  • bun typecheck in packages/session-ui: passed.
  • Updated against v2 after the GUI extension migration, which removed the legacy workspace E2E file; the theme regression remains.
  • bun run check via the unmodified pre-push hook: passed; 36 typecheck tasks succeeded. Full lint reported 17,583 warnings and 0 errors. Astro emitted a sandbox log-directory warning while its diagnostics passed.

Screenshots / recordings

Before: One Dark Pro workspace screenshot from the issue. An after screenshot was not captured: the earlier targeted Playwright run could not launch Chromium in this macOS sandbox (MachPortRendezvousServer permission denied). The legacy E2E file was subsequently removed upstream during the GUI extension migration.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@github-actions

Copy link
Copy Markdown
Contributor

Thanks for your contribution!

This PR doesn't have a linked issue. All PRs must reference an existing issue.

Please:

  1. Open an issue describing the bug/feature (if one doesn't exist)
  2. Add Fixes #<number> or Closes #<number> to this PR description

See CONTRIBUTING.md for details.

@github-actions

Copy link
Copy Markdown
Contributor

The following comment was made by an LLM, it may be inaccurate:

This branch has not been deployed

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant