fix(user-input): stop @mention/skill menu from reopening after dismiss#5464
Conversation
- Fixes a bug where the @mention (and /skill) autocomplete menu couldn't be dismissed: clicking away or pressing Escape closed it, but the very next click/selection change reopened it because the caret was still inside the unfinished @token - Adds a one-shot "dismissed" marker per token, set only on a real outside-click/Escape dismiss, cleared the instant the user types again - Shared fix in use-prompt-editor.ts covers every consumer: home chat input, scheduled-task modal, task-details modal
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
PR SummaryLow Risk Overview
Adds Reviewed by Cursor Bugbot for commit 5e55525. Configure here. |
…smiss fix Trims the inline // explanations added in the previous commit down to the two declaration-level doc comments that carry real information — matching the repo's no-inline-comments convention.
…gger Cursor Bugbot review: insertSlashTrigger (the toolbar Slash button) called syncSlashState without clearing dismissedSlashStartRef, so a stale dismissal could suppress the skills menu on an explicit user action when the new token's start offset coincided with the previously dismissed one. An explicit trigger click must always open the menu, so it now clears the marker first like every other insertion path.
|
@cursor review |
|
@cursor review |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 5e55525. Configure here.
Summary
Type of Change
Testing
Added use-prompt-editor.test.tsx (4 tests) that mounts the real hook and reproduces the exact scenario — confirmed it fails on the pre-fix code and passes after. Also ran full typecheck/lint.
Checklist