mirror of
https://github.com/claude-code-best/claude-code.git
synced 2026-06-15 12:55:51 +00:00
fix: 消除 UltraplanChoiceDialog 中的 wheelDown/wheelUp as any
Ink Key 类型已包含 wheelDown/wheelUp 属性,直接访问即可。
This commit is contained in:
@@ -87,11 +87,11 @@ export function UltraplanChoiceDialog({
|
||||
if (!isScrollable) return;
|
||||
const halfPage = Math.max(1, Math.floor(visibleHeight / 2));
|
||||
|
||||
if ((key.ctrl && input === 'd') || (key as any).wheelDown) {
|
||||
const step = (key as any).wheelDown ? 3 : halfPage;
|
||||
if ((key.ctrl && input === 'd') || key.wheelDown) {
|
||||
const step = key.wheelDown ? 3 : halfPage;
|
||||
setScrollOffset(prev => Math.min(prev + step, maxOffset));
|
||||
} else if ((key.ctrl && input === 'u') || (key as any).wheelUp) {
|
||||
const step = (key as any).wheelUp ? 3 : halfPage;
|
||||
} else if ((key.ctrl && input === 'u') || key.wheelUp) {
|
||||
const step = key.wheelUp ? 3 : halfPage;
|
||||
setScrollOffset(prev => Math.max(prev - step, 0));
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user