jonmbake / react-terminal-ui

A terminal react component with support for light and dark modes.
https://jonmbake.github.io/react-terminal-ui/demo/
MIT License
204 stars 30 forks source link

Add tab completion #55

Open colonelpopcorn opened 1 month ago

colonelpopcorn commented 1 month ago

Is your feature request related to a problem? Please describe. A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

Describe the solution you'd like A clear and concise description of what you want to happen.

Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.

Additional context Add any other context or screenshots about the feature request here.

The terminal should be able to autocomplete or show a list of close enough items to tab through. That way you can autocomplete predefined commands. In your example, you can create an array and do a switch/case or an includes call to determine if the right command was specified. You could even have this array be an object that could have a handler attached to be run when a match is found. Just a few thoughts, this looks great, thanks!

github-actions[bot] commented 1 month ago

Thank you for taking the time to submit an Issue! You should get a response to this issue within one to two days.