Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change Usage: gum confirm #488

Open
zen0bit opened this issue Jan 31, 2024 · 3 comments · May be fixed by #492
Open

Change Usage: gum confirm #488

zen0bit opened this issue Jan 31, 2024 · 3 comments · May be fixed by #492

Comments

@zen0bit
Copy link

zen0bit commented Jan 31, 2024

I'm always frustrated if gum confirm button color don't respect my stylling

Describe the solution you'd like
Add option to change button color from default pink to anything else
--button.color = 5

Describe alternatives you've considered
Don't use gum confirm

@zen0bit zen0bit changed the title gum confirm change button color confirm: change button color Jan 31, 2024
@jacobshu
Copy link

jacobshu commented Feb 5, 2024

@zen0bit I had this same problem. I was able to solve it this way:

gum confirm --selected.background 5

You can see the specific confirm option in confirm/options.go and the style reference in style/options.go.

@zen0bit
Copy link
Author

zen0bit commented Feb 6, 2024

Change gum confirm usage message to something like this?

Usage: gum confirm [<prompt>]

Ask a user to confirm an action

Arguments:
  [<prompt>]    Prompt to display.

Flags:
  -h, --help                 Show context-sensitive help.
  -v, --version              Print the version number

      --default              Default confirmation action
      --affirmative="Yes"    The title of the affirmative action
      --negative="No"        The title of the negative action
      --timeout=0            Timeout until confirm returns selected value or default if provided ($GUM_CONFIRM_TIMEOUT)

Style Flags
  --prompt.foreground=""           Foreground Color ($GUM_CONFIRM_PROMPT_FOREGROUND)
  --selected.foreground="230"      Foreground Color ($GUM_CONFIRM_SELECTED_FOREGROUND)
  --unselected.foreground="254"    Foreground Color ($GUM_CONFIRM_UNSELECTED_FOREGROUND)
  --selected.background="1"        Selected Background Color ($GUM_CONFIRM_SELECTED_BACKGROUND)
  --unselected.background="2"      Unselected Background Color ($GUM_CONFIRM_UNSELECTED_BACKGROUND)

@zen0bit
Copy link
Author

zen0bit commented Feb 6, 2024

If anyone can point me where I can find it that USAGE: message for gum confirm, I could try my first commit in go...
Maybe

@zen0bit zen0bit changed the title confirm: change button color Change Usage: gum confirmconfirm Feb 6, 2024
@zen0bit zen0bit changed the title Change Usage: gum confirmconfirm Change Usage: gum confirm Feb 6, 2024
@zen0bit zen0bit linked a pull request Feb 6, 2024 that will close this issue
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 a pull request may close this issue.

2 participants