fix: #305 disable double click to copy on pc

This commit is contained in:
Yifei Zhang 2023-04-01 15:46:34 +08:00 committed by GitHub
parent 45bf2c3d25
commit 0385f6ede9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -453,7 +453,10 @@ export function Chat(props: {
className="markdown-body"
style={{ fontSize: `${fontSize}px` }}
onContextMenu={(e) => onRightClick(e, message)}
onDoubleClickCapture={() => setUserInput(message.content)}
onDoubleClickCapture={() => {
if (!isMobileScreen()) return;
setUserInput(message.content);
}}
>
<Markdown content={message.content} />
</div>