Re: Clipboard API: remove dangerous formats from mandatory data types

On Tue, Jun 9, 2015 at 8:39 PM, Daniel Cheng <dcheng@google.com> wrote:

> Currently, the Clipboard API [1] mandates support for a number of formats.
> Unfortunately, we do not believe it is possible to safely support writing a
> number of formats to the clipboard:
> - image/png
> - image/jpg, image/jpeg
> - image/gif
>

Hi Daniel,
copying images to the clipboard is an important use case. Do you have any
suggestions for how we could meet this use case in a safer way? For
example, would it be safe and easy to add a little bit of "magic" to make

clipboardData.items.add(canvasElement)

put a PNG on the clipboard? Perhaps copying a rendered imgElement should
work too?
-Hallvord

Received on Thursday, 11 June 2015 06:31:39 UTC