Skip to content

fix(tui): align Claude Code style colors#1697

Closed
lbcheng888 wants to merge 12 commits into
Hmbown:mainfrom
lbcheng888:codex/claude-code-deepseek-tui
Closed

fix(tui): align Claude Code style colors#1697
lbcheng888 wants to merge 12 commits into
Hmbown:mainfrom
lbcheng888:codex/claude-code-deepseek-tui

Conversation

@lbcheng888
Copy link
Copy Markdown
Contributor

Summary

  • align the TUI palette with Claude Code-style neutral white/gray rendering while keeping DeepSeek blue accents
  • remove warm Claude/amber leakage from composer, plan/warning roles, optional themes, footer/header styling, and Todos coloring
  • align tool success/failure accents to Claude Code green/red and keep command/result body text pure white with neutral gray summaries
  • tighten diff and markdown rendering toward Claude Code-style visual hierarchy

Verification

  • cargo fmt --all --check
  • git diff --check
  • cargo build
  • cargo test -p deepseek-tui --test palette_audit
  • cargo test -p deepseek-tui deepseek_theme
  • cargo test -p deepseek-tui diff_render
  • cargo test -p deepseek-tui markdown_render
  • cargo test -p deepseek-tui run_tool_header_command_uses_pure_white
  • cargo test -p deepseek-tui non_command_tool_header_summary_uses_neutral_gray
  • cargo test -p deepseek-tui tool_output_body_uses_pure_white
  • cargo test -p deepseek-tui assistant_summary_body_uses_pure_white_markdown
  • cargo test -p deepseek-tui --test qa_pty

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request implements a comprehensive UI redesign for the DeepSeek TUI, shifting towards a minimal 'Claude-style' aesthetic. Major updates include a streamlined one-line header, a more compact transcript format for tool calls, a new 'swimming whale' footer animation, and the addition of basic syntax highlighting for markdown code blocks. Feedback identifies a critical compilation issue due to the use of unstable Rust 'let_chains' in the palette module, a layout bug in the composer widget where border height is incorrectly calculated, and a limitation in the syntax highlighter's string parsing logic which fails to handle escaped quotes.

Comment thread crates/tui/src/palette.rs
Comment thread crates/tui/src/tui/widgets/mod.rs
Comment thread crates/tui/src/tui/markdown_render.rs Outdated
lbcheng888 and others added 3 commits May 16, 2026 06:43
…sign

- Collapse nested ifs with let_chains (stable since Rust 1.85, MSRV 1.88)
- Use is_none_or() instead of map_or(true, ...)
- Use strip_prefix() for code fence language extraction
- Fix light_palette_maps test: use palette::DEEPSEEK_INK instead of stale
  hardcoded Rgb(11,21,38) which no longer matches after INK→(7,12,18)
- Fix composer_border test: check locale-independent COMPOSER_PROMPT "> "
  instead of removed "Composer" panel title

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@lbcheng888 lbcheng888 force-pushed the codex/claude-code-deepseek-tui branch from cc80f75 to b4401d8 Compare May 15, 2026 23:17
lbcheng888 and others added 8 commits May 16, 2026 07:29
These zero-sized structs exist only as trait impl namespaces; they are
never constructed but their associated constants are part of the public API.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
When an agent is running but not yet in subagent_cache, use the
agent_progress value (which holds the summarized assignment objective
or friendly progress string) as the display name in the agents sidebar
instead of the bare agent_<hash> identifier.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Drop millisecond/decimal precision — 1s is enough for the agent sidebar.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Claude Code's agent sidebar shows useful metrics, not implementation
details. Remove the truncated agent_<hash> ID from the detail line,
keep only steps / duration / progress summary. Also normalize "step(s)"
to "steps".

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
- Drop max_steps from subagent loop: use unbounded `loop` like Claude Code,
  letting context window exhaustion naturally bound agent execution.
- Add `objective` field to MailboxMessage::Started so the TUI knows the
  agent's task description from the start.
- Show task summary (not raw agent ID) in DelegateCard transcript header
  and in the agent sidebar when the agent hasn't reached subagent_cache yet.
- Format subagent duration in whole seconds instead of milliseconds.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
After removing the old 100-step limit, a runaway agent loop could
generate enough events to saturate the bounded engine event channel
(256), causing the UI to stall waiting for drain. Add a hard safety
limit at 500 steps — well above any reasonable agent run — with a
graceful completion message so the agent still produces a useful
result instead of silently dying.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
The id field is set on every construction path but never read during
rendering, which triggers `-D dead-code` under CI. Also apply cargo fmt
to fix lint check failures.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Keep both the PR's updated color constants (MODE_AGENT, MODE_YOLO,
MODE_PLAN, SELECTION_BG) and main's macOS palette detection functions
from upstream main.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@Hmbown
Copy link
Copy Markdown
Owner

Hmbown commented May 23, 2026

This PR was opened before the v0.8.41 rebrand and is now stale. Feel free to rebase onto current main and reopen. 鲸鱼兄弟们等你 🐋

@Hmbown Hmbown closed this May 23, 2026
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