Commit 2e5f8f5
committed
fix(chat): don't swallow a paste whose selection chip is already attached
Cursor Bugbot: the selection-paste path called preventDefault before
prepareContextForInsert, so when that returned null (the same selection is
already a chip) the handler returned having claimed the event — no chip
inserted and no text/plain pasted either. Cmd+V did nothing.
preventDefault now waits until there is a chip to insert; a duplicate falls
through to the plain-text paste below, which is the reasonable reading of the
gesture.1 parent b20cfcd commit 2e5f8f5
1 file changed
Lines changed: 10 additions & 6 deletions
File tree
- apps/sim/app/workspace/[workspaceId]/home/components/user-input/components/prompt-editor
Lines changed: 10 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
929 | 929 | | |
930 | 930 | | |
931 | 931 | | |
| 932 | + | |
| 933 | + | |
| 934 | + | |
| 935 | + | |
| 936 | + | |
932 | 937 | | |
933 | | - | |
| 938 | + | |
| 939 | + | |
| 940 | + | |
| 941 | + | |
934 | 942 | | |
935 | | - | |
936 | | - | |
937 | | - | |
938 | | - | |
939 | | - | |
| 943 | + | |
940 | 944 | | |
941 | 945 | | |
942 | 946 | | |
| |||
0 commit comments