mirror of
https://github.com/docmost/docmost.git
synced 2026-05-18 15:34:05 +08:00
feat: realtime comments (#1144)
* init * fix: close bubblemenu after comment and wait before scroll * scroll to comment when click * highlight comment animation
This commit is contained in:
@@ -53,6 +53,10 @@ const CommentEditor = forwardRef(
|
||||
autofocus: (autofocus && "end") || false,
|
||||
});
|
||||
|
||||
useEffect(() => {
|
||||
commentEditor.commands.setContent(defaultContent);
|
||||
}, [defaultContent]);
|
||||
|
||||
useEffect(() => {
|
||||
setTimeout(() => {
|
||||
if (autofocus) {
|
||||
|
||||
Reference in New Issue
Block a user