Skip to content

fix: improve confirm prompt button contrast in ThemeSurvey#572

Closed
sridhar-3009 wants to merge 1 commit into
slackapi:mainfrom
sridhar-3009:fix/huh-prompt-button-contrast
Closed

fix: improve confirm prompt button contrast in ThemeSurvey#572
sridhar-3009 wants to merge 1 commit into
slackapi:mainfrom
sridhar-3009:fix/huh-prompt-button-contrast

Conversation

@sridhar-3009
Copy link
Copy Markdown

Problem

Closes #562.

ThemeSurvey did not set FocusedButton or BlurredButton styles, so it fell through to ThemeBase defaults:

  • FocusedButton: black text on white background (ANSI 0 on 7)
  • BlurredButton: white text on black background (ANSI 7 on 0)

In many terminal color schemes these look nearly identical, making it unclear which Yes/No button is currently selected.

Fix

Add explicit FocusedButton and BlurredButton styles in themeSurvey:

t.Focused.FocusedButton = lipgloss.NewStyle().
    Foreground(ansiBlue).
    Bold(true).
    Padding(0, 1)
t.Focused.BlurredButton = lipgloss.NewStyle().
    Foreground(ansiGray).
    Padding(0, 1)
  • Focused (selected): blue + bold — matches the existing SelectSelector / SelectedOption color used throughout ThemeSurvey, visually consistent.
  • Blurred (unselected): gray, no bold — clearly inactive.

The contrast no longer depends on terminal background color.

ThemeSurvey did not set FocusedButton/BlurredButton styles, so it fell
through to ThemeBase defaults: black-on-white for selected and white-on-
black for unselected. These look nearly identical in many terminal themes
and make it hard to tell which button (Yes/No) is currently active.

Add explicit styles to themeSurvey:
- FocusedButton: blue, bold — clearly selected
- BlurredButton: gray, no bold — clearly inactive

The blue matches the existing SelectSelector/SelectedOption color used
throughout ThemeSurvey, making the confirm prompt visually consistent
with the rest of the survey UI.

Fixes slackapi#562
@sridhar-3009 sridhar-3009 requested a review from a team as a code owner June 3, 2026 04:49
@salesforce-cla salesforce-cla Bot added the cla:missing The CLA was not signed label Jun 3, 2026
@salesforce-cla
Copy link
Copy Markdown

salesforce-cla Bot commented Jun 3, 2026

Thanks for the contribution! Before we can merge this, we need @sridhar-3009 to sign the Salesforce Inc. Contributor License Agreement.

@zimeg
Copy link
Copy Markdown
Member

zimeg commented Jun 3, 2026

👋 Hey @sridhar-3009! Thanks for sending this in I think we should close #562 with #564!

@zimeg zimeg closed this Jun 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla:missing The CLA was not signed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Huh confirm prompt: selected vs unselected button is hard to distinguish

2 participants