Contact emails

[email protected]<mailto:[email protected]>, 
[email protected]<mailto:[email protected]>, 
[email protected]<mailto:[email protected]>

Explainer

https://docs.google.com/document/d/1rTEg2I-hMPXGiLrEMqKJz2Ycu6GRjlM3uvakOe84m8Q/edit?usp=sharing

Specification

None

Summary

This proposal aligns the HTML format read/write async API with the 
setData/getData DataTransfer APIs. Currently, when we read/write text/html MIME 
types using the async API, the sanitizer is invoked to strip out contents from 
the HTML markup due to security concerns, and styles are inlined in the HTML. 
This leads to loss of fidelity of HTML content when read by web authors or 
native apps.

Motivation

Using DataTransfer object's setData and async clipboard write method, we are 
seeing interop differences in how the HTML content is sanitized and written to 
the clipboard. In Chromium, async clipboard write method clears the clipboard 
content first and then writes the payload which results in overwriting the 
previous HTML content that was inserted by authors using DataTransfer object's 
setData API. It'd be beneficial for web authors if async clipboard and setData 
APIs provide the same HTML content during copy operation, so that round 
tripping is possible without any interop differences.

Moreover, creating a fragment and inlining the styles bloats the payload and 
strips out the custom styles inserted by sites like Excel Online that are used 
to preserve excel specific semantics.

Comments

Discussion between stakeholders: 
https://docs.google.com/document/d/1ha0pcpQsEgVGtPK8dd8N_0P1ynI7rXV7bR5ZFmOTD6Y/edit?usp=sharing

Firefox's support: 
https://github.com/w3c/clipboard-apis/issues/150#issuecomment-1031684598

Blink component

Blink>DataTransfer<https://bugs.chromium.org/p/chromium/issues/list?q=component:Blink%3EDataTransfer>

TAG review



TAG review status

As this is a Chromium specific change, we don't believe this merits TAG review. 
But we're happy to file a request if API_OWNERS feel this change should have 
one.

Risks



Interoperability and Compatibility

Gecko: Positive 
https://github.com/w3c/clipboard-apis/issues/150#issuecomment-1031684598

WebKit: No signal

Web developers: Positive

Debuggability

The async clipboard APIs have basic tooling support as described in 
https://docs.google.com/document/d/1eJn5QIX4JFGackDYmdLxWXEmTDkSGj_ZGz5XY4uCKbY/edit

Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, 
Chrome OS, Android, and Android WebView)?

Yes

Is this feature fully tested by 
web-platform-tests<https://chromium.googlesource.com/chromium/src/+/master/docs/testing/web_platform_tests.md>?

No

Flag name

TBD

Tracking bug

https://bugs.chromium.org/p/chromium/issues/detail?id=1268679

Estimated milestones

No milestones specified.

Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/5716132676763648<https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fchromestatus.com%2Ffeature%2F6037871692611584&data=05%7C01%7CAna.Sollano%40microsoft.com%7Cb0a2fbe347734699403a08da3815ec92%7C72f988bf86f141af91ab2d7cd011db47%7C0%7C0%7C637883964057764552%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=Un0P6tjq0ARKUWsn51chYU10v6Ev57Tb%2BJzNUFDDHJc%3D&reserved=0>

-- 
You received this message because you are subscribed to the Google Groups 
"blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/a/chromium.org/d/msgid/blink-dev/MN2PR00MB046492DBF7ABFE976B948BE8FD899%40MN2PR00MB0464.namprd00.prod.outlook.com.

Reply via email to