Re: [w3c/clipboard-apis] Clarify "8.1. The copy action" in regards to copying selected data (#49)

To achieve compatibility across browsers, it should additionally be specified how the selected contents are copied.

For instance, when selecting rows in a table, current browser behavior (Chrome, Firefox) when pasting them to the clipboard is to create a tab between the content of two adjacent cells.

Example: open the following in a browser, select all and copy-paste to a text editor:
```data:text/html,<table><tr><td>x</td><td>y</td><tr/> <tr><td>a</td> <td>b</td></tr> </table>```

However, if the selected elements have the display property `block`, Chrome and Firefox create line breaks between two adjacent cells.

Example: open the following in a browser, select all and copy-paste to a text editor:
```data:text/html,<table><tr><td><p>x</td><td><p>y</td><tr/> <tr> <td><p>a</td> <td><p>b</td> </tr> </table>```

Having such and potentially other related details specified would help achieving a reasonable and consistent behavior across browsers.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/clipboard-apis/issues/49#issuecomment-492277740

Received on Tuesday, 14 May 2019 15:06:02 UTC