PyInquirer icon indicating copy to clipboard operation
PyInquirer copied to clipboard

The "expand" type is described as using `help` by default, but instead the first choice is used by default

Open tjb1982 opened this issue 6 years ago • 9 comments

I suppose this could be just a change to the readme to correctly describe the default behavior, but there is currently no way that I can find to make help the default for the expand type.

tjb1982 avatar Apr 29 '19 15:04 tjb1982

@tjb1982 I dont understand what you mean

CITGuru avatar May 05 '19 21:05 CITGuru

I mean when you provide a list of choices and no default, like

{
  "type": "expand",
  #"default": "<=commented-out",
  "choices": [...],
}

The default (i.e., hitting the return key) should expand the help, but instead the first provided choice is the default.

tjb1982 avatar May 07 '19 20:05 tjb1982

Yes, you mean it should show up the help rather than the default if the default is not given.

CITGuru avatar May 09 '19 04:05 CITGuru

I mean, that's what I thought the docs said it would do. I also think it should be possible to manually assign the help as the default, but that doesn't seem to work either.

tjb1982 avatar May 09 '19 14:05 tjb1982

Hmmnnn, lemme check that out.

CITGuru avatar May 09 '19 14:05 CITGuru

If you accept PRs on this I can probably help out, also. Let me know.

tjb1982 avatar May 10 '19 12:05 tjb1982

Sure I accept PRS. I am actually looking for contributors now

CITGuru avatar May 10 '19 13:05 CITGuru

Sorry for the delayed reply. Okay, great. I'm actively using this library on a project, so as I go, I'll make PRs. I'm side tracked right now, though, with a project at work, so it might be a couple of weeks.

tjb1982 avatar May 17 '19 01:05 tjb1982

Sure, no problem. Thanks

CITGuru avatar May 17 '19 08:05 CITGuru