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

Keep tab position when closing tabs #18036

Closed
1 task done
rchatrath7 opened this issue Sep 18, 2024 · 2 comments · Fixed by #18168
Closed
1 task done

Keep tab position when closing tabs #18036

rchatrath7 opened this issue Sep 18, 2024 · 2 comments · Fixed by #18168
Labels
enhancement [core label] good first issue Issue suitable for first-time contributors tabs Feedback for tabs behavior, navigation, style, etc

Comments

@rchatrath7
Copy link

Check for existing issues

  • Completed

Describe the feature

When closing tabs, I expect zed to keep the position of whatever tab I'm at when I close it with cmd+w, like how a browser would. i.e. if I have 5 tabs open, and I close the 3rd tab, I expect zed to keep the new 3rd tab focused.
I often have a lot of tabs open as I'm working and go to cull them in bulk by holding cmd+w, but usually I want to keep my most recent tab open as I'm still working on it. What happens at that point is that the editor jumps to my most recent tab which might have changes and it's really annoying to have either close it out so I can just hold cmd+w or constantly click out of the tab so I can close out all my other tabs.

If applicable, add mockups / screenshots to help present your vision of the feature

No response

@rchatrath7 rchatrath7 added admin read Pending admin review enhancement [core label] triage Maintainer needs to classify the issue labels Sep 18, 2024
@notpeter
Copy link
Member

Gotcha. This is pretty straight forward. So if I understand the request correctly:

If closing Tab N the focus should jump to the new Tab N (what was previously Tab N + 1) unless Tab N was the right most tab and then it should shift Tab N - 1.

@notpeter notpeter added tabs Feedback for tabs behavior, navigation, style, etc good first issue Issue suitable for first-time contributors and removed triage Maintainer needs to classify the issue admin read Pending admin review labels Sep 19, 2024
@rchatrath7
Copy link
Author

Yes, that sounds perfect! Thank you for prioritizing!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement [core label] good first issue Issue suitable for first-time contributors tabs Feedback for tabs behavior, navigation, style, etc
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants