Closed ccsliinc closed 2 years ago
Well it was just created for that scenario - so the user performs an action and accepts that something will happen, it will block until it is accepted. It did not need a return value for our usage because to be unlocked it must be accepted.
What would you like an alternative for? What are you trying to achieve?
I was just trying to figure out if the user did not want to go through with the action what would they do. Even something as simple as hitting the escape key would allow them to exit the process. The only way I see it’s possible right now is if they actually exit the whole process itself. So for example if it was a confirm deletion dialogue and they accidentally hit it, then they have no way of backing out.
Of course, I don't dispute your use-case. It makes total sense. However, it is not supported right now. We would happily accept this as a feature request if you are interested in working on it :)
Yes, Thank you i will work on it.
Just remembered someone started this a while ago - maybe you can use it https://github.com/php-school/cli-menu/pull/65
I will have a pull request by Monday. It’s full working non breaking. Just learning to write tests.
PR sent.
Fixed with #248
Is there any way you can add a point release to this PR. I use this but it's a requirement for another component. I'd like it to pull this release.
Is there any way you can add a point release to this PR. I use this but it's a requirement for another component. I'd like it to pull this release.
@ccsliinc 4.2.0
@AydinHassan Thank you.
Looking through the code, the confirm dialog is not actually a confirmation. It has no return value, am i missing something or the way it currently is just another layer in which a user cannot back out? It seems like there is nothing I can do with a dialog other than click enter. You cant even escape out.
I am just asking to know if there is an alternative.