Spaces:
Running
Running
Commit ·
12eb4e9
1
Parent(s): 5aa6c68
commit 021158
Browse files- src/App.js +1 -0
- src/components/ChatInput.jsx +1 -1
src/App.js
CHANGED
|
@@ -45,6 +45,7 @@ export default function App() {
|
|
| 45 |
},
|
| 46 |
onDone: () => {
|
| 47 |
setLoading(false);
|
|
|
|
| 48 |
},
|
| 49 |
});
|
| 50 |
};
|
|
|
|
| 45 |
},
|
| 46 |
onDone: () => {
|
| 47 |
setLoading(false);
|
| 48 |
+
setFileUploaded(false);
|
| 49 |
},
|
| 50 |
});
|
| 51 |
};
|
src/components/ChatInput.jsx
CHANGED
|
@@ -4,7 +4,7 @@ export default function ChatInput({ onSend, fileUploaded }) {
|
|
| 4 |
const [input, setInput] = useState("");
|
| 5 |
|
| 6 |
const handleSubmit = () => {
|
| 7 |
-
|
| 8 |
onSend(input);
|
| 9 |
setInput("");
|
| 10 |
};
|
|
|
|
| 4 |
const [input, setInput] = useState("");
|
| 5 |
|
| 6 |
const handleSubmit = () => {
|
| 7 |
+
// if (!input.trim() || !fileUploaded) return;
|
| 8 |
onSend(input);
|
| 9 |
setInput("");
|
| 10 |
};
|