Skip to content

fix(cortex-cli): add color preview to agent show command#66

Merged
echobt merged 1 commit intomasterfrom
fix/bounty-issue-1380
Jan 26, 2026
Merged

fix(cortex-cli): add color preview to agent show command#66
echobt merged 1 commit intomasterfrom
fix/bounty-issue-1380

Conversation

@echobt
Copy link
Contributor

@echobt echobt commented Jan 26, 2026

Summary

The agent show command now displays colors with a visual preview block using ANSI true color escape codes, along with an approximate color name (e.g., green, blue, red) to make the hex code more understandable.

Changes

  • Added parse_hex_color() function to parse hex color strings into RGB components
  • Added approximate_color_name() function to convert RGB values to human-readable color names
  • Added format_color_with_preview() function that combines a colored preview block with the hex code and color name
  • Modified the color display in run_show() to use the new formatting function
  • Added unit tests for all new functions

Before

Color: #22c55e

After

Color: [colored block] #22c55e (green)

Related

Fixes PlatformNetwork/bounty-challenge#1380

Fixes bounty issue #1380

The agent show command now displays colors with a visual preview block
using ANSI true color escape codes, along with an approximate color name
(e.g., green, blue, red) to make the hex code more understandable.
@echobt echobt merged commit 8e8fc8a into master Jan 26, 2026
9 of 12 checks passed
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.

[BUG] agent show displays Colors as hex without preview

2 participants