git: Fix branch picker creating new branches with refs/head/ prefixed on the branch name (#44206)

The bug was introduced in this recent PR:
https://github.com/zed-industries/zed/pull/42819. Since it's still in
nightly, there is no need for release notes.

I also polished the feature a bit by:
- Ensuring branch names are always a single line so the branch picker's
uniform list uses the correct element height.
- Adding tooltip text for the filter remotes button.
- Fixing the create branch from default icon showing up for non-new
branch entries.

Release Notes:

- N/A
This commit is contained in:
Anthony Eid
2025-12-05 12:59:13 +00:00
committed by GitHub
parent a5ab5c7d5d
commit 126d708fa1
5 changed files with 69 additions and 46 deletions
+2 -1
View File
@@ -1332,7 +1332,8 @@
"context": "GitBranchSelector || (GitBranchSelector > Picker > Editor)",
"use_key_equivalents": true,
"bindings": {
"ctrl-shift-backspace": "branch_picker::DeleteBranch"
"ctrl-shift-backspace": "branch_picker::DeleteBranch",
"ctrl-shift-i": "branch_picker::FilterRemotes"
}
}
]