mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-07-12 02:50:41 -07:00
refactor: migrate to useKeyMatchers hook (#21753)
This commit is contained in:
committed by
GitHub
parent
cc43cfa810
commit
f7d284a43a
@@ -10,7 +10,8 @@ import Spinner from 'ink-spinner';
|
||||
import type { Config } from '@google/gemini-cli-core';
|
||||
import { debugLogger, spawnAsync, LlmRole } from '@google/gemini-cli-core';
|
||||
import { useKeypress } from '../../hooks/useKeypress.js';
|
||||
import { keyMatchers, Command } from '../../keyMatchers.js';
|
||||
import { Command } from '../../keyMatchers.js';
|
||||
import { useKeyMatchers } from '../../hooks/useKeyMatchers.js';
|
||||
|
||||
interface Issue {
|
||||
number: number;
|
||||
@@ -106,6 +107,7 @@ export const TriageDuplicates = ({
|
||||
onExit: () => void;
|
||||
initialLimit?: number;
|
||||
}) => {
|
||||
const keyMatchers = useKeyMatchers();
|
||||
const [state, setState] = useState<TriageState>({
|
||||
status: 'loading',
|
||||
issues: [],
|
||||
|
||||
@@ -10,9 +10,10 @@ import Spinner from 'ink-spinner';
|
||||
import type { Config } from '@google/gemini-cli-core';
|
||||
import { debugLogger, spawnAsync, LlmRole } from '@google/gemini-cli-core';
|
||||
import { useKeypress } from '../../hooks/useKeypress.js';
|
||||
import { keyMatchers, Command } from '../../keyMatchers.js';
|
||||
import { Command } from '../../keyMatchers.js';
|
||||
import { TextInput } from '../shared/TextInput.js';
|
||||
import { useTextBuffer } from '../shared/text-buffer.js';
|
||||
import { useKeyMatchers } from '../../hooks/useKeyMatchers.js';
|
||||
|
||||
interface Issue {
|
||||
number: number;
|
||||
@@ -69,6 +70,7 @@ export const TriageIssues = ({
|
||||
initialLimit?: number;
|
||||
until?: string;
|
||||
}) => {
|
||||
const keyMatchers = useKeyMatchers();
|
||||
const [state, setState] = useState<TriageState>({
|
||||
status: 'loading',
|
||||
issues: [],
|
||||
|
||||
Reference in New Issue
Block a user