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

Bypassing prompt buffer for cases with a single suggestion #2995

Closed
lansingthomas opened this issue May 30, 2023 · 3 comments
Closed

Bypassing prompt buffer for cases with a single suggestion #2995

lansingthomas opened this issue May 30, 2023 · 3 comments
Labels
feature Feature requests. ui/ux Nyxt User Interface: themes, appearance and usability.

Comments

@lansingthomas
Copy link
Contributor

Hello all,
I think an improvement here could be wonderful for getting users from A-->B a little more efficiently. However, after writing this out I am no longer convinced that we need to bother with it. I am going to post here then close the issue so we have a transparent record of the thinking process, but do not need to take action.

The idea:

Is your feature request related to a problem? Please describe.

Sometimes I find myself indicating a command, then confirming when confirmation can be easily assumed. I get the sense that the system could be doing more for me in some pretty common cases.

Executing a command in Nyxt often follows a pattern.

1. indicate the command you wish to run
2. use the `prompt-buffer` and list of `suggestions` to target your command
3. return
4. fun and profit

Some cases have only one Suggestion, the targeting step is already done. A more efficient flow might look like:

1. indicate the command you wish to run
2. return
3. fun and profit

Describe the solution you'd like
FOR cases with a singular suggestion in the prompt-buffer
we automatically return the command without displaying the prompt buffer.

Describe alternatives you've considered
The seed for this idea came from a discussion in #2984 for finding a keystroke efficient way to close panel buffers.

Perhaps we can test the single suggestion bypass feature on this concrete use case (panel buffer deletion with delete-panel-buffer)

Additional context
IF my only options are to EITHER return a singular suggestion OR close the prompt-buffer WHY am I seeing the prompt buffer in the first place?

@aartaka mentioned this earlier

having the prompt is a nice confirmation moment so that one can reconsider (irrevocable) panel deletion.

how we might do it:

Help me answer these questions to move the discussion forward.

Where would this prompt-buffer-bypass apply?

  • single suggestion prompt buffers for common actions
    • delete-panel-buffer & change the Docstring to "Delete a single panel buffer, OR prompt for panel buffers to be deleted."

In which cases do we keep the prompt buffer?

  • Keep it anytime we have more than one suggestion.
  • Keep it in cases with one suggestion where the importance of the action is high enough that users would appreciate a nice confirmation moment.
    • delete-window
    • delete-buffer
  • keep it for commands with "query" as the action verb
    • history-forwards-query
    • history-backwards-query
  • keep it for commands with "prompt" as the action verb

it is looking like we do not have many compelling opportunities for this feature... the only case I can think of seems to be easily done with the delete-all-panel-buffers command (recently bound in #2984)

@lansingthomas lansingthomas added the feature Feature requests. label May 30, 2023
@lansingthomas
Copy link
Contributor Author

closing for now, willing to reopen if/when someone finds more use cases for the proposed feature.

@aartaka
Copy link
Contributor

aartaka commented May 30, 2023

I mean, we do this type of action in history-forwards-maybe-query already. As per the docs:

If current node has multiple children, query which one to navigate to.
Otherwise go forward to the only child.

And then, in buffer deletion that critical of an action? It's revocable with reopen-buffer/reopen-last-buffer (we should probably mention it in the echo message for buffer deletion), so it's not that critical. But yes, window deletion is quite critical.

So my list of commands to bypass:

  • history-forwards.
  • delete-panel-buffer.
  • delete-buffer.
  • reload-buffer.

Commands to merge into the commands above:

  • history-forwards-maybe-query—merge into history-forwards?
    • As an author of global history tree, I'm biased here :P
  • reload-buffers—if we make reload-buffer to have multiple selection.
    • Or the other way around—remove reload-buffer for reload-buffers.
    • A long overdue one, actually. Not even sure why we have two commands here...

@Ambrevar
Copy link
Contributor

Also see atlas-engineer/prompter#10.

@aartaka aartaka reopened this Jun 22, 2023
@aadcg aadcg added the ui/ux Nyxt User Interface: themes, appearance and usability. label Jul 17, 2023
@aadcg aadcg closed this as not planned Won't fix, can't repro, duplicate, stale Feb 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Feature requests. ui/ux Nyxt User Interface: themes, appearance and usability.
Development

No branches or pull requests

4 participants