microsoft / microsoft/terminal

Tab position is not restored for `restoreLastClosed` action

Open
#12,902 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Area-UserInterface Help Wanted Issue-Bug Priority-3 Product-Terminal
Dominant language
C++
Stars
105k
Forks
9.6k
Avg merge
3d 17h
Merged PRs (30d)
29

Description

The problem with this is the tab position is not restored, if tab closed is first one, the restored tab is the last one.
the position should also be restored

_Originally posted by @swinder0161 in https://github.com/microsoft/terminal/issues/960#issuecomment-1098341305_

This might be tricky - we might be able to remember the location of the tab, but I'd expect it to work weird if the tabs get reordered before restoring the tab. This might be acceptable though.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the `restoreLastClosed` action and how a closed tab's location is remembered. Reproduce the case where the first tab is closed and restored, then define completion as restoring it to its prior position, while checking behavior if tabs are reordered before restoration.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
cli
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.