diff --git a/packages/nc-gui/helpers/tiptapExtensions/mention/index.ts b/packages/nc-gui/helpers/tiptapExtensions/mention/index.ts new file mode 100644 index 0000000000..a50ef83505 --- /dev/null +++ b/packages/nc-gui/helpers/tiptapExtensions/mention/index.ts @@ -0,0 +1,10 @@ +import * as TipTapMention from '@tiptap/extension-mention' + +export const Mention = TipTapMention.Mention.extend({ + renderHTML({ HTMLAttributes: _ }) { + return ['span'] + }, + renderText({ node: _ }) { + return '' + }, +}) diff --git a/packages/nc-gui/helpers/tiptapExtensions/mention/suggestion.ts b/packages/nc-gui/helpers/tiptapExtensions/mention/suggestion.ts new file mode 100644 index 0000000000..33b0d250af --- /dev/null +++ b/packages/nc-gui/helpers/tiptapExtensions/mention/suggestion.ts @@ -0,0 +1,9 @@ +export default { + render: () => { + return { + onStart: (_props: Record) => {}, + + onUpdate(_props: Record) {}, + } + }, +}