fix: react function rendering always to insert mode

This commit is contained in:
qixinbo
2026-03-30 00:05:58 +08:00
parent cb7913ebb0
commit 307ea0189e
+12 -12
View File
@@ -801,7 +801,7 @@ export function ChatInterface() {
); );
}; };
const ChatInputPanel = ({ const renderInputPanel = ({
menuSide, menuSide,
menuOffsetClass, menuOffsetClass,
recordingWaveKeyPrefix, recordingWaveKeyPrefix,
@@ -1382,11 +1382,11 @@ export function ChatInterface() {
{/* Input Area */} {/* Input Area */}
<div className="w-full px-4"> <div className="w-full px-4">
<ChatInputPanel {renderInputPanel({
menuSide="bottom" menuSide: "bottom",
menuOffsetClass="mt-2" menuOffsetClass: "mt-2",
recordingWaveKeyPrefix="empty" recordingWaveKeyPrefix: "empty",
/> })}
<div className="mt-4 flex flex-wrap justify-center gap-2"> <div className="mt-4 flex flex-wrap justify-center gap-2">
{/* Common Questions or suggestions could go here */} {/* Common Questions or suggestions could go here */}
</div> </div>
@@ -1636,12 +1636,12 @@ export function ChatInterface() {
{/* Floating Input for Chat State */} {/* Floating Input for Chat State */}
{messages.length > 0 && ( {messages.length > 0 && (
<div className="px-4 pb-6 pt-3 border-t border-border bg-background"> <div className="px-4 pb-6 pt-3 border-t border-border bg-background">
<ChatInputPanel {renderInputPanel({
menuSide="top" menuSide: "top",
menuOffsetClass="mb-2" menuOffsetClass: "mb-2",
recordingWaveKeyPrefix="chat" recordingWaveKeyPrefix: "chat",
showDisclaimer showDisclaimer: true,
/> })}
</div> </div>
)} )}
<Dialog open={Boolean(artifactPreview)} onOpenChange={(open) => { <Dialog open={Boolean(artifactPreview)} onOpenChange={(open) => {