mirror of https://github.com/fantasticit/think.git
fix: fix comment editor
This commit is contained in:
parent
4c9838e29e
commit
e211f07794
|
@ -1,6 +1,7 @@
|
||||||
import { HocuspocusProvider } from '@hocuspocus/provider';
|
import { HocuspocusProvider } from '@hocuspocus/provider';
|
||||||
import Collaboration from '@tiptap/extension-collaboration';
|
import Collaboration from '@tiptap/extension-collaboration';
|
||||||
import CollaborationCursor from '@tiptap/extension-collaboration-cursor';
|
import CollaborationCursor from '@tiptap/extension-collaboration-cursor';
|
||||||
|
import History from '@tiptap/extension-history';
|
||||||
import { getRandomColor } from 'helpers/color';
|
import { getRandomColor } from 'helpers/color';
|
||||||
import { Document } from './extensions/document';
|
import { Document } from './extensions/document';
|
||||||
import { BaseKit } from './basekit';
|
import { BaseKit } from './basekit';
|
||||||
|
@ -14,7 +15,7 @@ export const DocumentWithTitle = Document.extend({
|
||||||
content: 'title block+',
|
content: 'title block+',
|
||||||
});
|
});
|
||||||
|
|
||||||
export { Document };
|
export { Document, History };
|
||||||
export const DEFAULT_EXTENSION = [...BaseKit];
|
export const DEFAULT_EXTENSION = [...BaseKit];
|
||||||
|
|
||||||
export const getCollaborationExtension = (provider: HocuspocusProvider) => {
|
export const getCollaborationExtension = (provider: HocuspocusProvider) => {
|
||||||
|
|
|
@ -121,19 +121,7 @@ export const CommentMenuBar: React.FC<{ editor: any }> = ({ editor }) => {
|
||||||
|
|
||||||
<Divider />
|
<Divider />
|
||||||
<BaseMenu editor={editor} />
|
<BaseMenu editor={editor} />
|
||||||
|
|
||||||
<Divider />
|
|
||||||
<AlignMenu editor={editor} />
|
|
||||||
|
|
||||||
<Divider />
|
|
||||||
<BaseInsertMenu editor={editor} />
|
|
||||||
</Space>
|
</Space>
|
||||||
|
|
||||||
<BaseBubbleMenu editor={editor} />
|
|
||||||
<ImageBubbleMenu editor={editor} />
|
|
||||||
<LinkBubbleMenu editor={editor} />
|
|
||||||
<BannerBubbleMenu editor={editor} />
|
|
||||||
<TableBubbleMenu editor={editor} />
|
|
||||||
</>
|
</>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue