fix: make @file suggestions case-insensitive (#11394)

This commit is contained in:
Riddhi Dutta
2025-10-18 01:28:06 +05:30
committed by GitHub
parent e4226b8a3e
commit 4d2a1111e0
3 changed files with 36 additions and 3 deletions

View File

@@ -145,9 +145,9 @@ export function useAtCompletion(props: UseAtCompletionProps): void {
} else if (
(state.status === AtCompletionStatus.READY ||
state.status === AtCompletionStatus.SEARCHING) &&
pattern !== state.pattern // Only search if the pattern has changed
pattern.toLowerCase() !== state.pattern // Only search if the pattern has changed
) {
dispatch({ type: 'SEARCH', payload: pattern });
dispatch({ type: 'SEARCH', payload: pattern.toLowerCase() });
}
}, [enabled, pattern, state.status, state.pattern]);