Fix media description not recognized if programmatically entered

pull/475/head
Lim Chee Aun 2024-04-02 17:45:14 +08:00
rodzic 28882d98d9
commit ff336628f8
1 zmienionych plików z 4 dodań i 1 usunięć

Wyświetl plik

@ -1711,6 +1711,9 @@ function MediaAttachment({
onDescriptionChange,
250,
);
useEffect(() => {
debouncedOnDescriptionChange(description);
}, [description, debouncedOnDescriptionChange]);
const [showModal, setShowModal] = useState(false);
const textareaRef = useRef(null);
@ -1759,7 +1762,7 @@ function MediaAttachment({
onInput={(e) => {
const { value } = e.target;
setDescription(value);
debouncedOnDescriptionChange(value);
// debouncedOnDescriptionChange(value);
}}
></textarea>
)}