zulip-terminal icon indicating copy to clipboard operation
zulip-terminal copied to clipboard

Globally refocus after search

Open Rohitth007 opened this issue 4 years ago • 1 comments

We currently can locally refocus back to the index before panel search in the left and right column. A more useful feature would be to focus back to where it was before search if it was not in the stream/topic/user list. Eg: If we are in the message view and press q, escaping should bring us back to that message.

Rohitth007 avatar Jun 07 '21 15:06 Rohitth007

Rereading, the concept appears to be that

  • currently going in/out of search in the side panels saves the previous position, eg. see #978
  • (this was also updated for topic position per stream subsequently)
  • upon noticing a search keypress we could also save the previous state, such as if in the central message list (or elsewhere)
  • backing out of a search (typically esc) would then restore that state

If we went with this, this could interact with displaying what Esc does, via eg. https://github.com/zulip/zulip-terminal/pull/1060#issuecomment-1925557444

Discussion was at: https://chat.zulip.org/#narrow/stream/206-zulip-terminal/topic/Globally.20refocus.20after.20search.20.23T1049

To explore the issue, please read that and continue discussion there.

neiljp avatar Apr 22 '24 18:04 neiljp