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

Adds 'starting_filter_input' to Select #185

Merged
merged 6 commits into from
Nov 1, 2023

Conversation

luctius
Copy link
Contributor

@luctius luctius commented Oct 10, 2023

This adds the option to set an initial filter value to the Select prompt.
My use-case it to allow the user to start a command with some initial input, if that doesn't match anything directly, build a Select prompt with their initial value as a starting point.

The current implementation does exhibit a (usual) problem, in that the contents is not yet filtered until the user takes another action. (for example, deleting a character). My first attempt at solving that resulted in a much larger PR, and would like your input if it is worth the effort (and if so, the best approach at solving it).

If this is something you could see working, I would be happy to add this to other prompts.

@luctius
Copy link
Contributor Author

luctius commented Oct 11, 2023

The lint error doesn't seem to originate from my code.

@mikaelmello mikaelmello merged commit 1949b47 into mikaelmello:main Nov 1, 2023
8 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.

2 participants