mirror of
https://github.com/QwenLM/qwen-code.git
synced 2026-04-29 12:11:09 +00:00
Refactor: Enhance @-command, Autocomplete, and Input Stability (#279)
This commit is contained in:
parent
4649026312
commit
6b3ef9f939
5 changed files with 104 additions and 89 deletions
|
|
@ -13,8 +13,8 @@
|
|||
* @returns True if the query looks like an '@' command, false otherwise.
|
||||
*/
|
||||
export const isAtCommand = (query: string): boolean =>
|
||||
// Check if starts with @ OR has a space, then @, then a non-space character.
|
||||
query.startsWith('@') || /\s@\S/.test(query);
|
||||
// Check if starts with @ OR has a space, then @
|
||||
query.startsWith('@') || /\s@/.test(query);
|
||||
|
||||
/**
|
||||
* Checks if a query string potentially represents an '/' command.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue