From 7ecf01f308044995085eba519ef7c7314789979b Mon Sep 17 00:00:00 2001 From: Anish Sarkar <104695310+AnishSarkar22@users.noreply.github.com> Date: Wed, 22 Jul 2026 01:38:53 +0530 Subject: [PATCH] refactor: remove onPaste handler from InlineMentionEditor for cleaner code --- .../components/assistant-ui/inline-mention-editor.tsx | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/surfsense_web/components/assistant-ui/inline-mention-editor.tsx b/surfsense_web/components/assistant-ui/inline-mention-editor.tsx index ee2d1c873..f1b8554e7 100644 --- a/surfsense_web/components/assistant-ui/inline-mention-editor.tsx +++ b/surfsense_web/components/assistant-ui/inline-mention-editor.tsx @@ -733,15 +733,9 @@ export const InlineMentionEditor = forwardRef ({ placeholder, - onPaste: (e: React.ClipboardEvent) => { - e.preventDefault(); - const text = e.clipboardData.getData("text/plain"); - const tf = editor.tf as { insertText: (value: string) => void }; - tf.insertText(text); - }, onKeyDown: handleKeyDown, }), - [editor, handleKeyDown, placeholder] + [handleKeyDown, placeholder] ); const mentionEditorContextValue = useMemo(