Skip to content

feat(prompt): keep the Claude Code apply prompt to what it can apply - #205

Merged
luongnv89 merged 1 commit into
mainfrom
feat/claude-code-prompt-quiet-apply
Oct 16, 2026
Merged

luongnv89 merged 1 commit into
mainfrom
feat/claude-code-prompt-quiet-apply

Conversation

@luongnv89

@luongnv89 luongnv89 commented Oct 16, 2026 •

Copy link
Copy Markdown
Owner

Closes #206

Summary

Applying a theme with the Claude Code prompt produced a long reply: contrast measurements, a made-up success color, a note about the terminal background, and a list of things it couldn't apply (fonts, syntax colors, web steps, light mode). This happened because the prompt asked for things a Claude Code theme can't do and left the rest to the agent's judgement.

  • Colors only: a new COLOR_ONLY_APP_TARGETS list (currently just claude-code) in src/lib/appTargets.ts. Targets on it get a prompt without the STYLE block or the generic "Also follow agentInstructions.steps / Test in both light and dark modes" ending.
  • Rules stated up front in the Claude Code instruction:
    • write one file, for the theme's default mode
    • fallback green hsl(150 80% 70%) on a dark base, hsl(150 70% 30%) on a light one
    • fix contrast by changing lightness only, until text colors reach 4.5:1 and promptBorder reaches 3:1
    • the theme sets UI colors only and draws on the terminal's own background
  • Short reply: only the file path and the /theme step.

Other app targets are unchanged. The pairing prompt in themeMapping.ts reuses the same Claude Code instruction text, so it picks up the new rules too.

Test plan

  • npm test: 481 passed. Includes a new test for what the Claude Code prompt must include and leave out.
  • tsc --noEmit and eslint on the changed files are clean.
  • Paste the new prompt into Claude Code and check that the reply is just the path and the /theme step.

🤖 Generated with Claude Code

The Claude Code prompt carried the STYLE block and the generic
"follow agentInstructions.steps / test both modes" tail, so the agent
reported fonts, web steps and light mode as skipped, and listed every
contrast fix and derived color it chose.

- Claude Code is now a colors-only target: its prompt drops STYLE and
  the generic tail.
- The instruction states the rules up front: default mode only, a
  fallback green, lightness-only contrast fixes (4.5:1 text, 3:1
  promptBorder), UI colors only on the terminal background.
- The agent replies with only the file path and the /theme step.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@luongnv89
luongnv89 merged commit b03c050 into main Oct 16, 2026
5 checks passed
@luongnv89
luongnv89 deleted the feat/claude-code-prompt-quiet-apply branch October 16, 2026 09:25
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.

Keep the Claude Code apply prompt to what a Claude Code theme can apply

1 participant