Rocket.Chat icon indicating copy to clipboard operation
Rocket.Chat copied to clipboard

Copy history message with multi line and pasty to new message will auto add blank line.

Open akong77 opened this issue 2 years ago • 3 comments

Description:

I have upgrade to 5.3.2.I found a bug.If I copy history message and it's message have multi line.Then I pasty to my message.It's will auto add blank line.How to fix it.

Steps to reproduce:

  1. Copy multi line history message
  2. Pasty to my message.
  3. It's will auto add blank line.

Expected behavior:

The original message should be displayed

Actual behavior:

圖片 The original is 圖片

Server Setup Information:

  • Version of Rocket.Chat Server: 5.3.2
  • Operating System: Ubuntu
  • Deployment Method: snap
  • Number of Running Instances: 1
  • DB Replicaset Oplog:
  • NodeJS Version: v14.19.3
  • MongoDB Version: 4.4.15

Client Setup Information

  • Desktop App or Browser Version: 3.8.14
  • Operating System: Win11

Additional context

Relevant logs:

akong77 avatar Nov 29 '22 02:11 akong77

Hi! That's a nice catch, but not sure if a bug exactly :)

Just to clarify: When you copy a multi line text from Rocket.Chat and paste it (tested on VSCODE), it will indeed add a blank line between lines.

Example: 123 456 789 111 222 333

When I pasted in LibreOffice, however, it didn't added the space.

This is because Rocket.Chat will render the message like this:

<p>123</p>
<p>456</p>
<p>789</p>
<p>111</p>
<p>222</p>
<p>333</p>

and not like this

123<br />
456<br />
789<br />
111<br />
222<br />
333<br />

While both can represent the same, it will depend on how the receiving party will render that while receiving the information.

dudanogueira avatar Nov 29 '22 13:11 dudanogueira

Okay,Maybe it's not a bug.Could fix it?

akong77 avatar Nov 30 '22 00:11 akong77

@dudanogueira As a UI/UX designer, I believe I can solve this issue. Shall I proceed?

BhuvanAde avatar Dec 06 '22 14:12 BhuvanAde

I would like to work on this, please assign this to me.

jsrjhbaryan959 avatar Jan 15 '23 14:01 jsrjhbaryan959