You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a custom emoji which outputs an src link to image in case of native it runs fine but in this case it is not working
<EmojiPopovertriggerIcon={<EmojiToolbarButton/>}// intentionally not bringing focus back to the editor to keep the popover openonEmojiClick={(emoji: any)=>{if(!!emoji.native){returneditor?.chain().insertContent(emoji.native).run();}letemj=document.createElement("div");emj.innerHTML=`<img src="${emoji.src}" />`returneditor?.chain().insertContent(emj).run();}}offset={[-210,-5]}shouldCloseOnClick={false}/>
Error :
[tiptap warn]: Invalid content. Passed value: <div><img src="https://github.githubassets.com/images/icons/emoji/octocat.png"></div> Error: RangeError: Unknown node type: undefined
at Schema.nodeType (index.js:2446:19)
at _Node.fromJSON (index.js:1523:23)
at Schema.nodeFromJSON (index.js:2431:21)
at createNodeFromContent (createNodeFromContent.ts:34:21)
at insertContentAt.ts:37:21
at Object.insertContentAt (CommandManager.ts:137:64)
at insertContent.ts:23:19
at Object.chainedCommand [as insertContent] (CommandManager.ts:86:45)
at onEmojiClick (toolbarButtons.tsx:108:32)
at Object.onEmojiSelect (EmojiPopover.tsx:163:21)
I have a custom emoji which outputs an src link to image in case of native it runs fine but in this case it is not working
Error :
Also tried this
but image still not loading, no error though
The text was updated successfully, but these errors were encountered: