mirror of
https://git.mirrors.martin98.com/https://github.com/bytedance/deer-flow
synced 2025-08-20 21:39:16 +08:00
fix: message input box reflow (#252)
This commit is contained in:
parent
56e35c6b7f
commit
9888098f8a
@ -15,13 +15,13 @@ import {
|
|||||||
} from "novel";
|
} from "novel";
|
||||||
import { Markdown } from "tiptap-markdown";
|
import { Markdown } from "tiptap-markdown";
|
||||||
import { useDebouncedCallback } from "use-debounce";
|
import { useDebouncedCallback } from "use-debounce";
|
||||||
import { cx } from "class-variance-authority";
|
|
||||||
|
|
||||||
import "~/styles/prosemirror.css";
|
import "~/styles/prosemirror.css";
|
||||||
import { resourceSuggestion } from "./resource-suggestion";
|
import { resourceSuggestion } from "./resource-suggestion";
|
||||||
import React, { forwardRef, useMemo, useRef } from "react";
|
import React, { forwardRef, useMemo, useRef } from "react";
|
||||||
import type { Resource } from "~/core/messages";
|
import type { Resource } from "~/core/messages";
|
||||||
import { useRAGProvider } from "~/core/api/hooks";
|
import { useRAGProvider } from "~/core/api/hooks";
|
||||||
|
import { LoadingOutlined } from "@ant-design/icons";
|
||||||
|
|
||||||
export interface MessageInputRef {
|
export interface MessageInputRef {
|
||||||
focus: () => void;
|
focus: () => void;
|
||||||
@ -152,7 +152,11 @@ const MessageInput = forwardRef<MessageInputRef, MessageInputProps>(
|
|||||||
}, [onEnter, provider]);
|
}, [onEnter, provider]);
|
||||||
|
|
||||||
if (loading) {
|
if (loading) {
|
||||||
return null;
|
return (
|
||||||
|
<div className={className}>
|
||||||
|
<LoadingOutlined />
|
||||||
|
</div>
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
Loading…
x
Reference in New Issue
Block a user