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

'All messages' are not consistently accessible compared to P/#/f #1505

Open
neiljp opened this issue May 29, 2024 · 1 comment · May be fixed by #1512
Open

'All messages' are not consistently accessible compared to P/#/f #1505

neiljp opened this issue May 29, 2024 · 1 comment · May be fixed by #1512
Labels
area: hotkeys bug Something isn't working

Comments

@neiljp
Copy link
Collaborator

neiljp commented May 29, 2024

Bug description

As discussed in the past, and again in #1480, the key(s) for 'all messages' (a, Esc ) do not work reliably except when a message is selected.

This compares with P, #, f, which are also in the top left list of views (as the web app now names/groups them), which are accessible from:

  • the left panel (whether on the button or not)
  • the right panel (ie. user list)
  • possibly elsewhere? (to be confirmed)

Discussed at:
#zulip-terminal > Make the ALL_MESSAGES command work everywhere

How is the bug triggered?

How can you reproduce the bug?

  1. Enter different areas of the UI where one of P/#/f are confirmed to change narrow (as above, and excluding the central message area)
  2. The a hotkey fails to trigger a change in the central active narrow (message list), as does Esc, though also behaves differently depending upon context

What did you expect to happen?

For context, when a message is selected, narrowing keys like these are currently expected to keep message focus, but change the narrow to view around it - this is not the intent for this fix.

Instead, when selecting a view/narrow explicitly (stream/topic/DMs/etc), from a side panel or hotkey from these locations, this should enter the first unread message in that view. This is what should already occur with the existing P/#/f hotkeys.

One possible challenge here is that Esc is used for various other functions, so they should likely take precedence, for example:

  • exiting popups
  • exiting searches
  • exiting compose

Similarly, when a text box is open, such as during searches or when the compose box is open, regular keys such as a would not be expected to cause narrowing.

Related aspects

These were discussed in the topic linked above:

  • Esc could be enabled or disabled depending upon the organization user setting for using Esc to go to the default/home view
  • Splitting the GO_BACK command may make it clearer in the help, compared to 'Go back'; otherwise this is somewhat of a refactor in the context of this issue

How are you running the application?

Please include as many of the following as possible:

  • Zulip-terminal version: 0.7.0+git
    eg. a specific version (0.7.0), or if running from main also ideally the git ref
  • Zulip server version(s): chat.zulip.org
    eg. Zulip Cloud, the version you are running self-hosted, or the Zulip Community server (chat.zulip.org)
  • Operating system (and version): Debian
    eg. Debian Linux, Ubuntu Linux, macOS, WSL in Windows, Docker
  • Python version (and implementation): 3.9
    eg. 3.8, 3.9, 3.10, ... (implementation is likely to be eg. CPython, or PyPy)

If possible, please provide details from the About menu: (hotkey: Meta + ?)
(this can provide some of the details above)

@neiljp neiljp added bug Something isn't working area: UI General user interface update labels May 29, 2024
@neiljp neiljp changed the title Hotkeys for 'all messages' are not consistently accessible compared to P/#/f 'All messages' are not consistently accessible compared to P/#/f May 29, 2024
@neiljp neiljp added area: hotkeys and removed area: UI General user interface update labels May 29, 2024
@zulipbot
Copy link
Member

Hello @zulip/server-hotkeys members, this issue was labeled with the "area: hotkeys" label, so you may want to check it out!

@Niloth-p Niloth-p linked a pull request Jun 6, 2024 that will close this issue
18 tasks
Niloth-p added a commit to Niloth-p/zulip-terminal that referenced this issue Jun 6, 2024
This command worked only when a message was selected, using it as
an anchor to fetch messages.
Now, it has been made consistent with the other menu button commands,
to work from any panel.

This could not be implemented in ui.py along with other menu buttons,
because of the conflict caused by the Esc key also being assigned to
reset search in the side panels (GO_BACK command).

When both operations,
1. reset search in the current panel view
2. narrow to all messages
are possible, pressing `Esc` is set to trigger only
the reset search operation and not the ALL_MESSAGES command.
The next keypress of `Esc` will go to the home view once the
current panel view is restored to its default state.

Fixes zulip#1505.
Niloth-p added a commit to Niloth-p/zulip-terminal that referenced this issue Jun 26, 2024
This command worked only when a message was selected, using it as
an anchor to fetch messages.
Now, it has been made consistent with the other narrow commands,
to work from any panel.

This could not be implemented in ui.py along with other narrow commands,
because of the conflict caused by the Esc key also being assigned to
reset search in the side panels (GO_BACK command).

When both operations,
1. reset search in the current panel view
2. narrow to all messages
are possible, pressing `Esc` is set to trigger only
the reset search operation and not the ALL_MESSAGES command.
The next keypress of `Esc` will go to the home view once the
current panel view is restored to its default state.

Fixes zulip#1505.
Niloth-p added a commit to Niloth-p/zulip-terminal that referenced this issue Jun 28, 2024
This command worked only when a message was selected, using it as
an anchor to fetch messages.
Now, it has been made consistent with the other narrow commands,
to work from any panel.

This could not be implemented in ui.py along with other narrow commands,
because of the conflict caused by the Esc key also being assigned to
reset search in the side panels (GO_BACK command).

When both operations,
1. reset search in the current panel view
2. narrow to all messages
are possible, pressing `Esc` is set to trigger only
the reset search operation and not the ALL_MESSAGES command.
The next keypress of `Esc` will go to the home view once the
current panel view is restored to its default state.

Fixes zulip#1505.
Niloth-p added a commit to Niloth-p/zulip-terminal that referenced this issue Jun 28, 2024
This command worked only when a message was selected, using it as
an anchor to fetch messages.
Now, it has been made consistent with the other narrow commands,
to work from any panel.

This could not be implemented in ui.py along with other narrow commands,
because of the conflict caused by the Esc key also being assigned to
reset search in the side panels (GO_BACK command).

When both operations,
1. reset search in the current panel view
2. narrow to all messages
are possible, pressing `Esc` is set to trigger only
the reset search operation and not the ALL_MESSAGES command.
The next keypress of `Esc` will go to the home view once the
current panel view is restored to its default state.

Fixes zulip#1505.
Niloth-p added a commit to Niloth-p/zulip-terminal that referenced this issue Jul 18, 2024
This command worked only when a message was selected, using it as
an anchor to fetch messages.
Now, it has been made consistent with the other narrow commands,
to work from any panel.

This could not be implemented in ui.py along with other narrow commands,
because of the conflict caused by the Esc key also being assigned to
reset search in the side panels (GO_BACK command).

When both operations,
1. reset search in the current panel view
2. narrow to all messages
are possible, pressing `Esc` is set to trigger only
the reset search operation and not the ALL_MESSAGES command.
The next keypress of `Esc` will go to the home view once the
current panel view is restored to its default state.

Fixes zulip#1505.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: hotkeys bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants