-
-
Notifications
You must be signed in to change notification settings - Fork 163
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
[BUG] Pasting text from MS Word inserts as image in MDXEditor #641
Comments
I can confirm this issue. We are using MDXEditor in production at fiete.ai. Our users are reporting this issue frequently, since they are teachers who are using MS Word a lot. Here is a short Video demonstrating the issue: In our app, where we have an upload handler implemented, the uploaded image contains the copied text. |
@maltesa it's great that your company relies on this project. If it brings value to your business, you can either |
@petyosi I was about to update my comment, because I was looking into the code to find a fix by myself. I will also consider the sponsorship. This is the content of the clipboard item when text is pasted from office: What is the expected behaviour? If you agree with this, I'm happy to open a pull-request for that. I hope this only requires a small change here: editor/src/plugins/image/index.ts Line 257 in da50ea9
|
That makes sense to me. |
#652 should fix this. |
Merged #652 |
Issue Description
When copying content from MS Word for Mac OS and pasting it into MDXEditor, the content is inserted as an image instead of editable text.
Steps to Reproduce
Clipboard Data Formats
After copying content from MS Word, I ran
osascript -e 'clipboard info'
and received the following output:«class RTF », 43042 «class ut16», 814 «class HTML», 40872 Unicode text, 820 «class PDF », 46178 «class weba», 41178 «class rtfd», 1956 «class utf8», 410 string, 0
Analysis
Expected Behavior
MDXEditor should paste the text content with proper formatting, using one of the text-based formats like RTF or HTML.
Actual Behavior
The editor inserts the content as an image, making the text non-editable.
Environment
Additional Information
The text was updated successfully, but these errors were encountered: