-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Copying linked content from other rich text editors into the tiptap editor will treat the content following the link as a link #3893
Comments
Hey @Chenchaoyang666 just a few questions:
Thanks for your help. |
Copy the following linked text from wangeditor into the tiptap editor: |
It seems that github has the same problem as tiptap |
@ZowieTao it's not clear why you shared those images. If there's a difference, please mention what it is. |
The issue seems to occur because of these lines: tiptap/packages/extension-link/src/helpers/pasteHandler.ts Lines 58 to 59 in 05a2edf
|
The first bad commit is likely from this PR: #3975 TipTap @bdbch pinging you because it's your commit and I know these things tend to get harder to fix the longer that passes. It would be great if this could be resolved before the stable release of I'm not really sure what prior problem the lines I mentioned are intended to accomplish so I can't suggest any changes. |
@slapbox could you explain exactly where you copied the content from? I tried to replicate it with a copied link + list - but it didn't break on my end. Did you copy it from another editor or another tiptap instance? |
@Chenchaoyang666 for the example you provided I determined the problem down to the Same with the commas which are Are those characters usually used in chinese? If so I can't really help here and would require help from a chinese developer as I can't test this accordingly. |
Problem is - we're using linkify to find links inside text and will use the link length + the link offset to add a mark for the link. Because your link does technically not have spaces, linkify takes everything as a link. |
@bdbch thanks for looking into this. I copied the content from the same TipTap editor instance to produce my screenshot. |
What’s the bug you are facing?
Copying linked content from other rich text editors into the tiptap editor will treat the content following the link as a link
Which browser was this experienced in? Are any special extensions installed?
Version 110.0.5481.100 (Official Version) (64-bit)
How can we reproduce the bug on our side?
Copying linked content from other rich text editors into the tiptap editor will treat the content following the link as a link,I think pasted content with a label should be processed first
Can you provide a CodeSandbox?
No response
What did you expect to happen?
If the attached content is labeled a, the link can be accessed normally
Anything to add? (optional)
No response
Did you update your dependencies?
Are you sponsoring us?
The text was updated successfully, but these errors were encountered: