mirror of
https://github.com/Termix-SSH/Termix.git
synced 2026-10-30 07:05:24 +00:00
fix: number shortcuts skip the home tab (#1724)
This commit is contained in:
1 parent
474996b6e0
commit
034d68b163
2 files changed
+4
-2
No files matched your search
@@ -208,11 +208,12 @@ export function useShellKeybindings({
|
||||
return;
|
||||
}
|
||||
|
||||
// Cmd+1..9 on macOS, Alt+1..9 elsewhere: jump directly to the tab at that position
|
||||
// Cmd+1..9 on macOS, Alt+1..9 elsewhere: jump directly to the tab at that
|
||||
// position. The home tab has its own button, so the count starts after it.
|
||||
const tabDigit = getTabJumpDigit(e);
|
||||
if (tabDigit !== null) {
|
||||
const currentTabs = tabsRef.current.filter(
|
||||
(tab) => !tab.parentSplitTabId,
|
||||
(tab) => !tab.parentSplitTabId && tab.type !== "dashboard",
|
||||
);
|
||||
const index = tabDigit - 1;
|
||||
if (index < currentTabs.length) {
|
||||
|
||||
Reference in new issue
Block a user