Add tree rename (on Enter) and global rename hotkeys (#279)

This commit is contained in:
Gregory Schier
2025-10-24 08:01:38 -07:00
committed by GitHub
parent 43437abae7
commit 1198aa7d87
9 changed files with 218 additions and 93 deletions

View File

@@ -32,7 +32,7 @@ export function RecentRequestsDropdown({ className }: Props) {
}
});
useHotKey('request_switcher.prev', () => {
useHotKey('switcher.prev', () => {
if (!dropdownRef.current?.isOpen) {
// Select the second because the first is the current request
dropdownRef.current?.open(1);
@@ -41,7 +41,7 @@ export function RecentRequestsDropdown({ className }: Props) {
}
});
useHotKey('request_switcher.next', () => {
useHotKey('switcher.next', () => {
if (!dropdownRef.current?.isOpen) dropdownRef.current?.open();
dropdownRef.current?.prev?.();
});
@@ -87,7 +87,7 @@ export function RecentRequestsDropdown({ className }: Props) {
<Dropdown ref={dropdownRef} items={items}>
<Button
size="sm"
hotkeyAction="request_switcher.toggle"
hotkeyAction="switcher.toggle"
className={classNames(
className,
'truncate pointer-events-auto',