Your Rocket.Chat version: 0.33.0
Firstly I'm filing this against R.C instead of R.C.E because this also happens with Chrome/Chromium as well as Electron. This leads me to believe it is a bug to do with how the application interfaces with the browser based on which browser it is.
The issue is that whenever someone attempts to paste from a spreadsheet program, be it LibreOffice or Microsoft Excel, it results in grabbing the image MIME object from the clipboard instead of the text object.
Being able to test other sites in Chrome/Chromium, this does not happen on other sites like google's input box or pastebin.com's. The clipboard object is correctly interpreted as multi-line text.
Open up LibreOffice or Microsoft Excel. Make the following text:
| | A |
| --- | --- |
| 1 | Test 1 |
| 2 | Test 2 |
(Optional) Go to http://www.google.com, paste the same text into their input box
Chrome/Chromium/Electron: In RC and RC only:



I'm seeing this with Excel 2016 on Chrome Version 51.0.2704.84 m and Electron client running on Windows 10 64-bit
Hm... this must have something to do with the rich text stuff. Like how styling is brought over when you copy between office and outlook, etc. So we might need to just strip styling on text?
+1
same here
Rock.Chat+ 1.3.1, MS Excel for MAC 15.13.1 , OS X 10.11.4
@geekgonecrazy I think just text will be fine.
This is still broken. And now it does it in Firefox, too, apparently.
Pasting from LibreOffice Calc or Microsoft Office or OneNote etc still asks to upload an image instead of just simply pasting the text.
I think this should be reclassified as a bug not an improvement (aren't all bug fixes improvements too)? @geekgonecrazy
0.59.3 still happening... hope there's a way to allow excel copy to paste as plain text instead of image upload
I'm seeing this when attempting to copy and paste data from excel as well.
Even just 1 cell being pasted results in

Same here on a Mac OSX, version 10.12.6 when copying text from a mailbody within Microsoft Outlook 15.40.
Resulted text will be uploaded as image in the Mac Electron App Rocket Chat+
@geekgonecrazy Do you have any idea what component might be causing this?
I'm willing to try and look into it but i cant pinpoint the component causing it.
I honestly have no idea. Seems like the conversion must be happening some how client side since shows before the upload.
Still affects 0.62.1
This is becoming a hot issue where I have RocketChat deployed.
It's been an issue for awhile, but not as hot as it is now.
We are currently running RocketChat-Server: 0.62.1
It's hosted on Ubuntu 16.04 LTS
I've been trying to figure this out for a very long time now, still have not managed to find the cause :(
Can you please try using keyboard to paste ...
on Mac OSX ... Shift + Option + Command + V
on Windows ... Control + Shift + V
@Sing-Li
On OSX:
Command+Shift+V works as a work around to regular Command+V when connected to Rocket.Chat in web browser and if it's loaded in latest versions of Rambox & Franz. Pastes properly as regular text, free from image conversion.
Command+Shift+V/Command+Shift+Option+V does NOT work in Rocket.Chat+ Electron app on OSX. (tested in version 2.10.5)
We do not have any Windows clients really using it so have not ran that test on windows.
Would still be ideal for regular paste commands to not convert to image but regular text. But this is a solution that will cool off some staff members in the meantime.
Any update ?
Is the problem resolved?
The problem is still alive in 0.65.1
Not resolved for Mac OSX + Franz or Mac OSX + Chrome. Works as workaround on Mac OSX + Safari
IMO, As stated before, the default behavior for cmd+v should be pasting text.
I wouldn't expect many cases at all where pasting an image of the text would be useful. You could always paste a screenshot if you needed an image. If a user highlights text and copy/paste, then their intention should be obvious since you shouldn't expect a rectangular image from a potentially multi-line, wrapped selection of text.
@mmickelson Basically you are right, but if you are pasting a table from Excel into an E-Mail or word it also stays readable and formated.
I second @mmickelson , default paste to text and give the option to create a pic/keep the format when needed would be best.
Still doesn't work on Macos
We should loop the clipboard array and open a modal window for the users to choose what version of the content they want to use. Plain text on the message input or a file to upload.
@mmickelson Basically you are right, but if you are pasting a table from Excel into an E-Mail or word it also stays readable and formated.
@mfraiss The trouble I see with pasting a table as an image is that you wouldn't be able to select the text. When pasting from Excel to Word or Outlook, the text is still selectable. Unless the clipboard contains an image, I struggle to find a scenario that would make the most sense to paste an image of what was copied.
IMHO, pasting a table into rocket should at a minimum paste comma or tab-delimited text. I don't think users should expect to paste in a fully formatted, exact copy of the Excel table. This is because the reason for pasting a table is usually to copy the _data_, not the aesthetic look of the table. If you want to give someone the fully formatted table, send them the flippin' file.
Are there any other apps in existence that paste an image of text? I think it's standard to paste text for a reason.
@engelgabriel Although the feature of converting text to an image is nifty, I would have to push for the default behavior to just be pasting text unless the clipboard content is an image. A modal would just get in the way. This sounds like a case of adding a feature that shouldn't be there but the developers want to keep because of the time put into it.
Again, think about the reason a user pastes text. Is it to show someone what the text looks like in another app? I think it's because they want to share the information or data that often needs to be selectable and copyable.
Hi,
I have the same problem here, after I have introduced RocketChat as company wide communication tool, unfortunately the CEO discovered this (and doesn't like it). I would like to back @mmickelson and ask if someone has already done a fix for this or if it is still discussed, how to solve the problem? If I would want to just switch off the image generating code (given that this is possible for me with my limited skills ;-)) where would I have to start looking?
I just tested on Linux Chromium Version 77.0.3865.90
Ctrl + Shift + V pastes as text
Shift + V pastes as image
See this (I have highlighted the text to show it is text and can be copied again):

Unfortunately the company runs on MACs and we are using the native app. I will give a more detailed report on versions as soon as I have access to my MAC, as I am currently using Linux ;-) where everything works fine so far.
Summary for Pasting from Office as plain Text on a Mac:
Native Client: no way, always as picture 馃槥 (version 2.15.5)
Firefox: CMD+V results in plaintext (version 69.0.1)
Chrome: CMD+V results in picture, CMD+Shift+V results in plaintext (version 77.0.3865.90)
Safari: CMD+V results in plaintext (version 13.0.2)
Rocket Chat is in Version 1.1.2
Anything coming from Excel over clipboard has four MIME types:
text/plain;text/html;text/rtf;image/png.IMO having a text/plain content is sufficient to NOT use the image/png one since the message box doesn't support rich text, but (1) I'm not sure if there are users out there which like the option to paste an image from Office documents and (2) we need to ensure that no exotic browser/OS combination attaches text/plain to any clipboard images.
Most helpful comment
Still affects 0.62.1