فهرست منبع

Update chat.tsx

Snow Kawashiro 1 سال پیش
والد
کامیت
9775660da7
1فایلهای تغییر یافته به همراه2 افزوده شده و 2 حذف شده
  1. 2 2
      app/components/chat.tsx

+ 2 - 2
app/components/chat.tsx

@@ -1102,9 +1102,9 @@ function _Chat() {
   }, []);
   
   const handlePaste = useCallback(
-    const currentModel = chatStore.currentSession().mask.modelConfig.model;
-    if(!isVisionModel(currentModel)){return;}
     async (event: React.ClipboardEvent<HTMLTextAreaElement>) => {
+      const currentModel = chatStore.currentSession().mask.modelConfig.model;
+      if(!isVisionModel(currentModel)){return;}
       const items = (event.clipboardData || window.clipboardData).items;
       for (const item of items) {
         if (item.kind === "file" && item.type.startsWith("image/")) {