Update
This commit is contained in:
@@ -518,13 +518,17 @@ const VideoEditor = ({ width, height }) => {
|
||||
emitter.on('video-play', handlePlay);
|
||||
emitter.on('video-reset', handleReset);
|
||||
emitter.on('video-seek', handleSeek);
|
||||
emitter.on('text-update', ({ elementId, updates }) => {
|
||||
handleElementUpdate(elementId, updates);
|
||||
});
|
||||
|
||||
return () => {
|
||||
emitter.off('video-play', handlePlay);
|
||||
emitter.off('video-reset', handleReset);
|
||||
emitter.off('video-seek', handleSeek);
|
||||
emitter.off('text-update');
|
||||
};
|
||||
}, [emitter, handlePlay, handleReset, handleSeek]);
|
||||
}, [emitter, handlePlay, handleReset, handleSeek, handleElementUpdate]);
|
||||
|
||||
return (
|
||||
<div style={{ width: dimensions.width, height: dimensions.height }} className="rounded-3xl">
|
||||
|
||||
Reference in New Issue
Block a user